Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Feb 2005
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Another pair of eyes...

    Can someone take a quick look? I'm getting the lovely message: Parse error: parse error, expecting `T_VARIABLE' or `'$'' in /usr/local/apache/htdocs-dev-secure/Res_Life/Submit_Application.php on line 23

    I've been looking and I can't seem to find it....

    Code:
    //set variables
    Line 20 is here $Application_Date = $_POST['Application_Date'];
    $Sem_ApplyFor = $_POST['Sem_ApplyFor'];
    $Position_Requested = $_POST['Position_Requested'];
    $1st_Pref = $_POST['1st_Pref'];
    $2nd_Pref = $_POST['2nd_Pref'];
    $3rd_Pref = $_POST['3rd_Pref'];
    $4th_Pref = $_POST['4th_Pref'];
    $5th_Pref = $_POST['5th_Pref'];
    $SIRP_Pref = $_POST['SIRP_Pref'];
    $Resume = $_POST['Resume'];
    $Quest1 = $_POST['Quest1'];
    $Quest2 = $_POST['Quest2'];
    $Quest3 = $_POST['Quest3'];
    $Quest4 = $_POST['Quest4'];
    $Quest5 = $_POST['Quest5'];
    $Quest6 = $_POST['Quest6'];
    $Quest7 = $_POST['Quest7'];
    $Dietary_Needs = $_POST['Dietary_Needs'];
    $TShirt_Size = $_POST['TShirt_Size'];
    
    //set up the query
    $query = "INSERT INTO ApplicationTbl(CampusID,Application_Date,Sem_ApplyFor,Position_Requested,1st_Pref,2nd_Pref,3rd_Pref,4th_Pref,5th_Pref,SIRP_Pref,Resume,Quest1,Quest2,Quest3,Quest4,Quest5,Quest6,Quest7,Dietary_Needs,TShirt_Size)VALUES('" .$_SESSION['Campus_ID'] . "','" . $Application_Date . "','" . $Sem_ApplyFor . "','" . $Position_Requested . "','" . $1st_Pref . "','" . $2nd_Pref . "','" .$3rd_Pref . "','" . $4th_Pref . "','" . $5th_Pref . "','" . $SIRP_Pref . "','" . $Resume . "','" . $Quest1 . "','" . $Quest2 . "','" . $Quest3 . "','" . $Quest4 . "','" . $Quest5 . "','" . $Quest6 . "','" . $Quest7 . "','" . $Dietary_Needs . "','" . $TShirt_Size . "')";
    //do the query
    $result=mysql_query($query) or die ("Query failed: " . mysql_error() . " Actual query: " . $query);
    Thanks for any help.

    Laura

  • #2
    teh Moderatorinator
    Join Date
    Sep 2004
    Location
    USA
    Posts
    2,472
    Thanks
    4
    Thanked 40 Times in 40 Posts
    Hi,

    variables can't start with numbers

    http://us3.php.net/language.variables

  • #3
    New Coder
    Join Date
    Feb 2005
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Dang. Thanks for that.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •