GithubHelp home page GithubHelp logo

What does this mean? about dhclass-hub HOT 6 CLOSED

ebeshero avatar ebeshero commented on July 25, 2024
What does this mean?

from dhclass-hub.

Comments (6)

CodyKarch avatar CodyKarch commented on July 25, 2024

@ebeshero @ghbondar @RJP43

from dhclass-hub.

CodyKarch avatar CodyKarch commented on July 25, 2024

Hello? Anybody?

from dhclass-hub.

ebeshero avatar ebeshero commented on July 25, 2024

@CodyKarch Hi Cody! Just saw your post. Here's what I meant: basically you want to write a template rule for this:

<xsl:template match="listOrg">

`<!--something to process your template match here: apply-templates!-->`

</xsl:template>

Think about why we need that! When you do XPath over my site index file, you'll see there are multiple <listOrg> elements, and our outermost list is going to collect all of them in a single list. You want to match on something that holds all the listOrg elements up in your template that matches on the document node ( the one that holds the outer structure of your html document: <xsl:template match="/"> and you want that to hold the thing that contains your output list (either <ul> or <ol>)...
And then, since each listOrg has a distinct identifier: you're going to match on that in a separate template rule so each one is output as a list item.

Then you need to set up, in each one of those list items, a new list to sit inside it. The first time you write this is hard, but we hope you can figure out how this is working!

from dhclass-hub.

ebeshero avatar ebeshero commented on July 25, 2024

@CodyKarch We talked about some of this in class, and you can see some examples of list code and XSLT that some of the other students have pushed to GitHub in Class Examples in XSLT. Browse away--looking at those will likely be helpful!

from dhclass-hub.

ebeshero avatar ebeshero commented on July 25, 2024

@CodyKarch One more thing, because I think we discussed this in class after you left for your advising appt.: If you're confused, try writing your code one step at a time, and run your transformation after each step to see what you're outputting. That can be a clue to how your template rules are working. Remember to select the "HTML" button before you run the transformation, so you can toggle between the text and the html view in the output window.

from dhclass-hub.

CodyKarch avatar CodyKarch commented on July 25, 2024

Great! This should help, and I believe you mentioned that before I left; I've used that rule, and I agree with you on it. Thank you!!!

from dhclass-hub.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.