Jump to content

help: pass variables from javascript to php


general

Recommended Posts

i'm writing a calendar code and all the php/mysql coding works great. but to make the calendar update without refreshing the whole page, i've made it so that javascript writes the php code into a div tag.

Now, i dont know javascript very well. can one of u guys tell me how to pass variables from javascript to php?
the php will run before the page loads, so writing php into a div tag using js wouldn't accomplish anything.  You can pass variables by using hidden forms and giving their value with js, and then submitting the form to be handled by a php script.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.