← Prev in month ← Prev in thread

Is there any legitimate case for processing based on a specific namespace prefix?

From
Costello, Roger L. <>
To
"" <>
Date
2012-08-28T20:20:25Z
ID
<>
Thread
Is there any legitimate case for processing based on a specific namespace prefix?
Hi Folks,

Recall that a namespace prefix may be anything.

For example, by convention 'xsl' is used as the prefix for the XSLT namespace, but I could equally well use 'foo' or 'bar' as the prefix.

Is there ever a time when it is okay to create an XML application that checks for a specific prefix, e.g.,

    If the prefix is 'foo' then
            do A, B, C
     Else
           do X, Y, Z

It seems to me that such code would be very brittle and very unwise.

But perhaps there are legitimate cases where this is okay.

If so, would you provide a concrete example please?

/Roger
← Prev in month ← Prev in thread