Search the archives!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Javascript] regexp - how to exclude a substring
- From: flavio at economisa.com.br (Flavio Gomes)
- Subject: [Javascript] regexp - how to exclude a substring
- Date: Mon May 30 07:46:14 2005
I'd just 'substring' the result:
var result = '<div> my Div Contents </div>';
result = result.substring(5, result.length - 6);
I believe will do,
=]
--
Flavio Gomes
flavio@xxxxxxxxxxxxxxxx
Alberto Domingo wrote:
> //
>
>Therefore as my next step I need to know how to exclude
>"</div" from the
>
>innerHTML of the div. I've tried (.*(<\/div){0}) but it doesn't
>seem to work.
>
>
>
>1) How do I say "allow any number of any characters but don't allow
>this
>
>substring"?
>
>//
>
>
>
>
>
>
> May be an stupid idea, but, I would try to first change the substring
> to exclude to a single special character (for example |). Then you can
> do the regxp search excluding that special character.
>
>
>
>
>
> Alberto Domingo
>
>
> _________________________________________________________________________
> Universidad de Alcal?
> Departamento de Bioqu?mica y Biolog?a Molecular
> Edificio de Medicina
> Campus Universitario
> Alcal? de Henares - 28871
> Madrid
>
> Tel?fono: (+34) 91 885 4520
> FAX: (+34) 91 885 4585
>
> alberto.domingo@xxxxxx
- References:
- [Javascript] regexp - how to exclude a substring
- From: Alberto Domingo
- [Javascript] regexp - how to exclude a substring
- Prev by Date: [Javascript] regexp - how to exclude a substring
- Next by Date: [Javascript] regexp - how to exclude a substring
- Previous by thread: [Javascript] regexp - how to exclude a substring
- Next by thread: [Javascript] regexp - how to exclude a substring
- Index(es):