Running code from a PHP button

Can someone tell me where I am going wrong in this PHP code:

In my PHP form:
printf("");

In the page header:

<?php function logout() { $uid = ""; print ""; } ?>

You’re trying to call PHP directly with javascript. That isn’t possible.

Change the block of code in the header to:
[php]?>

<?php[/php]
Sponsor our Newsletter | Privacy Policy | Terms of Service