ahill Posted June 18, 2015 Share Posted June 18, 2015 (edited) Here is what I have right now. I want the page to change the header when the page is reloaded based on what is selected. <h2> <% If tom = " " and jan = " " and jake= " " then response.write (" welcome") ElseIf tom <> " " and jan = " " and jake= " " then response.write ("hello") %> </h2> <% If tom = " " and jan = " " and jake= " " then SQL statement ElseIf tom <> " " and jan = " " and jake = " " then SQL statement End If SOME OTHER CODE Reload %> Edited June 18, 2015 by ahill Link to comment Share on other sites More sharing options...
justsomeguy Posted June 18, 2015 Share Posted June 18, 2015 Which part do you need help with? Is that all the code? Where are those variables coming from? Link to comment Share on other sites More sharing options...
ahill Posted June 18, 2015 Author Share Posted June 18, 2015 no all of the code is not there. i have a string of code that pulls from my sql so my page posts a table with clickable images that reloads into the same page. Now I am trying to make my header of the <div> change every time the page reloads with the next selection in the page. Everything on the page works, I just wana make the header change based on the selection of the page when it reloads. I unfortunately cant post the full code because it is for a company. Link to comment Share on other sites More sharing options...
justsomeguy Posted June 18, 2015 Share Posted June 18, 2015 Well, the general idea behind the code you posted above will work. I guess I can't say if it's the best way to do something like that in your case, but the idea should work. Link to comment Share on other sites More sharing options...
ahill Posted June 19, 2015 Author Share Posted June 19, 2015 (edited) It works for the first greeting but does not change to the second greeting when selected, as it still displays the first one. Edited June 19, 2015 by ahill Link to comment Share on other sites More sharing options...
justsomeguy Posted June 19, 2015 Share Posted June 19, 2015 There's not enough code there for me to suggest anything. Does that mean that the conditions in your if statements aren't correct? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now