Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
I tend to think of XSLT as tree walking but with a twist. I find that model keeps me sane for the simpler templates.

Each template is really made of smaller templates, which in turn can be made of smaller (etc). In my mental model I match my tree walking to my templates, so for large general sections of the tree I have larger, general templates (if you see what I mean).

So I guess I map fragments to fragments like two bits of velcro or two bits of a sandwich (or something).

I find that where it begins to get hard is when you start to do node processing using XPath. Really XSLT and XPath go hand in hand and its hard to get anything complicated out of XSLT without having a good grounding in XPath.

However, this is where I think XSLT can fall down, I have had to write some very complex XPath queries that I know most of the content developers wouldn't have a hope of producing - hence, at work, I'm one of the only people to use it.

I got the O'Reilly stuff too and I don't think they are much good (but thats my PERSONAL opinion ;) ). I'd search the web for XPath tutorials and play with a self generated XML document for an afternoon.

Just my 2p :)

In reply to Re: What's Your Mental Image of XSLT? by simon.proctor
in thread What's Your Mental Image of XSLT? by Cody Pendant

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (1)
As of 2024-04-24 15:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found