Search String In HTML Form
In a HTML form field, the user enters a long text. I need to search for an image tag. Then get the name of the image (*.gif or *.jpeg) to check the image library if the image already exists. If exists, cannot upload the image. Else, upload the image.
View Replies
ADVERTISEMENT
I want to search a string of HTML and insert a querystring into any url where the url is an asp page and is either a local link /folder/page.asp or of a specific domain http://www.somedomain.com/folder/page.asp. It needs to be able to handle plain links and those with querystrings already in there.
I could do it with instr functions etc but I thought this might a good time to brush up on regular expressions. Can anyone point me in the right dirction?
View Replies
View Related
if anyone can shed some experience on how to have search engines index a website that is a store using products stored in an asp database. I've been creating static html pages each time I update my inventory but it seems like there has to be a better/quicker way.
View Replies
View Related
I am passing the following variables....
City - name of city
RentLow - low range of rent
RentHigh - high range of rent
myquery - keywords
The following is the start of my query string but I am having issues with the City portion already and I have not gotten to the rent yet
I know the SQLquery portion right below is fine - it tested perfectly, along with the rest of the query, it was when I added in the request city string that gives me No value given for one or more required parameters. even though one is passed in the string.
SQLquery = "(" &parsethis(strText ,words ,wCount, 3) & ")"
SQLquery = Replace(SQLquery, "<FIELD1>", "title")
SQLquery = Replace(SQLquery, "<FIELD2>", "description")
SQLquery = Replace(SQLquery, "<FIELD3>", "comments")
SQLstr = "SELECT * FROM links WHERE " & SQLquery & " AND city = " & Request.QueryString("city") & " AND linktype = 2 AND active = " & myTrue & " " & SortSQL & ";"
end if
View Replies
View Related
i ve a string like this : my_name_is_ahmed_adly
now i need to see if this string contains the word "is"
so how can i do this ?
View Replies
View Related
if i have a string with comma seperated words. is there a way to search another string for words that are in it?
View Replies
View Related
I have a page that is not asp that is linking to an asp page with a question mark and a variable on the end of the URL. How can I pull the variable off using server
side processing only?I have tried using ServerVariable("HTTP_REFERER") no good, I tried ServerVariable("URL") no good. I am also using Instr(var,"?") to search the url string like this.
Red1 = Requestor.ServerVariable("URL")
Test1 = Instr(Red1,"?")
Test1 is always a 0 because Red1 is always just the refering URL and I need the whole string in address field. I think that I am using the wrong property but I am not sure what is the right property.
View Replies
View Related
Is there any fast way to search for a specific string within all the files in a folder at a same time?
View Replies
View Related
I need to return only string value from a html string
For eg.
<html>aaaa</html>
Currently, i use replace function to replace the html tags to obtain the string aaaa.
But it is tedious as i will need to code all the possible html tag.
View Replies
View Related
I've taken over maintenance of a website running on NT 4, IIS with ASP pages and an MS Access database, but I don't have much experience with this platform. I've got the ASP down pretty well and know SQL, but am having a problem figuring out how to get data for the main page.
On the main page (default.html) I want to display a random business from our database of businesses. Since it's a .html page how can I run server-side code to run the query and select the business? Am I stuck with CGI or is there some other way to do this? I don't want to redirect from the main page to another page, either.
View Replies
View Related
I am having some trouble with getting reliable results with a search string I am using in an ASP page that uses embedded SQL.
In the ASP page, I am using checkboxes for the user to select states to search for records that apply to the selected states. Let's say that I checked the states of [GA][VA][TN]. And, let's say that there is a record with a column "states" which has the states of "AL,GA,FL,VA,TN".
The search criteria I use above will not return that record. However, If I use a search criteria that satifies the leading value of "states" or the trailing value of "states" the result will be returned. But since my search criteria 'breaks apart' the actual value of "states", it is not returned in the search. Why, and how can I make this work better?
View Replies
View Related
I've made my first ASP website that interacts with a detabase. All fairly standard: it can display the entire contents of the db, you can input new items, update and delete items, and I've just started making a search page...[!]
It all works fine if the user just searches with one word, but if they enter more than one word and then press search, I don't know how to split their searchstring up into [an array of?] different strings to search the db with.
Is this even the easiest way to do it, or am I just wasting my time?
View Replies
View Related
I am creating a search page and need help writing the code to build the sql
string.
I have 3 fields on the main page which a user can choose to enter search
terms in any of the 3 fields. My question is how do I write the logic so it
only includes the fields in the search criteria where the user has entered
anything.
Fields are
Production No
Production Title
Synopsis
The user may enter any, all or some of the search teams in the fields.
On the search page I am using lots of if conditions to build my sql string
like
strSQL = "Select * from Productions where "
now after where there are lots of permutations and combination like
production no could be empty or it could be filled in and the other fields
might be empty or filled in as well.
Does someone has a simple logic to build the correct sql String?
View Replies
View Related
I'm trying to split my search string, So I can compare search results if the string was of two words such as: "world news"... But i'm a bit confused of how to do it using this code (FOR EXAMPLE): ....
View Replies
View Related
I'm trying to use the Microsoft Search to search for a text string in a folder full of a bunch of ASP files. Seems like the normal "Search for text in files" program in XP Pro won't search between the ASP delimiters <% %> .
How can I search for text strings in ASP a folder full of ASP files with out opening each one individually and searching?
View Replies
View Related
I want to store HTML content of a URL into a string using ASP is there any provision for that ? for example i have a URL like www.mywebsite.com/default.asp and i want all HTML content of this page into String variable in my ASP page .
View Replies
View Related
I have an ASP search function which, after typing the search term, searches HTML pages and creates a list of links.
The problem is that I do not know how to code so the search term is highlighted in red after the user clicks on the link to view the HTML page.
View Replies
View Related
This is probably simple and I'll kick myself when I see the answer, but I am trying to write a simple if statement that will check to see if a string value is contained within a list of string values. In SQL this is a simple matter with syntax like WHERE status IN ('PT', 'PD', 'PDC', 'DIP', 'TIP') I basically want to do the same thing in my ASP page.
I know I can use code like the following and am doing so now. I'm just looking for a more simple method. Code:
View Replies
View Related
I wish to catch the output of an asp page after it is executed into a
string I.e.
Dim htmlOutput
htmlOutput = someobject.execute("nameoffile.asp")
View Replies
View Related
The following pattern is used to strip HTML tags from a string. I need to remove the tags only if they contain a colon. Is it possible? How can I modify this regexp pattern to match only if a colon exists between the "<" and ">" ? Code:
<[^>]*>
View Replies
View Related
Is it possible to search a string for a upper case character? Here is what I am trying to do:
I have the following string:
Quote: str = "ProjectSectionPlanning"
I'm trying to break this string into:
Quote: str = "Project Section Planning"
View Replies
View Related
I need to convert html into a multiline string which looks something like this:
shtml = "<table border=""0"" cellspacing=""0"" cellpadding=""0""
width=""720"">" & _ "<tr><td width=""100%"" valign=""top""><br>
<!-- MainTable -->" & _
....
Is there a tool that can do this?
View Replies
View Related
I have built dynamic HTMLTable. Now I want to attach it directly to the Email Body - it is already built, so why not to use a ready table. However, I cannot find the way of getting plain HTML text out of dynamically built control. I tried to put my table between div and read div.innerHTML then - HTTP exception has been thrown.
View Replies
View Related
i have an asp page which creates a object using server.createobject and
uses its method. example:
set obj1= server.createobject("test.test") ' test is a dll
tmp = obj1.method() ' it returns a BSTR string.
i want to display tmp in HTML. when i tried to print tmp like
<font><%=tmp%></font>
i get some garbage value.
View Replies
View Related
I am attempting to send an HTML email which a hyperlink that will change based on the user's session ID. I need the hyperlink to display as:
http://www.synergeticsusa.net/admin/shop_cart/detail.asp?id=
WHERE the id = Session("MM_UserID")
However I cannot seem to code this into the html string in the correct syntax, to where id=1 or id=2, etc. Does anyone know the anwser to this problem?The basic code I am using can be found below.
html = html & "<a href=""http://www.synergeticsusa.net/admin/shop_cart/detail.asp?id="">"
html = html & Session("MM_UserID")
html = html & "<IMG SRC=""myImage2.gif""></A><BR><BR>"
html = html & "</br>"
View Replies
View Related
I have a string of HTML (used for a specific purpose) that I'd like to
use somewhere else but as plain text. Rather than introduce a
specifically created plain text version I'd like to strip the tags code
from the HTML version. This in itself is easy, using a function such
as:
Function HTMLDecode(Expression)
Dim sTemp
sTemp = Expression
sTemp = Replace(sTemp, ">", ">", , , 1)
sTemp = Replace(sTemp, "<", "<", , , 1)
'Repeat for each defined entity
HTMLDecode = sTemp
End Function
However, the difficulty comes when trying keep each paragraph seperate.
For example, the string "this is<p>my name" shows on screen as:
this is
my name
if I use the above function, it strips out the <p> tag and shows the
result on one line:
this is my name
I thought I could use something like:
str = replace(str, "<p>", chr(10))
but that doesn't seem to work. Can anyone help me replace <br> and <p>
tags with something that's recognised as "plain" text but will keep the
paragraphs and new lines formatted correctly??
View Replies
View Related
I have a ms access table, which is called students. This table contain data about the students. 3 fields I use for my search form. Gender contains male and female, age contains the age of the students between 15 and 25 and state contains the state where the students are coming from.
Now I would like to search for example all male students who are between 17 and 21 and are from California. Or I would like to search all female students who are between 16 and 19 and are from New York. how the SQL query should look like and to make it work, by that I can see all searched students with their data in the results table?
View Replies
View Related
I created a html form and its data is sent when the submit button is clicked. The files are: rcf.html this for the users to enter their data, rcf_add.asp this page is to show the users their data is recevied, and rcf_view.asp this page is the view all the data that is in the access database.
The problem I am running into is when the submit button is clicked on rcf.html page, it should take the users to the next page (rcf_add.asp) where saying "thank you..." but instead, the code of the rcf_add.asp is displayed. I am going to upload all of my files and if anyone can figure out why please please let me know! I've been trying for the past week.
View Replies
View Related
I have a form on my site that allows someone to enter a date range they want to search for in ASP. I want the From Date to lag behind the To Date by two months automatically?
I know how to make the To Date today's date, but do not know how to make it subtract two months off for the From Date.
The part I know:
<input type="text" name="ToDate" size="8" class="style2" value="<%=Date%>">
The part I don't:
<input type="text" name="ToDate" size="8" class="style2" value="<%=??????????%>
View Replies
View Related
I am trying to implement a search form that lets people find businesses by zip codes with a certain distance (e.g. 10, 20, and 50 miles).what do I need to buy to have the resources to do this? I have seen some zip code databases but I am not sure how to setup the distance from point A to point B and return the results within the distance.
View Replies
View Related
I have set up a search form on our homepage which allows users to search for properties to rent.They enter details like postcode, rent amount, number of beds etc. on the search form, hit submit and matching records from an access database are displayed on a new results page.I want to be to make it easy for the user to review the search criteria and amend it.
Can I get the search criteria to display in another form on the results page or do I just expect the user to hit back to get back to the original completed form. If the Back button is the best method can I add a button/link on the results page to perform the same function as the back button on the toolbar.
View Replies
View Related
i have an access database and i want to create a form using asp to search one or more field(s) and display all the fields in the db online.
you know where i can get help on this or is there such a software where i could buy and do this kind of stuff?
View Replies
View Related
I have a html form, and I like to know how to capture the values in the form after the user hit the submit button. How do I capture these values in an ASP page?
View Replies
View Related