You are here: Re: Regexp - matching text not containing certain count of certain characters « PHP Programming Language « IT news, forums, messages
Re: Regexp - matching text not containing certain count of certain characters

Posted by John Dunlop on 11/18/58 11:44

Jiri Fogl:

> I'm trying to build a regular expression (POSIX extended). One part of
> it has to match any text not containing a slash except standalone two
> dots (..), but I can't find the way to say something like "match any
> count of any characters except string ..".
>
> For example, it should match
> ..anything..
> aaa..
> ...
>
> but must not match
> anything/containing/a/slash
> ..

(UNTESTED)

!ereg('^\.\.$|/',$subject)

--
Jock

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация