eessen" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 1:22 PM
Subject: Re: [PHP] Question about $_GET
> Make life easy for yourself:
>
> $query = "SELECT Newsheadline, News, Contact FROM news WHERE Newsid =
".$_GET['id'
On Thursday 16 January 2003 04:35, [-^-!-%- wrote:
> I agree with Chris, the quote should stay there to prevent confusion.
> Nevertheless, I often run in the same problem. Sometimes, the only way to
> fix it is by removing the quotes ($_GET[id]).
>
> I know PHP documents goes against this, but it
I agree with Chris, the quote should stay there to prevent confusion.
Nevertheless, I often run in the same problem. Sometimes, the only way to
fix it is by removing the quotes ($_GET[id]).
I know PHP documents goes against this, but it dosn't always work with the
quotes.
Perhaps the dev team
--- Frank Keessen <[EMAIL PROTECTED]> wrote:
> So the code looks like this:
>
> $query = "SELECT Newsheadline, News, Contact FROM news
> WHERE Newsid = $_GET['id']";
>
> But all i'm getting in my browser is:
>
> parse error, expecting `T_STRING' or `T_VARIABLE' or
> `T_NUM_STRING'
I could not t
Make life easy for yourself:
$query = "SELECT Newsheadline, News, Contact FROM news WHERE Newsid = ".$_GET['id'];
- Original Message -
From: "Frank Keessen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 4:50 AM
Su
On Wednesday 15 January 2003 18:57, Frank Keessen wrote:
> Thanks, but not working:
>
> The error message:
> Error in query: SELECT Newsheadline, News, Contact FROM news WHERE Newsid =
> . You have an error in your SQL syntax near '' at line 1
>
> Here are both lines:
>
> $query = "SELECT Newsheadl
ewsid =
{$_GET['id']}";
$result = mysql_query($query) or die ("Error in query: $query. " .
mysql_error());
Regards,
Frank
- Original Message -
From: "Danny Shepherd" <[EMAIL PROTECTED]>
To: "Frank Keessen" <[EMAIL PROTECTED]>; <[EMAIL
Chris Hayes wrote:
Let me explain.
For one, the single quotes are not in the way here because the query
is written between double quotes.
Then, leaving out the single quotes like Marek suggests will only work
because PHP is too programmer-friendly.
But the indexes of such arrays should al
At 11:57 15-1-03, Marek Kilimajer wrote:
"SELECT Newsheadline, News, Contact FROM news WHERE Newsid = $_GET[id]";
- removed single quotes
I think that that is a really bad advice.
Let me explain.
For one, the single quotes are not in the way here because the query is
written between double q
($query) or die ("Error in query: $query. " .
> mysql_error());
>
> Regards,
>
> Frank
> - Original Message -
> From: "Danny Shepherd"
> To: "Frank Keessen" ;
> Sent: Wednesday, January 15, 2003 11:54 AM
> Subject: Re: [PHP] Question about $_GET
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Error in query: $query. " .
mysql_error());
Regards,
Frank
- Original Message -
From: "Danny Shepherd"
To: "Frank Keessen" ;
Sent: Wednesday, January 15, 2003 11:54 AM
Subject: Re: [PHP] Question about $_GET
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
ED]>
Sent: Wednesday, January 15, 2003 11:54 AM
Subject: Re: [PHP] Question about $_GET
> Try
>
> $query = "SELECT Newsheadline, News, Contact FROM news WHERE Newsid =
> {$_GET['id']}";
>
> HTH
>
> Danny.
> - Original Message -
> From: &quo
"SELECT Newsheadline, News, Contact FROM news WHERE Newsid = $_GET[id]";
- removed single quotes
Frank Keessen wrote:
Hi All,
Can you please help me with the following problem? I've had code wich was running fine with php till i've upgraded to PHP version 4.2.3.
The original code line was:
Try
$query = "SELECT Newsheadline, News, Contact FROM news WHERE Newsid =
{$_GET['id']}";
HTH
Danny.
- Original Message -
From: "Frank Keessen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 10:50 AM
Subject: [PH
Hi All,
Can you please help me with the following problem? I've had code wich was running fine
with php till i've upgraded to PHP version 4.2.3.
The original code line was:
$query = "SELECT Newsheadline, News, Contact FROM news WHERE Newsid = '$id'";
but it's not working when you have register
You need to turn register_globals off in your php.ini
file. This is default in php 4.2+
Try this article for a great overview:
http://www.webmasterbase.com/article/758/8
olinux
--- swade <[EMAIL PROTECTED]> wrote:
> On my laptop i still have 4.11 apache,linux on it
> but its just for
> develo
On my laptop i still have 4.11 apache,linux on it but its just for
development.
I must be confused about get and post handling. I've been referrencing
them in $_GET, etc but I was just working on something and linked to a
script by using ?section=duh in the query string,etc
Now i thought $duh
17 matches
Mail list logo