Re: [PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Nicholas Cooper
On 31 March 2011 15:53, Stuart Dallas wrote: > On Thursday, 31 March 2011 at 15:45, Nicholas Cooper wrote: > Good day, > > > > I have three arrays A, B and C. Anyone of them might not have the 'id' > key > > set which will give the Notice "Undefined index: id". > > > > I just wanted to know what

Re: [PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Stuart Dallas
On Thursday, 31 March 2011 at 15:45, Nicholas Cooper wrote: Good day, > > I have three arrays A, B and C. Anyone of them might not have the 'id' key > set which will give the Notice "Undefined index: id". > > I just wanted to know what the correct approach to this problem would be; > without maki

[PHP] If Statements Array and Notice Undefined Index

2011-03-31 Thread Nicholas Cooper
Good day, I have three arrays A, B and C. Anyone of them might not have the 'id' key set which will give the Notice "Undefined index: id". I just wanted to know what the correct approach to this problem would be; without making the code overly complicated to read by introducing a number of "if is

Re: [PHP] if() statements

2002-06-06 Thread Analysis & Solutions
On Thu, Jun 06, 2002 at 07:52:28PM +1000, Justin French wrote: > It's starting to get a noticeable (although not major) lag. It's probably > the multiple MySQL queries, which I'm going to attempt to minimise and > optimise, but it also brings me to a question about if(). > > does the process of

[PHP] if() statements

2002-06-06 Thread Justin French
Hi, I'm working on a 350+ line message board script with multiple SQL queries, etc. It's starting to get a noticeable (although not major) lag. It's probably the multiple MySQL queries, which I'm going to attempt to minimise and optimise, but it also brings me to a question about if(). does th

RE: [PHP] IF Statements

2002-05-16 Thread Patrick Lynch
iginal Message- From: Jon Yates [mailto:[EMAIL PROTECTED]] Sent: 15 May 2002 15:04 To: '[EMAIL PROTECTED]' Subject: [PHP] IF Statements People, hope you can help. The below IF statement is getting a PARSE error. Can anyone spot why? Cheers. Jon if (($this->checkReferr

Re: [PHP] IF Statements

2002-05-15 Thread 1LT John W. Holmes
. You'll have to put it all back together to actually execute the code, but this will help you on large statements like this to make sure your logic and syntax is correct. ---John Holmes... - Original Message - From: "Jon Yates" <[EMAIL PROTECTED]> To: <[EMAIL PROTE

RE: [PHP] IF Statements

2002-05-15 Thread Jay Blanchard
[snip] People, hope you can help. The below IF statement is getting a PARSE error. Can anyone spot why? if (($this->checkReferralCB($this->benefitRef, $this->benefitNo, $this->childDOB)) && (!$this->checkLocation($this->post, "W")) && (!empty($this->childDOB))) || ($this->checkPregnancy($th

Re: [PHP] IF Statements

2002-05-15 Thread Michal Dvoracek
Hello, try this version :) if (($this->checkReferralCB($this->benefitRef, $this->benefitNo, $this->childDOB)) && (!$this->checkLocation($this->post, "W")) && (!empty($this->childDOB)) || ($this->checkPregnancy($this->benefitRef, $this->benefitNo))) Regards, Michal Dvoracek

Re: [PHP] IF Statements

2002-05-15 Thread Steven Apostolou
if (($this->checkReferralCB($this->benefitRef, $this->benefitNo, $this->childDOB)) && (!$this->checkLocation($this->post, "W")) && (!empty($this->childDOB))) || ($this->checkPregnancy($this->benefitRef, $this->benefitNo)) must be: if (($this->checkReferralCB($this->benefitRef, $this->

Re: [PHP] IF Statements

2002-05-15 Thread Rasmus Lerdorf
Your brackets don't match up. Use an editor that lets you do bracket-matching. Hit '%' in vi, for example. -Rasmus On Wed, 15 May 2002, Jon Yates wrote: > People, hope you can help. The below IF statement is getting a PARSE error. > Can anyone spot why? > > Cheers. > > Jon > > if (($this->c

[PHP] IF Statements

2002-05-15 Thread Jon Yates
People, hope you can help. The below IF statement is getting a PARSE error. Can anyone spot why? Cheers. Jon if (($this->checkReferralCB($this->benefitRef, $this->benefitNo, $this->childDOB)) && (!$this->checkLocation($this->post, "W")) && (!empty($this->childDOB))) || ($this->checkPre

RE: [PHP] IF Statements

2002-01-13 Thread Martin Towell
14, 2002 2:09 PM To: [EMAIL PROTECTED] Subject: [PHP] IF Statements I have a page for listing the contents of a table from my db. Being client.php?action=list As the action variable also allows for adding extra to the table, etc. Once I use ?action=list I want to be able to click on a singl

Re: [PHP] IF Statements

2002-01-13 Thread James Mclean
Hi, > My problem is working out how to evaluate this new part. I have normal > If > statements for the listing, adding, etc. But how can I get it to check > if > clientcode is present. If clientcode is not present I want it to load > the > list page as normal. But if the clientcode is present t

Re: [PHP] IF Statements

2002-01-13 Thread Bogdan Stancescu
if ($action=='list') { if (!$clientcode) { } else { } } I put the $clientcode test inside the $action test because I suppose you take different actions on $clientcode depending on $action - if that's not the case, simply switch the two if's. This assumes that $clientcode>0. If you al

[PHP] IF Statements

2002-01-13 Thread Necro
I have a page for listing the contents of a table from my db. Being client.php?action=list As the action variable also allows for adding extra to the table, etc. Once I use ?action=list I want to be able to click on a single record and have it give me the extended info. so client.php?action=list

Re: [PHP] "IF" statements

2001-05-22 Thread Steve Werby
"chris herring" <[EMAIL PROTECTED]> wrote: > if ($date == 24 && $hour == 3) { } > > But that doesn't work... Any help is appreciated Your logic is correct. If the code within the braces isn't working it's likely there's either an error in the code within the braces or $date and $hour aren't ret

RE: [PHP] "IF" statements

2001-05-22 Thread Maxim Maletsky
Developer PHPBeginner.com (Where PHP Begins) [EMAIL PROTECTED] www.phpbeginner.com -Original Message- From: chris herring [mailto:[EMAIL PROTECTED]] Sent: Wednesday, May 23, 2001 11:58 AM To: [EMAIL PROTECTED] Subject: [PHP] "IF" statements Ok, use your imaginations an

RE: [PHP] "IF" statements

2001-05-22 Thread Peter Houchin - SunRentals Australia
What's wrong with doing it like if ($date == 24) { if ($hour == 3) { do something } } ?? -Original Message- From: chris herring [mailto:[EMAIL PROTECTED]] Sent: Wednesday, May 23, 2001 12:58 PM To: [EMAIL PROTECTED] Subject: [PHP] "IF&q

[PHP] "IF" statements

2001-05-22 Thread chris herring
Ok, use your imaginations and visualize what I'm trying to do with this, because I'm not quite sure how to explain it. Anyway, I'm trying to have a script that says when THIS_VAR and THAT_VAR are a certain number it show something. I'm not quite sure how to do that without making yet another va