|
Posted by Jason Wong on 01/20/05 20:41
On Friday 21 January 2005 01:52, Tim Boring wrote:
> To try to help spot the issue, I put in the if(preg_match("/^\W+/",
> $line)) logic, and the weird thing is that this logic isn't outputting
> the line beginning with things like "AKRN", yet the same line is getting
> caught in the switch statement and being discarded.
Well the biggest problem in your code right now is your incomprehensible (to
me anyway) use of the switch construct. For a start I've no idea why you're
using ...
> switch ($line)
.... when your tests do not involve $line
> case ($total_counter <= 5):
I suspect what you want to be doing is something like this:
switch (TRUE) {
case ANY_EXPRESSION_THAT_EVALUATES_TO_TRUE:
...
}
--
Jason Wong -> Gremlins Associates -> www.gremlins.biz
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
------------------------------------------
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
------------------------------------------
New Year Resolution: Ignore top posted posts
Navigation:
[Reply to this message]
|