[PHP] One more 'Headers Already Sent' error. :-(

2002-06-25 Thread Brad Melendy
Hi All, I know this has come up before and I've read some posts so far, but this is still eluding me. I have come to understand that typically, if you are getting an error message about your headers having already been sent to the browser, you are writing bad code. Now, I want to right good

Re: [PHP] Re: One more 'Headers Already Sent' error. :-(

2002-06-26 Thread Brad Melendy
Holmes... -Original Message- From: Brad Melendy [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 25, 2002 10:39 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] Re: One more 'Headers Already Sent' error. :-( Oh I read all the error messages, I just don't understand them. ;-) I'm

Re: [PHP] Re: One more 'Headers Already Sent' error. :-(

2002-06-26 Thread Brad Melendy
Erik Price [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... On Tuesday, June 25, 2002, at 06:07 PM, Brad Melendy wrote: Well, I have traced this down to line 4 in the following code 'include(header.html);' which just includes my navigation bar. If I

[PHP] Usiing FOREACH to loop through Array

2002-06-29 Thread Brad Melendy
Hi All, I've stumped myself here. In a nutshell, I have a function that returns my array based on a SQL query and here's the code: -begin code--- function getCourses($UID) { global $link; $result = mysql_query( SELECT C.CourseName FROM tblcourses C, tblusers U,

Re: [PHP] Usiing FOREACH to loop through Array

2002-06-29 Thread Brad Melendy
going to revisit the mysql_fetch_array function right now. Thanks for your help, it is greatly appreciated. ...Brad Steve Edberg [EMAIL PROTECTED] wrote in message news:p05100300b943f2a7feef@[168.150.239.37]... At 3:27 PM -0700 6/29/02, Brad Melendy wrote: Hi All, I've stumped myself here

Re: [PHP] Usiing FOREACH to loop through Array

2002-06-29 Thread Brad Melendy
someone else next time. :-) Steve Edberg [EMAIL PROTECTED] wrote in message news:p05100300b943f2a7feef@[168.150.239.37]... At 3:27 PM -0700 6/29/02, Brad Melendy wrote: Hi All, I've stumped myself here. In a nutshell, I have a function that returns my array based on a SQL query and here's

[PHP] One more Regular Expression Question...

2002-05-13 Thread Brad Melendy
Hello, I'm pretty stuck here. I wish to assign a variable the value of a particular substrint of text from a second variable. It's HTML so I've got something like: $string1 = a href='/Schedule_Detail'Here's the Schedule/a I want to create a variable $string2 and assign it the value of

[PHP] Re: One more Regular Expression Question...

2002-05-13 Thread Brad Melendy
Philip Hallstrom [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... $string1 = a href='/Schedule_Detail'Here's the Schedule/a; ereg((.*)/a, $string1, $matches); $string2 = $matches[1]; Something close to that anyway... On Mon, 13 May 2002, Brad Melen

Re: [PHP] Re: One more Regular Expression Question...

2002-05-14 Thread Brad Melendy
ore info. miguel On Mon, 13 May 2002, Brad Melendy wrote: Thanks Philip. This gives me everything before the ' that I'm looking for but I believe it is because it occurs more than once. I think I need to count the times that ' occurs and then try to target the specific occurance tha

Re: [PHP] Re: One more Regular Expression Question...

2002-05-14 Thread Brad Melendy
has in the above expression, but it works so I'm not gonna complain. But if anyone wants to explain it to me, that's wonderful. The info for STRRCHR at php.net is a tad light to say the least on this particular function. Thanks again. Brad Brad Melendy [EMAIL PROTECTED] wrote in message

[PHP] Can I have If...Else inside a For Loop???

2001-10-19 Thread Brad Melendy
Hi All, I'm stumped. I've got the following code: ?php if(isSet($domain)) { for ( $counter=0; $counter = strlen($domain); $counter++ ) { $nChar = ord(strtolower(substr($domain, $counter, 1))); if (($nChar 47 And $nChar 58) or ($nChar 96 And $nChar 123) or $nChar = 45); { print

Re: [PHP] Can I have If...Else inside a For Loop???

2001-10-19 Thread Brad Melendy
the end of the 'if' line, at '... $nChar = 45); { ...' ? Looks like the if statement ends there, the ' { print OK.; } ' is a block on it's own and the 'else' is now out of context. -Original Message- From: Brad Melendy [mailto:[EMAIL PROTECTED]] Sent: Friday, October 19, 2001

Re: [PHP] Can I have If...Else inside a For Loop???

2001-10-20 Thread Brad Melendy
@localhost">news:3bd15547.14743496@localhost... On Fri, 19 Oct 2001 21:46:29 -0700 impersonator of [EMAIL PROTECTED] (Brad Melendy) planted I saw in php.general: arrh! I don't think I can say much else. Thanks so much for pointing that out David. ;-) .Brad

Re: [PHP] Can I have If...Else inside a For Loop???

2001-10-20 Thread Brad Melendy
Oops, I spoke too soon. I wasn't getting the results I thought I was until I used == instead of = at the very end of my IF statement. Thanks very much for pointing that out. Brad Brad Melendy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... H...

[PHP] Using Logical OR operator in IF statement???

2001-10-20 Thread Brad Melendy
Hello, Ok, this works: if (substr($sString,(strlen($sString)-1)!=-)) { print You can't have a dash at the end of your string.; } and this works: if (substr($sString,0,1)!=-) { print You can't have a dash at the beginning of your string.; } But, this doesn't work for any case: if

[PHP] Re: Using Logical OR operator in IF statement???

2001-10-21 Thread Brad Melendy
eginning or end of your string.; } else { echo Whatever; } ? Just my thoughts... James Brad Melendy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, Ok, this works: if (substr($sString,(strlen($sString)-1)!=-)) { print You c

[PHP] Re: Using Logical OR operator in IF statement???

2001-10-21 Thread Brad Melendy
Ok, it works!! Thanks to everyone for their suggestions and answers. This group is a great resourse. Thanks again ...Brad Brad Melendy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Thanks James, I tried a regular expression comparis

[PHP] Re: Can If Else statements be split into code blocks??

2001-11-13 Thread Brad Melendy
the proper condition was met in the If Else statement. Brad Brad Melendy [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, I'm trying to execute some HTML in an IF ELSE statement. I'm trying something like: ?php if (strstr($DomResult

[PHP] Segmented Code/HTML VS. ECHO??

2001-11-18 Thread Brad Melendy
Hello, Other than the fact that sometimes, you just can't get raw HTML to process properly by dropping out of PHP code, what are the pros and cons of using RAW HTML or just ECHOING everything in PHP? Thanks for any insights. ..Brad -- PHP General Mailing List (http://www.php.net/) To