If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
This is the error:
Parse error: parse error, unexpected T_VARIABLE in /srv/www/htdocs/sendinfo.php on line 45
This is the code:
<?php
$fname=$_POST['fname'];
$lname=$_POST['lname'];
$address=$_POST['address'];
$address2=$_POST['address2'];
$address3=$_POST['address3'];
$citye=$_POST['city'];
$state=$_POST['state'];
$zip=$_POST['zip'];
$phone=$_POST['phone'];
$email=$_POST['email'];
$subject="Data Added";
$f*******@YYY.com;
$ipaddress = $_SERVER['REMOTE_ADDR'];
mail("XX*@XXX.com",$subject, "Street Address: $address\r\nCity:$city\r\nZip: $zip\r\nIP: $ipaddress", "FROM: $from\r\n");
echo "Your IP address is: $ipaddress";
?>
<?php
$username="XXX";
$password="XXXX";
$database="XXXX";
$localhost="localhost";
$fname= mysql_escape_string($_POST['fname']);
$lname= mysql_escape_string($_POST['lname']);
$address= mysql_escape_string($_POST['address']);
$address2= mysql_escape_string($_POST['address2']);
$address3= mysql_escape_string($_POST['address3']);
$city= mysql_escape_string($_POST['city']);
$state= mysql_escape_string($_POST['state']);
$zip= mysql_escape_string($_POST['zip']);
$phone= mysql_escape_string($_POST['phone']);
$email= mysql_escape_string($_POST['email']);
$ipaddress=mysql_escape_string($_SERVER['REMOTE_ADDR']
$conn=mysql_connect($localhost, $username, $password) or die("Unable to setup connection"); //This is the line the error is referencing
mysql_select_db($database,$conn) or die( "Unable to select database");
$query = "INSERT INTO leads VALUES('$fname','$lname','$address','$address2','$ address3','$city','$state','$zip','$phone','$email ',$ipaddress)";
echo $query;
mysql_query($query) or die("Error: ".mysql_error());
mysql_close();
?> 17 2210
I got it, Thanks!!
"SuSe newbie" <jk******@sc.rr.com> wrote in message news:Tp*********************@twister.southeast.rr. com...
If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
This is the error:
Parse error: parse error, unexpected T_VARIABLE in /srv/www/htdocs/sendinfo.php on line 45
This is the code:
<?php
$fname=$_POST['fname'];
$lname=$_POST['lname'];
$address=$_POST['address'];
$address2=$_POST['address2'];
$address3=$_POST['address3'];
$citye=$_POST['city'];
$state=$_POST['state'];
$zip=$_POST['zip'];
$phone=$_POST['phone'];
$email=$_POST['email'];
$subject="Data Added";
$f*******@YYY.com;
$ipaddress = $_SERVER['REMOTE_ADDR'];
mail("XX*@XXX.com",$subject, "Street Address: $address\r\nCity:$city\r\nZip: $zip\r\nIP: $ipaddress", "FROM: $from\r\n");
echo "Your IP address is: $ipaddress";
?>
<?php
$username="XXX";
$password="XXXX";
$database="XXXX";
$localhost="localhost";
$fname= mysql_escape_string($_POST['fname']);
$lname= mysql_escape_string($_POST['lname']);
$address= mysql_escape_string($_POST['address']);
$address2= mysql_escape_string($_POST['address2']);
$address3= mysql_escape_string($_POST['address3']);
$city= mysql_escape_string($_POST['city']);
$state= mysql_escape_string($_POST['state']);
$zip= mysql_escape_string($_POST['zip']);
$phone= mysql_escape_string($_POST['phone']);
$email= mysql_escape_string($_POST['email']);
$ipaddress=mysql_escape_string($_SERVER['REMOTE_ADDR']
$conn=mysql_connect($localhost, $username, $password) or die("Unable to setup connection"); //This is the line the error is referencing
mysql_select_db($database,$conn) or die( "Unable to select database");
$query = "INSERT INTO leads VALUES('$fname','$lname','$address','$address2','$ address3','$city','$state','$zip','$phone','$email ',$ipaddress)";
echo $query;
mysql_query($query) or die("Error: ".mysql_error());
mysql_close();
?>
SuSe newbie wrote: If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
<code snip>
Missing semicolon on line above one with the error
~Cameron
I got it, Thanks!!
"SuSe newbie" <jk******@sc.rr.com> wrote in message news:Tp*********************@twister.southeast.rr. com...
If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
This is the error:
Parse error: parse error, unexpected T_VARIABLE in /srv/www/htdocs/sendinfo.php on line 45
This is the code:
<?php
$fname=$_POST['fname'];
$lname=$_POST['lname'];
$address=$_POST['address'];
$address2=$_POST['address2'];
$address3=$_POST['address3'];
$citye=$_POST['city'];
$state=$_POST['state'];
$zip=$_POST['zip'];
$phone=$_POST['phone'];
$email=$_POST['email'];
$subject="Data Added";
$f*******@YYY.com;
$ipaddress = $_SERVER['REMOTE_ADDR'];
mail("XX*@XXX.com",$subject, "Street Address: $address\r\nCity:$city\r\nZip: $zip\r\nIP: $ipaddress", "FROM: $from\r\n");
echo "Your IP address is: $ipaddress";
?>
<?php
$username="XXX";
$password="XXXX";
$database="XXXX";
$localhost="localhost";
$fname= mysql_escape_string($_POST['fname']);
$lname= mysql_escape_string($_POST['lname']);
$address= mysql_escape_string($_POST['address']);
$address2= mysql_escape_string($_POST['address2']);
$address3= mysql_escape_string($_POST['address3']);
$city= mysql_escape_string($_POST['city']);
$state= mysql_escape_string($_POST['state']);
$zip= mysql_escape_string($_POST['zip']);
$phone= mysql_escape_string($_POST['phone']);
$email= mysql_escape_string($_POST['email']);
$ipaddress=mysql_escape_string($_SERVER['REMOTE_ADDR']
$conn=mysql_connect($localhost, $username, $password) or die("Unable to setup connection"); //This is the line the error is referencing
mysql_select_db($database,$conn) or die( "Unable to select database");
$query = "INSERT INTO leads VALUES('$fname','$lname','$address','$address2','$ address3','$city','$state','$zip','$phone','$email ',$ipaddress)";
echo $query;
mysql_query($query) or die("Error: ".mysql_error());
mysql_close();
?>
thanks Cameron,
now i'm getting an error on that line for
Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on
line 43
any ideas??
"Cameron" <fo*@bar.invalid> wrote in message
news:bv**********@news5.svr.pol.co.uk... SuSe newbie wrote: If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!! <code snip>
Missing semicolon on line above one with the error
~Cameron
SuSe newbie wrote: thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on line 43 any ideas?? "Cameron" <fo*@bar.invalid> wrote in message news:bv**********@news5.svr.pol.co.uk...
SuSe newbie wrote:
If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
<code snip>
Missing semicolon on line above one with the error
~Cameron
ah yes sorry, on the same line that had the missing semicolon there is
also a missing ) so it should end with );
Missing closing parentheses on that line.
--
Chris Dingman
Webmaster
Cabaret Theatre http://www.cabarettheatre.org
Now selling officially licensed Cabaret Theatre merchandise
"SuSe newbie" <jk******@sc.rr.com> wrote in message
news:rz*********************@twister.southeast.rr. com... thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php
on line 43 any ideas?? "Cameron" <fo*@bar.invalid> wrote in message news:bv**********@news5.svr.pol.co.uk... SuSe newbie wrote: If someone can help me out with this i would really appreciate it.
I'm kind of new so don't bash my code too bad!! <code snip>
Missing semicolon on line above one with the error
~Cameron
Thanks guys, i've gotten rid of those bugs now. I figured it was something
stupid. I hope this is the last time i'll ask, but i'm getting a new error
now. Check this out and let me know what you think:
Your IP address is: XX.XX.XX.XX INSERT INTO leads
VALUES('test','test','test','test','test','test',' sc','55555','5555555555','
an**@anon.com',XX.XX.XX.XX)Error: You have an error in your SQL syntax near
'.148.78)' at line 1
"Chris Dingman" <di****@cabarettheatre.org> wrote in message
news:rD******************@nwrdny03.gnilink.net... Missing closing parentheses on that line.
-- Chris Dingman Webmaster Cabaret Theatre http://www.cabarettheatre.org
Now selling officially licensed Cabaret Theatre merchandise "SuSe newbie" <jk******@sc.rr.com> wrote in message news:rz*********************@twister.southeast.rr. com... thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on line 43 any ideas?? "Cameron" <fo*@bar.invalid> wrote in message news:bv**********@news5.svr.pol.co.uk... SuSe newbie wrote: > If someone can help me out with this i would really appreciate it. I'm > kind of new so don't bash my code too bad!! > <code snip>
Missing semicolon on line above one with the error
~Cameron
I got it, Thanks!!
"SuSe newbie" <jk******@sc.rr.com> wrote in message news:Tp*********************@twister.southeast.rr. com...
If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
This is the error:
Parse error: parse error, unexpected T_VARIABLE in /srv/www/htdocs/sendinfo.php on line 45
This is the code:
<?php
$fname=$_POST['fname'];
$lname=$_POST['lname'];
$address=$_POST['address'];
$address2=$_POST['address2'];
$address3=$_POST['address3'];
$citye=$_POST['city'];
$state=$_POST['state'];
$zip=$_POST['zip'];
$phone=$_POST['phone'];
$email=$_POST['email'];
$subject="Data Added";
$f*******@YYY.com;
$ipaddress = $_SERVER['REMOTE_ADDR'];
mail("XX*@XXX.com",$subject, "Street Address: $address\r\nCity:$city\r\nZip: $zip\r\nIP: $ipaddress", "FROM: $from\r\n");
echo "Your IP address is: $ipaddress";
?>
<?php
$username="XXX";
$password="XXXX";
$database="XXXX";
$localhost="localhost";
$fname= mysql_escape_string($_POST['fname']);
$lname= mysql_escape_string($_POST['lname']);
$address= mysql_escape_string($_POST['address']);
$address2= mysql_escape_string($_POST['address2']);
$address3= mysql_escape_string($_POST['address3']);
$city= mysql_escape_string($_POST['city']);
$state= mysql_escape_string($_POST['state']);
$zip= mysql_escape_string($_POST['zip']);
$phone= mysql_escape_string($_POST['phone']);
$email= mysql_escape_string($_POST['email']);
$ipaddress=mysql_escape_string($_SERVER['REMOTE_ADDR']
$conn=mysql_connect($localhost, $username, $password) or die("Unable to setup connection"); //This is the line the error is referencing
mysql_select_db($database,$conn) or die( "Unable to select database");
$query = "INSERT INTO leads VALUES('$fname','$lname','$address','$address2','$ address3','$city','$state','$zip','$phone','$email ',$ipaddress)";
echo $query;
mysql_query($query) or die("Error: ".mysql_error());
mysql_close();
?>
$citye=$_POST['city'];
I dont know if you have noticed but the varible here has an e on the end of
city but everywhere else it does not
$citye=$_POST['city'];
I dont know if you have noticed but the varible here has an e on the end of
city but everywhere else it does not
$citye=$_POST['city'];
I dont know if you have noticed but the varible here has an e on the end of
city but everywhere else it does not
SuSe newbie wrote: Thanks guys, i've gotten rid of those bugs now. I figured it was something stupid. I hope this is the last time i'll ask, but i'm getting a new error now. Check this out and let me know what you think: Your IP address is: XX.XX.XX.XX INSERT INTO leads VALUES('test','test','test','test','test','test',' sc','55555','5555555555',' an**@anon.com',XX.XX.XX.XX)Error: You have an error in your SQL syntax near '.148.78)' at line 1
Everything in the values section is quoted (surrounded by single quotes)
except the IP address.
--
I won't rise to the occaasion, but I'll slide over to it.
SuSe newbie wrote: Thanks guys, i've gotten rid of those bugs now. I figured it was something stupid. I hope this is the last time i'll ask, but i'm getting a new error now. Check this out and let me know what you think: Your IP address is: XX.XX.XX.XX INSERT INTO leads VALUES('test','test','test','test','test','test',' sc','55555','5555555555',' an**@anon.com',XX.XX.XX.XX)Error: You have an error in your SQL syntax near '.148.78)' at line 1
Everything in the values section is quoted (surrounded by single quotes)
except the IP address.
--
I won't rise to the occaasion, but I'll slide over to it.
SuSe newbie wrote: Thanks guys, i've gotten rid of those bugs now. I figured it was something stupid. I hope this is the last time i'll ask, but i'm getting a new error now. Check this out and let me know what you think: Your IP address is: XX.XX.XX.XX INSERT INTO leads VALUES('test','test','test','test','test','test',' sc','55555','5555555555',' an**@anon.com',XX.XX.XX.XX)Error: You have an error in your SQL syntax near '.148.78)' at line 1
Everything in the values section is quoted (surrounded by single quotes)
except the IP address.
--
I won't rise to the occaasion, but I'll slide over to it.
On Tue, 27 Jan 2004 05:21:27 +0000, SuSe newbie wrote: thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on line 43 any ideas??
<snip!>
Parse Error *always* means "syntax error". Meaning that you have a missing
semicolon, curly brace, unclosed double-quote, extra parentheses, etc.
Basically, a typo. Syntax errors can be very hard to find.
--
-------------------------
| Jeffrey Silverman |
| jeffrey-AT-jhu-DOT-edu|
-------------------------
On Tue, 27 Jan 2004 05:21:27 +0000, SuSe newbie wrote: thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on line 43 any ideas??
<snip!>
Parse Error *always* means "syntax error". Meaning that you have a missing
semicolon, curly brace, unclosed double-quote, extra parentheses, etc.
Basically, a typo. Syntax errors can be very hard to find.
--
-------------------------
| Jeffrey Silverman |
| jeffrey-AT-jhu-DOT-edu|
-------------------------
On Tue, 27 Jan 2004 05:21:27 +0000, SuSe newbie wrote: thanks Cameron, now i'm getting an error on that line for Parse error: parse error, unexpected ';' in /srv/www/htdocs/sendinfo.php on line 43 any ideas??
<snip!>
Parse Error *always* means "syntax error". Meaning that you have a missing
semicolon, curly brace, unclosed double-quote, extra parentheses, etc.
Basically, a typo. Syntax errors can be very hard to find.
--
-------------------------
| Jeffrey Silverman |
| jeffrey-AT-jhu-DOT-edu|
------------------------- This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: SuSe newbie |
last post by:
If someone can help me out with this i would really appreciate it. I'm kind of new so don't bash my code too bad!!
This is the error:
Parse error: parse error, unexpected T_VARIABLE in...
|
by: Danny |
last post by:
I am posting xml to a server and get the above error returned. The client
code is listed below, it works until say a "<" character is put in XmlData.
On the server page I try to pick up the XmlData...
|
by: phopman |
last post by:
Hello!
I am currently working on a project. And have been assigned to get up to speed quickly on php. And even though I love the language, it's not easy to get up to speed in like 2 seconds :-)
...
|
by: srinivasMP51 |
last post by:
<?php
$host = “localhost”; //Host where this database is running.
$user_name = “root”; //Your MySQL Server’s user name
$password = “yyyyyyy”; //Your MySQL Server’s Password
$db_name...
|
by: neogazz |
last post by:
Please see the attached picture. When I try to create my MySQL table using the below commands I get the attached error, why?
mysql> CREATE TABLE grocery_inventory (
-> id int not null primary key...
|
by: Victor Miagkikh |
last post by:
I'm getting a foreign key constraint error when I use MySQL running under Windows 7. When I run the same MySQL and Hybernate code on Mac it works just fine. Here are the details of the error:
...
|
by: ben pymer |
last post by:
Hi All
I am currently in the process of migrating several sites from one web server running IIS to another.
Everything is fine apart from a couple of the pages in certain sites which reference...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |