Re: [PHP-DB] recover values independently of GET or POST used

2009-09-14 Thread Chris
bu...@alejandro.ceballos.info wrote: I am using some expressions to load the value of a parameter when called, independently if used GET or POST method, using something like: $mydata = (isset($_GET["mydata"])) ? $_GET["mydata"] : (isset($_POST["mydata"])) ? $_POST["mydata"] : 0; echo $myd

Re: [PHP-DB] recover values independently of GET or POST used

2009-09-14 Thread TG
Some weird stuff happens when you try to chain ternary operations. Not awake enough to explain it better right now. What it sounds lik eyou're looking for is $_REQUEST. This will give you the correpsonding GET or POST value (as well as cookie, environment, etc.. google it). It's probably goo

[PHP-DB] recover values independently of GET or POST used

2009-09-14 Thread buzon
I am using some expressions to load the value of a parameter when called, independently if used GET or POST method, using something like: $mydata = (isset($_GET["mydata"])) ? $_GET["mydata"] : (isset($_POST["mydata"])) ? $_POST["mydata"] : 0; echo $mydata; ?> The problem occurs with abo

Re: [PHP-DB] Re: Need help-Send email

2009-09-14 Thread nagendra prasad
Hi Chris, Thanks for the response. However I have coded the Email code with SMTP authentication. But the problem is my mail is going to the SPAM not in the inbox. I remember someone has said that if the code is sending the email and if its going under SPAM folder then the code is correct but I hav

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Chris
Stan wrote: OK. If I change the test to "if(mysql_num_rows($thisRow) < 1)" it does what I want. I guess if I want to understand why False was returned originally (just after I created the database) I need to start over. According to the docs mysql_query only returns false if there's an error.

Re: [PHP-DB] Re: Need help-Send email

2009-09-14 Thread Chris
What _IS_ required is a valid recipient. What google requires to send an email through their servers is smtp authentication - none was mentioned in the original post (nor any follow up suggestions). If the recipient is invalid, it will bounce back - just like any other email where you mis

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Stan
OK. If I change the test to "if(mysql_num_rows($thisRow) < 1)" it does what I want. I guess if I want to understand why False was returned originally (just after I created the database) I need to start over. Do I have 4 possible conditions here: 1) the mysql_query() function fails and I get a PH

Re: [PHP-DB] mysql_query returning empty result after DELETE

2009-09-14 Thread Stan
Yes. I deleted all records. Prior to the DELETE, if I did a SELECT with specific criteria (WHERE p.pictureFile = "some valid content"), and those criteria were not met, mysql_query() returned False ... and, conversely, if those criteria were met, mysql_query() returned "a resource" against which I

Re: [PHP-DB] Re: Need help-Send email

2009-09-14 Thread Richard Quadling
2009/9/14 Chris : > nagendra prasad wrote: >> >> Hi all, >> >> Below is the code that I have coded after replies from all of you. But >> before that I want to thank all of you for your help. I have coded the >> email >> code but still it is giving me an error. Please help me. > > ... and the error