I took another tact. I took the javascript out of the asp because it was syntactically impossible to make the titles links because the javascript needs the single brackets for it to work. So calling the script within a response.write was incompatible. I used the ASP to control the data and write...
Sheco,
That's the point. I have typed it out in raw HTML and Javascript, and it works fine.
When I run the script and view the source code this is what is happening:
this code:
response.Write "<span class=fieldlabel><a href=" & "javascript:ViewDetails(" & "'Project_details.asp?Title=" &...
I tried it and it "really!!" doesn't work with those spaces. This is driving me crazy!! When I close up the spaces I'm back to the original problem. :(
That still a little unclear about what you are telling me.
response.Write "<span class=fieldlabel><a href=" & "javascript:ViewDetails(" & "'Project_details.asp?Title=" & title & "')" & " class=FormField>" & Title & "</a></span><br>"
When I break it apart further it is still only giving me the...
Yes, the function is in an include file. And the function works fine when it is used apart from ASP.
<a href="javascript:ViewDetails('Project_details.asp?Title=<% = rs("Title") %>');" class="FormField">View</a>
When it is is an <a> tag by itself it works like a charm.
When I use this method:
Title=rs("Title")
sUrl = "javascript:ViewDetails('Project_details.asp?Title='" + Server.urlEncode(title) + "'"
response.Write(sUrl)
I am getting this response:
('Project_details.asp?Title='International+Paper+Blox+Cooling+Tower+and+Brine'javascript:ViewDetails
It...
Hi,
I am having trouble with the use of syntax in my ASP code. It is truncating the Title at the first blank space.
The code when it is not involved in a response.write is as follows:
<a href="javascript:ViewDetails('Project_details.asp?Title=<% = rs("Title") %>');" class="FormField">View</a>...
That did the Trick!! :) Do you have to have the single quotes when it is more than one word? I'm asking because I've used this dynamically before but it was a URL so there were no breaks in the line...so that did fine without single quotes.
Thank you...!!!!
Kris ;)
HI!
I am loading distinct Names from a field in a Contractors table to populate a drop down menu, which when you make a choice it will ultimately populate the contractors field in the Projects table. The drop down menu is being populated fine, But when I choose an option and press submit it is...
Hi,
I am trying to use a CDOSys email script that is failing at the .send line. I am used to using ASP Email so I am not familiar with the quirks that come with CDOSys.
Here is the script I am using...
<%
Const cdoSendUsingMethod = _...
I am trying to query my DB with this statement:
<%
set connection = server.createobject("ADODB.Connection")
connection.open session("DBConnString")
Start = Date()
This_Month = DateAdd("d", 30, Date())
SQL = "select * from Events Where Start_Date Between Start AND This_Month"
set rs =...
Hi Candyman,
Thanks for the info. I think this will work although I don't want to redirect to another page using the function.
I want to run the randomizer on click and than populate the text box with that number because the user is going to have to validate that number before being allowed to...
Hi,
I'm not sure how to call a VB function from a form. I want to generate a random number when a button in a form is clicked. This is what I have so far...
The Function:
<%
Dim MyValue
Function Randomize
upperlimit = 5000000.0
lowerlimit = -300000.0
MyValue =Int((upperlimit -...
Thanks DNG!
It is populating correctly now BUT the second half of the code that is supposed to be displaying the job titles for the selection isn't happening. I wrote the code very similar to what I have here and it works great for a keyword search. But this doesn't seem to be getting the...
I am trying to populate dropdown options in a form so the user can make the selection and when they hit submit the jobs the contractor is involved with will show in another section of the page. I have 13 records in the database. As of now it is populating the options with one record 13 times. I...
Thanks DNG...I found my stupid mistake! "C_Title Not Title"
After a while go blind looking at this stuff. A pair of fresh eyes usually does the trick! It working fine though. I will definetly try it your way--a lot less code! I will get back to you and let you know...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.