Jump to content

[SOLVED] Please Help Me! PHP and MySQL


Recommended Posts

I am trying to make a e-mail script that will e-mail a someone ever minuet using there e-mail they input.


Well I get this error on the insert.php (add's the e-mail to the database)


Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /mounted-storage/home48c/sub007/sc33591-LWQU/uploads/vote/insert.php on line 13


line 13 is blank. ??


Here is the whole script


include ("config.php");

// connect to the mysql server

$link = mysql_connect($server, $db_user, $db_pass)
or die ("Could not connect to mysql because ".mysql_error());

// select the database

or die ("Could not select database because ".mysql_error());

// insert the data

// always set a form condiction.....


//<<<<dont post within database statements......


$insert = mysql_query("insert into $table values ('$email')");
or die("Could not insert data because ".mysql_error());

// print a success message
echo "E-Mail Added To Database, starting to e-mail.";
echo "<meta http-equiv=Refresh content=2; URL=mailing.php>";



-Thanks Guys


Link to comment
Share on other sites

This thread is more than a year old. Are you sure you have something important to add to it?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.