How to put a php variable into javascript

Hi I am haveing an issue inserting php variables into javascript can it be done?

<script type="text/javascript"> var _SKYAUTH = { loginUrl:'REPLACE WITH FULL LOGIN URL', memberNick:'REPLACE WITH CONTEXT CODE TO GET MEMBER USER NAME', memberId:'REPLACE WITH CONTEXT CODE TO GET MEMBER ID', profileUrl:'REPLACE WITH MEMBER PROFILE URL', photoUrl:'REPLACE WITH MEMBER PHOTO URL' }; </script>
I need the two varaibles to be inserted into the above script.
[php]membernick = $user
memberid= $member_id
[/php]

am new to this many thanks in advacen

Echo or print the variable.

Sponsor our Newsletter | Privacy Policy | Terms of Service