Richard Davey wrote:
unset($type);
$type = $_GET['action'];
(Please note - you don't HAVE to "unset" each variable, but if you are
working in a Register Globals ON environment, it's a good safety
measure).
I've seen a few people recommending this type of thing. Please explain
how this is any safer
To everyone, especially Richard,
Thanks a lot for the help. I have accomplished everything I needed to do
with your help, and I have never used PHP before.
Thanks again!
alistair
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hello Alistair,
Thursday, March 11, 2004, 1:25:47 AM, you wrote:
AH> unset($type);
AH> $type = $_GET['type'];
AH> $link = mysql_connect('localhost', 'user', 'password');
AH> if (!$link) {
AH> echo "Couldn't make a connection!";
AH> exit;
AH> }
AH> $db = mysql_sele
On Wednesday 10 March 2004 18:54, Raditha Dissanayake wrote:
> Hi.
> There is an ADO simulator for PHP (i think it's called ADODB PHP but i
> can't remember the link). There is also a asp to php converter called
> (can you guess? ) asp2php.
http://php.weblogs.com/
And
Pear::DB must work too :P
h
Sorry, was the query!
Richard Davey wrote:
Hello Alistair,
Wednesday, March 10, 2004, 11:26:53 PM, you wrote:
AH> I get this error: mysql_num_rows(): supplied argument is not a valid
AH> MySQL result resource
Then your database connection failed OR the SQL query did. Check those
steps over be
Richard Davey wrote:
Hello Alistair,
Wednesday, March 10, 2004, 11:26:53 PM, you wrote:
AH> I get this error: mysql_num_rows(): supplied argument is not a valid
AH> MySQL result resource
Then your database connection failed OR the SQL query did. Check those
steps over before anything else.
Mayb
Hi.
There is an ADO simulator for PHP (i think it's called ADODB PHP but i
can't remember the link). There is also a asp to php converter called
(can you guess? ) asp2php.
Alistair Hayward wrote:
Hi ,
What is the equavilant in PHP to creating a recordset in ASP using a
query?
This is what I d
Hello Alistair,
Wednesday, March 10, 2004, 11:26:53 PM, you wrote:
AH> I get this error: mysql_num_rows(): supplied argument is not a valid
AH> MySQL result resource
Then your database connection failed OR the SQL query did. Check those
steps over before anything else.
Maybe post that part of y
Richard Davey wrote:
A few ways to do this:
$total_records = mysql_num_rows($result);
for ($i=0; $i < $total_records; $i++)
{
$data = mysql_fetch_assoc($result);
print_r($data);
}
$data will now be an array holding the first set of information. The
print_r line just displays it so you can
Richard:
Thank you so much!
Richard Davey wrote:
Hello Alistair,
Wednesday, March 10, 2004, 10:26:03 PM, you wrote:
AH> dim Type
AH> Type = CStr(Request.QueryString("action")) (getting parameter from URL)
unset($type);
$type = $_GET['action'];
(Please note - you don't HAVE to "unset" each variab
Hello Alistair,
Wednesday, March 10, 2004, 10:26:03 PM, you wrote:
AH> dim Type
AH> Type = CStr(Request.QueryString("action")) (getting parameter from URL)
unset($type);
$type = $_GET['action'];
(Please note - you don't HAVE to "unset" each variable, but if you are
working in a Register Globals
Hi ,
What is the equavilant in PHP to creating a recordset in ASP using a query?
This is what I do in PHP:
..
dim Type
Type = CStr(Request.QueryString("action")) (getting parameter from URL)
Dim cnn ' ADO connection
Dim rst ' ADO recordset
Dim strDBPath ' path to
12 matches
Mail list logo