Posted by Toby A Inkster on 11/19/07 08:41
pradnya wrote:
> How to share/use a variable between PHP and HTML on the same page ?
> ( i.e. without using GET/ POST etc.... )
>
> Is it possible ?
Not sure what you mean. HTML doesn't have "variables".
> And what about same with PHP and JavaScript ?
Depending on what you want to achieve there are several techniques. You
can use PHP to generate the Javascript in the first place, which allows
PHP to populate the script's variables with certain values. Or a piece of
Javascript can communicate with a PHP script using AJAX.
--
Toby A Inkster BSc (Hons) ARCS
[Geek of HTML/SQL/Perl/PHP/Python/Apache/Linux]
[OS: Linux 2.6.12-12mdksmp, up 12 days, 15:35.]
USD/EUR Exchange Rate Graph
http://tobyinkster.co.uk/blog/2007/11/18/usd-eur/
Navigation:
[Reply to this message]
|