Re: A simply regex question



Franzl Wisseworst wrote:
[Subject: A simply regex question]

Your task can better be solved without using a RE.

How can I figure if my DOCUMENT_URI contains a substring, eg.:

perldoc -f index

And is there a way to ignore case, so the substring could be
"mein.totenkopf.de" or "MEIN.TOTENKOPF.DE" for example?

You normalize both strings before searching, e.g. make both all lower-case,
see
perldoc -f lc

jue


.



Relevant Pages

  • Re: Teach me how to fish, regexp
    ... I use the std docs many times each day, but never through perldoc. ... relevant docs. ... so then I try searching other ways: ... That is a feature of your pager program, ...
    (comp.lang.perl.misc)
  • Re: array question
    ... See `perldoc -f split` for details. ... Note: no strings. ... a string of a single space will match all ... whitespace. ...
    (perl.beginners)
  • Re: Perldoc versus Man
    ... TM> It knows how to display the docs for modules installed from CPAN. ... if you have normal pod, ... perldoc can do that man can't. ... about the docs than man can (stuff like searching or indexing). ...
    (comp.lang.perl.misc)
  • Re: laziest / fastest way to match last characters of a string
    ... Why not benchmark some different alternatives to see? ... Your 'long strings' might not be all that long. ... Don't know if it'll be faster, but using length and index would be an alternative, another would be substr. ... perldoc -f length ...
    (comp.lang.perl.misc)
  • Re: Quick regex question
    ... > I am not sure if there is a proper name for this but was having some ... > difficulty searching for it. ... > # more dataaa ... perldoc -f map ...
    (perl.beginners)