I have a text file that is the result of using XMLHTTP object to pull back a page of search results from a search engine.
So I have the entire results page in HTML, and want to break out each hit result from the text file as a unique item and do what I want with each hit result.
Is there any suggested algorithms or any other techniques I could be directed to?
In my main 'submit news' admin for a site I am doing, I want to be able to offer the person submitting the news the ability to reference other files within their text without the need to use HTML. My proposal is to use [square brackets] within the text that will then be parsed when the page is rendered from the database. At present I have this - e.g.
To download the file [file.exe, click here]. Which I want to render with the words 'click here' as being a link to file.exe. I'm very familiar with instr, replace and split (all of which I think I would need to use) but I cannot figure out how to parse the above text in the way I want.
<title>Partly Cloudy and 73 degrees F at Pitt-Greenville Airport, NC</title>
In an ASP file, how would I get the three characters before the word "degrees"? In this particular case, it would be "73 ". Obviously, I'm trying to extract the degrees from this weather string (which is from the National Weather Service, in case anyone is wondering). If anybody knows a better way to get the degrees information from this string.
EDIT: Nevermind. I found that the National Weather Service also offers an XML version that has the degrees totally separated. (The one above is from an RSS feed rather than straight XML.) Having it in this form makes it much easier to parse.
I know this is a little off topic, but this is the best resource I know of for anything coding related.
I'm needing to read through a text file that will have the following format:
c:ools c:docs c:htdocs
And have the the results put in an array for later processing. What I'm trying to build is a small vbscript that will automatically backup each path that may be in a given txt file.
Does anyone know of an ASP (VBScript) that can function as a Yahoo Group style replacement? This includes handling digest emails as well. All the popular forum software I've looked at, such as Snitz, can't handle it.
I have just upgraded my win98SE pc to winxp home. I am aware that PWS won't work with xp home, and I need to upgrade to XP pro for IIS. Problem is that I don't really want to upgrade unless I have to.
I've been investigating the various server options available. I need to run .asp scripts and connect to access 2000 databases. I'm not sure what servers will do this as the documentation is never that clear. Will Apache do what I want, and is there a duffers guide to getting it running?
However, that just makes it a regular double-quote. I guess I could try and find out what the character number for apostrophes are, but not sure where that is. Besides, will that mess up my SQL Server or the email if I do that?
Is it possible to make another file act likle global.asa? at the moment my project uses this file but im not sure how many hosts allow users access to it, so if i could just include another file and make it act like the global.asa that would be great.
Not strictly an ASP question, but it's for an ASP-based content management system:
I'm looking for a good, free textarea replacement application which creates a WYSIWYG interface from form textareas. I have used HTMLArea in the past but it only works on IE6.
I skinned an LMS (Learning Management System) using CSS and Javascript. The forms were skinned with niceforms.js, the site works perfectly in FF, IE 7 and IE6 but in ASP the javascript doesn't replace the images with the skinned elements. All the javascript functions initialize but the images are not placed in. Code:
While debugging why a web.config section replacement was not happening in the real web application, I tried a simplified case, no replacement is enabled and the connection string is not showing up? Code:
i want to ask is there any way that i could get the value from field (the value will be used in SQL statement) without submit the form coz if i use Request.form("name"), it need to submit the form to get the value
I'm interested in creating an asp function that enables the general parsing of xml. The function needs to take into account the structure of the xml document, as the document(s) can be quite complex.
The use of getElementsByTagName() is not appropriate in this case as I'm trying to avoid picking up the wrong data. The function also needs to be able to test if a node has any attributes and what the attributes are. Here's an example of the document I'm trying to parse: Code:
I do a regular HTML form POST to a third party server. The server processes the request and displays result in XML format. However, I need to parse this xml and display in HTML. The problem is how can I get the control from the form POST.right now, the form posts and the result is displayed but I need the control back.
I need to use forum code for my site, and making things bold, etc, is very easy however, I cannot work out how to use the tags [*url]http://site.com[/*url], the asterix will avoid it being parsed to create links.
I want to be able to get the text between the two URL tags, and build a link, so <a href=""" & textinbetween & """>" & textinbetween & "</a>".
is there any way that i could get the value from field (the value will be used in SQL statement) without submit the form coz if i use Request.form("name"), it need to submit the form to get the value.
Set ResponsibilitytNodes = DomDoc.SelectNodes("CLASS/Work_Experience/job[@employer='" & node.attributes(0).text & "']/Responsibility/") For Each node in ResponsibilitytNodes Response.Write ResponsibilitytNodes.text Next
I have a script that Technicweb helped me make. However it is just short of what I need. The players data still has the html code around it. I want to extract the name only with the statistics. I cant seem to get my head around it - all I have learned from picking apart Technicweb's script seem not to work for me. Here is the latest of what I have come up with, it gives me an error:
Microsoft VBScript runtime error '800a01c2'
Wrong number of arguments or invalid property assignment: 'MID'
I think this has been asked before but I can't find the reply. I'm using the XML parser to post data to a server and receiving a reply. The reply is in XML and I want to find elements of the retrieved data. Eg. I receive a string with: Code:
I am looking for something similar to "preg_match" and "preg_match_all" in PHP.
I have searched the forum with no luck. I hope you are able to give me some pointers
Basically I want to match some text from a form and loaded it into new variables making use of regular expressions. the text comes form a textarea input type. Code:
I have to display time in HH:MM AM/PM format. My date/time values are being pulled from a MS SQL database that is in smalldatetime field format.
I need to take a date such as "5/5/2006 7:35:00 AM" and display it as "7:35 AM". I can't seem to find how to parse this or display only the hours, minutes, and AM/PM designator.
I've found the MS XML parser as shown in below code. I'm just attempting to display the various ListNames in the ListStruc section of an incoming XML file (generated by the SelectLists API call). On the line with the astrik though, I'm getting the error "Object required: '[object]'. Is this because I don't have this parser installed? (I'm running XP Pro w/IE 6.0.)
Also, I'm not sure about the line xmlDoc.load(request), shouldn't it be xmlDoc.load(xml.responseText)? Code:
I have a string problem that I would like to resolve. I am submittting multiple values to a form that is posted to query string. The string looks like this:
So what I need to do is to take the id number of the user and put it into an array so I can later insert it into the database. So for the example above, I need an list that looks like this:
436, 430, 425
Once I have this list I can make it an array and then put it into the database.
My question is how do I make the string above look like the string below? I know that I need to use some function of asp to parse the name oout of the string, but i just don't know exactly what....
I have searched on parsing some strings but I don't know how to apply it to my string. The string I am parsing looks like: $$1,0,0,0,0,0,7,8,0,0,0,0,13,14,0$$None What I am looking to do is get the non-zero numbers.
I will then use these for another portion of the page where checkboxes corrosponding to those numbers will appear and the zeero numbers will not. The string after the last two $$ must be used as well for text on the page. I can change the string to look however is easiest to parse.
I have a select statement that gives me the following results (for example) "test documentation/software product version document.doc" I need to parse the data to only grab everything between the "/" and ".". So, in other words, "software product version document" - I have absolutley no idea how to do this .
I need to create an asp page to parse a slightly unusual data stream which is in CSV format with new records identified by carriage returns. how to start? Really I want to just tabulate some of the data and ignore other fields. It's a travel industry data feed - sample record: