Alas, more problems with forms =)

Well now, here is my problem. I have a form, "method" is set to "post", and
action is set to the same page. I also have a hidden field named
"form_post" and it's value is "1".

Underneath this form is my PHP script.

<?php

if (isset($form_post))
   {
    echo "Function \"isset\" called. Values are...<br>\n
     Title: $title<br>\n
     Author: $author<br>\n
     Lead Actors: $actors<br>\n
     Poster: $poster<br>\n
     Summ.: $summery<br><br>\n\n
     Rev.: $review<br><br>\n\n";
    verify();        // Function call to verify
   } else {
    exit;
   }    // Since form_post is set, it proceeds to verify. Strangley enough,
all the values appear in this if block.


function verify()
   {

    echo "Verify called. Values are...<br>\n
     Title: $title<br>\n
     Author: $author<br>\n
     Lead Actors: $actors<br>\n
     Poster: $poster<br>\n
     Summ.: $summery<br><br>\n\n
     Rev.: $review<br><br>\n\n";
   }

In the function "verify" no values appear, just:

Title:
Author:
Lead Actors:
Poster:
Summ.:

Rev.:

Although -- as the comment said -- the if block shows all the values just
fine.


What could possibly be wrong? The solution to my last problem was to get rid
of any functions. However, that results in highly messy code! There has got
to be a way of having values passed to a function.

Thanks for any help/suggestions.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to