致命错误:调用未定义的函数displayStep1()

i want to create a multiple step form, but i am now having problem with displayStep1(). please help me to find out my problem and to solve. thanx to all.

Fatal error: Call to undefined function displayStep1()

 if ( isset( $_POST["up_login"] ) and $_POST["up_login"] == 'up_login' )
 {
     include 'forms/up_login.php';
 } 
 elseif ( isset( $_POST["up_info"] ) and $_POST["up_info"] == 'up_info' )
 {

    if ( isset( $_POST["step"] ) and $_POST["step"] >= 1 and $_POST["step"]<= 5 ) 
    {
        call_user_func( "processStep" . (int)$_POST["step"] );
    } 
    else 
    {
        displayStep1();
    }

    function processStep1() 
    {
        displayStep2();
    }
    function processStep2() 
    {
        if ( isset( $_POST["continue"] ) and $_POST["continue"] =="< Back" ) 
        {
            displayStep1();
        } 
        else 
        {
            displayStep3();
        }
    }
    function processStep3() 
    {
        if ( isset( $_POST["continue"] ) and $_POST["continue"] =="< Back" ) 
        {
            displayStep2();
        } 
        else 
        {
            displayComplete();
        }
    }
    function processStep4() 
    {
        if ( isset( $_POST["complete"] ) and $_POST["complete"] =="< Back" ) 
        {
            displayStep3();
        } 
        else 
        {
            displaySuccess();
        }
    }

    function displayStep1() 
    {

     include 'update_step1.php';            

    }
    function displayStep2() 
    {

     include 'update_step2.php';            

    }
    function displayStep3() 
    {

     include 'update_step3.php';            

    }
    function displayComplete() 
    {

     include 'update_step4.php';            

    }
    function displaySuccess() 
    {

     include 'update_step1.php';            

    }

 }
 else
 {
     include 'forms/up_account.php';
 }

This function:-

function displayStep1() 
    {

     include 'update_step1.php';            

    }

should be placed before it is called.

Put your functions out from IF, your don't need create a function into the if, eg:

First:

function displayStep1(){/* ... */} 

After, continue with the code.

Make this for your all functions.