Results 1 to 16 of 16

Thread: Unexpected T_string
      
   

  1. #1
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Unexpected T_string

    Anyone know what this means?
    I find it when I publish the action.php page after I've copied the code into the HTML.
    www.hamiltonhomereview.com/househunters.html
    Bob

  2. #2
    Watdaflip's Avatar
    Watdaflip is offline Major General
    Join Date
    Sep 2005
    Location
    Cincinnati, Ohio
    Posts
    2,119

    Default Re: Unexpected T_string

    Post the code for action.php, you probably have some text that isn't enclosed in a " " or ' ', or something like

    echo "blah blah " blah " blah "; where the third blah isn't enclosed in quotes.

    If I see the code I can fix the error

    Register/Login Script
    Do you use a Password Protected Directory? Need a way to allow users to make their own account, try my .htaccess Login Script

  3. #3
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Thanks. I'm trying other things and am getting confused but I'll go back to step one and check everything.

  4. #4
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Here's the code I'm using on my test page which only has one field and the submit button. The page is: www.hamiltonhomereview.com/househunterstest.html


    <?PHP
    $mailto = "bmorrow@execs.com";
    $email = $HTTP_POST_VARS['email'];
    if ($email == "") {
    $email = $mailto;
    }
    $mailsubj = "Jointheclub";
    $mailhead = "From: $email\n";
    reset ($HTTP_POST_VARS);
    $mailbody = "name","Button1":\n";
    while (list ($key, $val) = each ($HTTP_POST_VARS))
    {
    if ($key!="submit")
    {
    $mailbody .= "$key : $val\n";
    }
    }
    mail($mailto, $mailsubj, $mailbody, $mailhead);
    ?>

  5. #5
    navaldesign's Avatar
    navaldesign is offline General & Forum Moderator
    Join Date
    Oct 2005
    Location
    Italy
    Posts
    12,115

    Default Re: Unexpected T_string

    Quote Originally Posted by bmorrow View Post
    Here's the code I'm using on my test page which only has one field and the submit button. The page is: www.hamiltonhomereview.com/househunterstest.html


    <?PHP
    $mailto = "bmorrow@execs.com";
    $email = $HTTP_POST_VARS['email'];
    if ($email == "") {
    $email = $mailto;
    }
    $mailsubj = "Jointheclub";
    $mailhead = "From: $email\n";
    reset ($HTTP_POST_VARS);
    $mailbody = "name","Button1":\n";
    while (list ($key, $val) = each ($HTTP_POST_VARS))
    {
    if ($key!="submit")
    {
    $mailbody .= "$key : $val\n";
    }
    }
    mail($mailto, $mailsubj, $mailbody, $mailhead);
    ?>
    The line in red is wrong, should be something like

    $mailbody = "Info submitted from our web form : \n";

    Why did you place "name" and "Button1" in there ?
    Navaldesign
    Logger Lite: Low Cost, Customizable, multifeatured Login script
    Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
    DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
    Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!


  6. #6
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    I thought you were supposed to name the fields. I guess not.

  7. #7
    Watdaflip's Avatar
    Watdaflip is offline Major General
    Join Date
    Sep 2005
    Location
    Cincinnati, Ohio
    Posts
    2,119

    Default Re: Unexpected T_string

    If you want to use submitted data you need to do 2 things

    1) create a variabled

    $name

    2) retrieve the posted data from the form

    $name = $_POST['name'];

    Register/Login Script
    Do you use a Password Protected Directory? Need a way to allow users to make their own account, try my .htaccess Login Script

  8. #8
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Thank you so much for your help Watdaflip and naval design. The form works great, the most complicated page I've done yet. Should boost my prospect marketing targets immensely.
    One other question that's not related. When I relaunch my site, I won't need some of the old published pages. How do I erase them off the web?

  9. #9
    Andy128's Avatar
    Andy128 is offline Major General
    Join Date
    Dec 2005
    Location
    Michigan
    Posts
    2,322

    Default Re: Unexpected T_string

    Use the FTP Manager. This will bring up a window of files on your computer on the left and on the right -will be the files on your server. Delete those that you desire off the server. !!Once you delete them from the server- they are gone....gone...gone...- so make sure they are the ones you want deleted.

    Andy
    PHP- is a blast!

  10. #10
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Thanks Andy, that's awesome! It's so simple when you've got help.

  11. #11
    Andy128's Avatar
    Andy128 is offline Major General
    Join Date
    Dec 2005
    Location
    Michigan
    Posts
    2,322

    Default Re: Unexpected T_string

    You are very welcome.

    Andy
    PHP- is a blast!

  12. #12
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Okay, went too fast. I got into FTP Manager through the Cpanel but have no clue what to do then. How do I log in to get to the columns you speak of?

  13. #13
    Andy128's Avatar
    Andy128 is offline Major General
    Join Date
    Dec 2005
    Location
    Michigan
    Posts
    2,322

    Default Re: Unexpected T_string

    Not through cpanel. Open the BV web builder program and then click on Tools and then FTP Manager ( I believe as I am not at my computer) Then click on connect on the left side under the Menu Bar. This will allows you to move or FTP files, pages, photos, folders from computer to server and vice versa. You can also use it to delete files, folders, photos,etc.... Simply right click on the file, folder, webpage and then choose delete.

    Andy
    PHP- is a blast!

  14. #14
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    Okay, now I feel really stupid. WHen I open up Blue Voda, I don't see Tools anywhere. I see Toolbar and all the tools used to work on a page, but no FTP Manager.

  15. #15
    navaldesign's Avatar
    navaldesign is offline General & Forum Moderator
    Join Date
    Oct 2005
    Location
    Italy
    Posts
    12,115

    Default Re: Unexpected T_string

    Do you have the top Text toolbar ? The one saying File Edit View Insert Format ....... Tools Window Help ? If not, right click on any part of the top bar and when the menu opens, check the "Menubar" checkbox.
    Navaldesign
    Logger Lite: Low Cost, Customizable, multifeatured Login script
    Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
    DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
    Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!


  16. #16
    bmorrow is offline Sergeant First Class
    Join Date
    Oct 2006
    Posts
    57

    Default Re: Unexpected T_string

    I'm missing something guys. When I go into Blue Voda, and right click at the top of the page, I only get three pull down menu options: File, View, Help. There is no Tools, Insert, etc.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49