On Sat, Jan 20, 2001 at 05:20:53PM -0800, Alex Black wrote : 
> no without submitting information to the server with get or post.
> 
> for example, if a bit of javascript you have comes up with some value, the
> only way you can get it to the server is to put it in a get and send the
> user to that url:
> 
> http://www.mysite.com/index.php?your_js_var=your_value

        With 'post' methods its also possible this way (works NS
and IE):

<script language="JavaScript"><!--
        function do_something( form) {
                form.jsvar.value = form.bla.selcetedIndex;
                form.submit();
                return true;
        }
//--></script>

<form name="mainform", action="<?echo$PHP_SELF?>" methos="post">
<input type="hidden" name="jsvar" value="">

<selcet name="bla">
<option> foo
<option> bar
</select>

<input type="button" onclick="do_something( document.mainform)" value="click">

</form>


You know have set the phpvar $jsvar from within javascript.

m.

-- 
Markus Fischer,  http://josefine.ben.tuwien.ac.at/~mfischer/
EMail:         [EMAIL PROTECTED]
PGP Public  Key: http://josefine.ben.tuwien.ac.at/~mfischer/C2272BD0.asc
PGP Fingerprint: D3B0 DD4F E12B F911 3CE1  C2B5 D674 B445 C227 2BD0

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to