[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
Re: [ic] set variable using Javascript???
Wouldn't that form have to be submitted for that value to be passed
to the next page?
At 13:22 -0700 7/3/01, Dan B wrote:
>At 03:20 PM 7/3/2001 -0400, you wrote:
>>I am working on a site that has a dhtml menu. We have three
>>versions of the navigation and when someone first comes to the site
>>we redirect them to an index page which sets a menutype variable.
>>
>>The problems is if someone come to the site directly to a page
>>other than the index this variable never gets set. Detecting which
>>browser they have is no problem but can I set a variable using
>>javascript?
>
>You can set [value]'s via javascript. E.g., use a hidden form value.
>
><INPUT type=hidden name=browsertype>
>
><SCRIPT>
> function set_browser(form) {
> form.browsertype.value = "Netscape";
> return 0;
> }
></SCRIPT>
>
>You also need something to call set_browser(this.form), probably
>best from <BODY ... onLoad()> or whatever it is.
>
>on the next page (or in mv_check) you can access it with:
>
>[value browsertype]
>
>I hope that helps,
>
>Dan Browning, Cyclone Computer Systems, danb@cyclonecomputers.com
>
>_______________________________________________
>Interchange-users mailing list
>Interchange-users@lists.akopia.com
>http://lists.akopia.com/mailman/listinfo/interchange-users
Scott Trunkhill 725 Broad St
Product Research Specialist Augusta, GA 30901
Morris Communications (706) 823-3203
trunk@morris.com
http://morris.com