I want to use php function in the java script
Moderator: General Moderators
I want to use php function in the java script
Iwant to use php function in the javascript pls help me.
Re: I want to use php function in the java script
i hv been made to realise the truth that trying to do somthing even u dont get it will widen ur knowledge.
try writin out some things then u can b corrected, u can always do better than u think. Bro

try writin out some things then u can b corrected, u can always do better than u think. Bro
Re: I want to use php function in the java script
"AOL speak" is against the rules here. Don't use it again please.iris wrote:i hv been made to realise the truth that trying to do somthing even u dont get it will widen ur knowledge.
try writin out some things then u can b corrected, u can always do better than u think. Bro
- mattcooper
- Forum Contributor
- Posts: 210
- Joined: Thu Mar 17, 2005 5:51 am
- Location: London, UK
Re: I want to use php function in the java script
Yeah, whatever, maybe stick to talking about PHP rather than getting all spiritual?iris wrote:i hv been made to realise the truth that trying to do somthing even u dont get it will widen ur knowledge.
try writin out some things then u can b corrected, u can always do better than u think. Bro
I think what you want to do is use values that are passed to PHP variables in your Javascript, in which case you can. Simply give your Javascript file a .js.php extension and then use whatever PHP code you want. so, for example:
Code: Select all
<script>
//script.js.php
document.getElementById('el').innerHTML = "<?php echo $yourValue ?>";
</script>
Re: I want to use php function in the java script
mattcooper wrote:Yeah, whatever, maybe stick to talking about PHP rather than getting all spiritual?
- mattcooper
- Forum Contributor
- Posts: 210
- Joined: Thu Mar 17, 2005 5:51 am
- Location: London, UK
Re: I want to use php function in the java script
Yar, I find time-wasters ever so tiresome <yawns>
Re: I want to use php function in the java script
Pls wat does "AOL" means? Pls!!!!!