within the js file I create all of my menu's. Now I have a session variable set very early in the piece;
I want to see what the value of the seesion variable is in the javascript code to see if certain menu's should be setup or not. I have tried all sorts of variations of coding to see what the coding should be, and none seem to work. Code:
I have a menu that I use on my Intranet app, and while I did try to replace it recently, I ended up going back to it. It's built entirely with javascript, and works great.
However, there are certain pages where I would like to be able to put an item into a querystring for a link. That is, I might have a link which is worded "Add to this ticket" and the hyperlink associated with that text is along the lines of "addtoticket.asp?ticketid=1000"
I am not able to figure out how to have an ASP variable into a link built by javascript. This is the main question. How can I have the ASP variable in a javascript?
Because it's Inranet, I don't have the page to show you. However, I have zipped up the two javascript files and placed them at www.middletree.net/js.zip
Also, in this case, IE-specific code will not be a problem. 100% of users are on IE5+
I have an asp page that is needing to validate data against database but to do so I need to pull in a key value from another web page. I can get the key value in ASP using the following javascript code:
<script> var main = opener.opener; var currQuote = main.document.forms[0].quotenum.value; </script>
My problem is trying to figure out how to use currQuote in the ASP code surrounding the script. There's got to be a way to do it - I'm just burnt out trying to figure it out.
I'm trying to take an ASP session variable and pass it into a javascript function with little success. As the page loads, the session variable is there and the javascript function is called as an include.
I've tried silly ideas like option explicit and using asp to write the javascript declaration of the variable.
I have a search function that is reading companies from a database via ASP and spitting out the results. I have various fields of each company in variables and I want to be able to create a link that uses Javascript to copy the address to the clipboard.
I know there is the javascript:window.clipboardData.getData(), but I can't get to parse the ASP variable through. Does anyone know how I can do this.
I got that right now but i want the variable, console to be placed along with news so when it selects from the db it selects from gcnnews or whatever variable it's on. How do I do that?
I need to assign a value to a variable, but this variable name is dependant upon another variable!! I am including the code below so you can see it, cos if not I am sure you are thinking whattt?? Code:
I'm having a customer submit an order. When they submit it, it posts to a page that processes the order and inserts into our database, while displaying a summary of their order. I have a javascript function that will cause a "confirm" box to show up if an order seems like it might be a duplicate. However, I can't seem to get the code to "wait" for the response from that box, which I guess makes some sense. Am I stuck with having an interim page or doing something with posts or is there an easy way to get the record to not insert until the user responds to the confirm box?
Im sure it exists but i am having some difficulty finding it. I need come code to take out any SPACES in a textbox when text is entered OR submitted. Example
i have a text box where people can enter there car registration.
To keep consistency thoughout my site, i want L736 VAF to be entered into the database as L736VAF.
so that when it is recalled via a search form, L736VAF wont be returned as "no record found" because some one has put a space init!
update some long commOn first page I display all the records from database (working well). Then first column has href which opens a popup (i am passing rownum from database to popup). I was hoping to run ASP code on load of the page so the comments which is already there for that row in the databse automatically comes in a textarea. And then you can edit and hit update. And this will update the database. Also I was thinking of using session variables for the rownum. But bcos I have href which opens a popup, I am not sure how i can set the session variable. I dont want to pass the "comments" itself to the next page bcos it can be really long comment and QueryString has some limitations.
I am making a dynmanic form that goes to a question depended on the answer. Is there a way that I can make it remember what the person selected (radio button) in the question so that I don't have to write something like,
"<input type = 'radio' name='Question3' value='Yes' checked <% if Question3 = "Yes" then response.write "SELECTED" end if%>>Yes<BR>" + ????
i have an asp page which shows a list of articles which are pulled from the database. I have a variable as below which defines number of records to show on each page
<%
numRows = 5 %>
Now i also have a drop down list from which you can choose 'display 5 records per page', display 10 records per page' and so on.What i want is when a new value is chosen from the list, the page refreshes and the ASP variable numRows is set to this new value.
I'd like to put some SQL values in my Javascript which is defined in de Head section If I put it in there like <%objrs=("field")%>, the script does not seem to run ?
I have a page that opens a javascript modal window and passes a variable. I then have that variable in Javascript. Is there anyway for me to get the value of that variable in asp. I am passing an id and want to check what the id is and open my recordset accordingly.
Is there a way that I can refresh a combo box using javascript after I select data from a another combo box? I can't seem to find the answer to this question. I'm guessing after I select the item in the first combo I could requery the database and display the correct informtion based off of it. I just don't know where to start. I've searched all over the internet.