in reply to Re^2: Help extracting text from XML data
in thread Help extracting text from XML data
Yes.
$xml = '<string>Everyone knows that 1 < 2</string>';; print $xml =~ m[>([^<]+)</string>]sm;; Everyone knows that 1 < 2
From the spec:
The ampersand character (&) and the left angle bracket (<) MUST NOT appear in their literal form, except when used as markup delimiters, or within a comment, a processing instruction, or a CDATA section. If they are needed elsewhere, they MUST be escaped using either numeric character references or the strings "&" and "<" respectively.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Help extracting text from XML data
by Jenda (Abbot) on Oct 21, 2008 at 10:51 UTC | |
by JadeNB (Chaplain) on Oct 21, 2008 at 20:32 UTC | |
by BrowserUk (Patriarch) on Oct 21, 2008 at 23:41 UTC | |
by Jenda (Abbot) on Oct 22, 2008 at 09:16 UTC |