What wrong wit hthis line?

Discussion in 'PHP' started by nrodes, Jan 19, 2009.

  1. #1
    i got the error:
    here is line 9. i cant seem to figure out what wrong with it.
    if($dir!=null && $pass!=null)
    PHP:
    does anyone know whats wrong?

    thanks
     
    nrodes, Jan 19, 2009 IP
  2. qualityfirst

    qualityfirst Peon

    Messages:
    147
    Likes Received:
    6
    Best Answers:
    1
    Trophy Points:
    0
    #2
    Post the surrounding code.

    PHP was not expecting the if statement.
     
    qualityfirst, Jan 19, 2009 IP
  3. gnp

    gnp Peon

    Messages:
    137
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #3
    please show the code up to line 9, as the error might be before line 9 ..
     
    gnp, Jan 19, 2009 IP
  4. nrodes

    nrodes Peon

    Messages:
    77
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    heres code to line 9
    <?php
    
    //get form data and set var
    $pass=$_POST["pass"];
    $dir=$_POST["dir"];
    $dest="/"
    
    //check null form
    if($dir!=null && $pass!=null)
    [php]
    PHP:
     
    nrodes, Jan 19, 2009 IP
  5. Dox5

    Dox5 Peon

    Messages:
    35
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #5
    $dest="/"

    I think that line should end with a ;
     
    Dox5, Jan 19, 2009 IP
  6. nrodes

    nrodes Peon

    Messages:
    77
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    ya, ur right. i just realized that. sry to bother you guys about it
     
    nrodes, Jan 19, 2009 IP