Re: grep question - how to strip spaces from the beginning ofa string?

This WebDNA talk-list message is from

2002


It keeps the original formatting.
numero = 45096
interpreted = N
texte = Thank you John!If I may, one more.... would it be better to use grep to change an accented charactor to the non-accented one or just use a convertchars db?What I am doing is taking nicknames that are in my database and 'cleaning' them so that in the near future I can use the nickname as part of the web url.right now members profiles are reached by ../members/details.html?recordid= 646464 I want to change this to be ../members/nickname/So the leading and trailing spaces some hed entered in the db are now being stripped and chars other than a-z and 0-1 and - _ . are being converted to _. Which means the accented chars get converted to _ which is not nice :)ThanksDaleOn Monday, November 11, 2002, at 11:08 PM, John Peacock wrote:> dale's stuff wrote: > >> hi, >> >> Reading past messages I see an example John P. gave for stripping spaces >> from the end of a string using - [grep search= *$&replace=][string][/grep] >> where the $ denotes the line end charactor. I wonder is there something >> similar for the line beginning? > > [grep search=^ *&replace=][string][/grep] > > John > > -- John Peacock ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: grep question - how to strip spaces from the beginning ofa string? (Gyuri 2002)
  2. Re: grep question - how to strip spaces from the beginning ofa string? (John Peacock 2002)
  3. Re: grep question - how to strip spaces from the beginning ofa string? (Kenneth Grome 2002)
  4. Re: grep question - how to strip spaces from the beginning ofa string? (Gyuri 2002)
  5. Re: grep question - how to strip spaces from the beginning ofa string? (dale's stuff 2002)
  6. Re: grep question - how to strip spaces from the beginning ofa string? (dale's stuff 2002)
  7. Re: grep question - how to strip spaces from the beginning ofa string? (John Peacock 2002)
  8. Re: grep question - how to strip spaces from the beginning ofa string? (Gyuri 2002)
Thank you John!If I may, one more.... would it be better to use grep to change an accented charactor to the non-accented one or just use a convertchars db?What I am doing is taking nicknames that are in my database and 'cleaning' them so that in the near future I can use the nickname as part of the web url.right now members profiles are reached by ../members/details.html?recordid= 646464 I want to change this to be ../members/nickname/So the leading and trailing spaces some hed entered in the db are now being stripped and chars other than a-z and 0-1 and - _ . are being converted to _. Which means the accented chars get converted to _ which is not nice :)ThanksDaleOn Monday, November 11, 2002, at 11:08 PM, John Peacock wrote:> dale's stuff wrote: > >> hi, >> >> Reading past messages I see an example John P. gave for stripping spaces >> from the end of a string using - [grep search= *$&replace=][string][/grep] >> where the $ denotes the line end charactor. I wonder is there something >> similar for the line beginning? > > [grep search=^ *&replace=][string][/grep] > > John > > -- John Peacock ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://search.smithmicro.com/ dale's stuff

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Next (1997) [SHOWIF] PROBLEM (2000) $append (1998) RE: [sendmail]- bcc? (1998) [Sum] function? (1997) WebCatalog for Postcards ? (1997) Quit revisited (1997) Math Problem - Format? (1997) [WebDNA] WebDNA & MS SQL (2013) [WAY OFF TOPIC] anybody live in Kansas? (2003) WebCatalog stalls (1998) PIXO support (1997) Summary layout (1997) [WebDNA] [OT] WebDNA Wiki - need grammar check / suggestions (2009) Using Plug-In while running 1.6.1 (1997) Apache Question (2003) SERIAL NUMBER BEING LOST AGAIN!!! (1999) add to cart within a page? (1997) RequiredFields template (1997) Online Docs? (1997)