hogtied
01-30-2003, 12:36 AM
Hello members,
I have a script (thanks to beettle) that parses the HTTP substring for variables.
Goal: I'm trying to make a universal page that will swap out pics and text.
(ie click on solider of fortune link would go to the universal page and display SOF pics and text.
click on unreal link would go to the same universal page and display its unreal pics and text.)
so far I got the specific pics to be displayed.
Problem: I have a hidden field that also uses the substring variable. But when submitted the value does not get sent.
Here's the jscript
var g = parseGetVars();
var arSpace = new Array();
var space = g.games.split(/\+/);
document.write('<img src=\"images/games/logo_' + space[0] + space[1] + '.gif\"><input type=\"hidden\" value=\"' + g.games+ '\" name=\"name\">');
I have the script to split by plus signs in case of more than one word. How can I check to see if the string contains a plus sign or not. REASON: if it does not contain a plus sign then the pic and text does not display. In either case the value does not get sent when clicking submit...
Thanks,
Hogtied :confused:
I have a script (thanks to beettle) that parses the HTTP substring for variables.
Goal: I'm trying to make a universal page that will swap out pics and text.
(ie click on solider of fortune link would go to the universal page and display SOF pics and text.
click on unreal link would go to the same universal page and display its unreal pics and text.)
so far I got the specific pics to be displayed.
Problem: I have a hidden field that also uses the substring variable. But when submitted the value does not get sent.
Here's the jscript
var g = parseGetVars();
var arSpace = new Array();
var space = g.games.split(/\+/);
document.write('<img src=\"images/games/logo_' + space[0] + space[1] + '.gif\"><input type=\"hidden\" value=\"' + g.games+ '\" name=\"name\">');
I have the script to split by plus signs in case of more than one word. How can I check to see if the string contains a plus sign or not. REASON: if it does not contain a plus sign then the pic and text does not display. In either case the value does not get sent when clicking submit...
Thanks,
Hogtied :confused: