Re: [PHP] Getting rid of extra lines (RESOLVED)

2009-07-29 Thread Miller, Terion
On 7/29/09 3:16 PM, "Jim Lucas" wrote: Miller, Terion wrote: > > > On 7/29/09 3:05 PM, "Jonathan Tapicer" wrote: > > On Wed, Jul 29, 2009 at 4:20 PM, Miller, > Terion wrote: >> >> >> On 7/29/09 1:45 PM, "Ashley Sheridan" wrote: >> >> [snip/] >> >> Have you thought of just using a regular str

Re: [PHP] Getting rid of extra lines (RESOLVED)

2009-07-29 Thread Jim Lucas
Miller, Terion wrote: > > > On 7/29/09 3:05 PM, "Jonathan Tapicer" wrote: > > On Wed, Jul 29, 2009 at 4:20 PM, Miller, > Terion wrote: >> >> >> On 7/29/09 1:45 PM, "Ashley Sheridan" wrote: >> >> [snip/] >> >> Have you thought of just using a regular str_replace() on your code? You >> can ask i

Re: [PHP] Getting rid of extra lines (RESOLVED)

2009-07-29 Thread Miller, Terion
On 7/29/09 3:05 PM, "Jonathan Tapicer" wrote: On Wed, Jul 29, 2009 at 4:20 PM, Miller, Terion wrote: > > > > On 7/29/09 1:45 PM, "Ashley Sheridan" wrote: > > [snip/] > > Have you thought of just using a regular str_replace() on your code? You > can ask it to replace newlines and carriage retu

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Jonathan Tapicer
On Wed, Jul 29, 2009 at 4:20 PM, Miller, Terion wrote: > > > > On 7/29/09 1:45 PM, "Ashley Sheridan" wrote: > > [snip/] > > Have you thought of just using a regular str_replace() on your code? You > can ask it to replace newlines and carriage returns with nothing and see > if that fixes you proble

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Jim Lucas
Miller, Terion wrote: > > > On 7/29/09 2:19 PM, "Jim Lucas" wrote: > > $clean = preg_replace('|\s+|', ' ', $input); > > Hi Jim, > The extra whitespace lines are in the data store, coming from it I'm going to > try your method but is there a way to not have mySQL store it with so many > lines

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Miller, Terion
On 7/29/09 2:19 PM, "Jim Lucas" wrote: $clean = preg_replace('|\s+|', ' ', $input); Hi Jim, The extra whitespace lines are in the data store, coming from it I'm going to try your method but is there a way to not have mySQL store it with so many lines (this is data being screen scraped and p

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Miller, Terion
On 7/29/09 1:45 PM, "Ashley Sheridan" wrote: [snip/] Have you thought of just using a regular str_replace() on your code? You can ask it to replace newlines and carriage returns with nothing and see if that fixes you problem? Thanks Ash www.ashleysheridan.co.uk Yep I have tried str_replac

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Jim Lucas
Miller, Terion wrote: > I am trying to get rid of empty whitespace lines, I can't us chop() because > as I read it it will remove all whitespacesright? > > Right now my db is outputting with extra lines, I have stripped tags I know > it isn't that causing it to look like this > > Blahlajdlkfj

RE: [PHP] Getting rid of extra lines

2009-07-29 Thread Bob McConnell
From: Miller, Terion /* snip */ Before anyone can tell you how to fix it, you need to find out what is causing that white space. is it empty lines, vertical tabs, thousands of spaces, ...? Once you find that out, it is pretty easy to decide how to get rid of them. Can you save the output to a fil

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Ashley Sheridan
[snip/] Have you thought of just using a regular str_replace() on your code? You can ask it to replace newlines and carriage returns with nothing and see if that fixes you problem? Thanks Ash www.ashleysheridan.co.uk -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Miller, Terion
On 7/29/09 1:34 PM, "Ashley Sheridan" wrote: On Wed, 2009-07-29 at 11:29 -0700, Miller, Terion wrote: > I am trying to get rid of empty whitespace lines, I can't us chop() because > as I read it it will remove all whitespacesright? > > Right now my db is outputting with extra lines, I have

Re: [PHP] Getting rid of extra lines

2009-07-29 Thread Ashley Sheridan
On Wed, 2009-07-29 at 11:29 -0700, Miller, Terion wrote: > I am trying to get rid of empty whitespace lines, I can't us chop() because > as I read it it will remove all whitespacesright? > > Right now my db is outputting with extra lines, I have stripped tags I know > it isn't that causing it