We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 25006
    • 10 Posts
    Hi,

    Im very new to ModX (have been using it for about a week or so), used to use Joomla/PHP-Nuke but hated their lack of customisation and SEF options which ModX is excellent in.

    The only problem i am having is with templates. I have tried a few and not found any im particularly keen on, so found www.modxhost.com and wanted to use that template. I noticed a /modxhost/ folder in my /templates/ directory and have been trying to use that (adding a new template from the modxhost.tpl file) but it doesnt work at all. I have tried messing with the template code to remove some of the style sheets that arent needed but its not working and im stuck!

    Here is the template code:

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    <head>
    <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    <link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="[(site_url)][~11~]" />
    <link title="Trend" rel="stylesheet" type="text/css" href="[(base_url)]assets/templates/default/fashion-modx-clear.css" />
    <link rel="stylesheet" type="text/css" href="[(base_url)]assets/templates/default/modx.css" />
    <link rel="stylesheet" type="text/css" href="[(base_url)]assets/templates/default/print.css" media="print" />
    <link title="ZiX" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/zi-modx-1.css" />
    <link title="ZiX Background" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/zi-modx-2.css" />
    <link title="Trend (Alternate)" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/default.css" />
    <link title="Light" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/light_green.css" />
    <link title="Light Green" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/light.css" />
    <link title="Dark" rel="alternate stylesheet" type="text/css" href="[(base_url)]assets/templates/default/dark.css" />
    <script src="[(base_url)]assets/templates/default/styleswitcher.js" type="text/javascript"></script>
    <base href="[(site_url)]" />
    <title>[(site_name)] | [*pagetitle*]</title>
    <script src="manager/media/script/scriptaculous/prototype.js" type="text/javascript"></script>
    <script src="manager/media/script/scriptaculous/scriptaculous.js" type="text/javascript"></script>
    <script src="assets/snippets/AjaxSearch/AjaxSearch.js" type="text/javascript"></script>
    </head>
    <body>
    <div id="wrap">
      <div id="header">
        <div id="title">
          <h1><a href="[~[(site_start)]~]">[(site_name)]</a></h1>
          <p id="slogan">{{slogan}}</p>
        </div>
        <h2 class="hide">Main menu</h2>
        <div id="mainmenu">[!DropMenu? &selfAsLink=`1` &useCategoryFolders=`0` &startDoc=`0` &levelLimit=`1` &hereClass=`current`!]</div>
        <div class="clear"></div>
      </div>
      <div id="leftside">
        <div id="lmenu" style="display: none;">
          <h2>Menu</h2>
          [!DropMenu? &selfAsLink=`1` &useCategoryFolders=`0` &startDoc=`0` &hereClass=`current`!]</div>
        <h2>Search</h2>
        [!AjaxSearch!]
        <h2>News</h2>
        [[NewsListing? &startID=`2` &summarize=`1` &total=`1` &commentschunk=`FormBlogComments` &tpl=`nl_sidebar` &showarch=`0` &truncLen=`100` &truncSplit=`0`]]
        <h2>Login</h2>
        <div id="sidebarlogin">[!WebLogin? &tpl=`FormLogin` &loginhomeid=`[(site_start)]`!]</div>
        <h2>Styles</h2>
        {{styles}} </div>
      <div id="contentwide">
        <h2>[*longtitle*]</h2>
        [*#content*] </div>
      <div id="footer">
        <p> {{footer}}</p>
        <p>MySQL: [^qt^], [^q^] request(s), PHP: [^p^], total: [^t^], document retrieved
          from [^s^].</p>
      </div>
    </div>
    </body>
    </html>
    


    Can anyone help? Im now completely stuck and need all the help i can get! Or if anyone knows any good similar templates that are XHTML/CSS compliant that would be brilliant?

    Thanks.

    huh
      • 10487 MODX Staff
      • 1,535 Posts
      In terms of stylesheets, if you’re only interested in the MODxHost theme then you can take out any of the stylesheet references that have a title assigned to them (Trend, Dark etc.) and if you’re not planning on using the styleswitcher you could remove the JS call to that code.

      As for other templates, you can always check the MODx Repository - there’s quite a few in there. And, don’t forget sites like www.oswd.org, pretty much any of the templates on there can be converted to work with MODx with a little amount of time and effort.

        Garry Nutting
        Senior Developer
        MODX, LLC

        Email: [email protected]
        Twitter: @garryn
        Web: modx.com