We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 14431
    • 65 Posts
    Yet Another NewB Question - Where do things go?
    Say I have a SAX XML parser that is used by several elements (snippets). Is there a central location where I would put this file? How would I access it?

    Same for a general purpose HTML parser (probably the same place??).

    What if I want to add another JS library like YUI or Dojo (or both?)... where do they go? How do I get the links added to the HTML? Do I have to hand write the remote links?

    What about multiple CSS files where I do not want the CSS displayed in the source? I’ve read some posts about CSS as documents but how you get the appropriate reference in the page is not clear (to me).

    Sorry if this is all to obvious and thanks for you Patience,
    joe
      • 25663 MODX Staff
      • 12,272 Posts
      Put them wherever you’d like them on the filesystem, just like you would were they in a statically built site. Every folder in the front end is relative to the main index file. If you have friendly URLs with alias paths turned on, then you’ll need a base href first thing in your document head.

      Good locations for JS libs might be assets/js/ ... I tend to put my external stylesheets in assets/site/ ... but there are no rules about where you have to put anything.

      Need further clarification, just ask away. laugh
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me