We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 3749
    • 24,544 Posts
    Quote from: Chaps at Feb 23, 2011, 02:22 PM

    I’ll try and find a ’proper’ template and disect it, figure out how to use the <base href="[[++site_url]]" />.

    You just put it in the <head> section of all your templates -- as is. Not having it could be the cause of many of your problems.

    <base href="[[++site_url]]" />


      Did I help you? Buy me a beer
      Get my Book: MODX:The Official Guide
      MODX info for everyone: http://bobsguides.com/modx.html
      My MODX Extras
      Bob's Guides is now hosted at A2 MODX Hosting
      • 4948
      • 33 Posts
      Thanks

      Disected one of the templates and added the following code into my head tags

      
      <base href="[[++site_url]]" />
      
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
      <title>[[*pagetitle]]</title>
      <meta name="description" content="[[*description]]"/>
      
      <link href="/css/styles3.css" rel="stylesheet" type="text/css">
      
      



      Its still not working.
        • 3749
        • 24,544 Posts
        You might have to remove any slashes on the front end of the paths, since site_url ends with one.

        BTW, when things get weird, it’s always worth going here to check for HTML code errors:

        http://validator.w3.org/

        Sometimes, you can spend a lot of time looking for PHP errors and MODx configuration errors when the problem is just an unclosed HTML tag or a bad DOCTYPE. wink
          Did I help you? Buy me a beer
          Get my Book: MODX:The Official Guide
          MODX info for everyone: http://bobsguides.com/modx.html
          My MODX Extras
          Bob's Guides is now hosted at A2 MODX Hosting
          • 4948
          • 33 Posts
          Thanks just validated to as "XHTML 1.0 Strict!" so all is good now with the structure smiley. Still no tinyMCE in the front end - any other hints?
            • 3749
            • 24,544 Posts
            Are the links in the source all pointing to files (that is, can you click on them in FF "View Source" and see the file content)?

            If so, I’m out of ideas.
              Did I help you? Buy me a beer
              Get my Book: MODX:The Official Guide
              MODX info for everyone: http://bobsguides.com/modx.html
              My MODX Extras
              Bob's Guides is now hosted at A2 MODX Hosting
              • 4948
              • 33 Posts
              Guess Im on my own now? huh

              Used FF and Firebug, looked at the references for the javascript, and they were deifintiely in the document (i.e. I expanded the javascript lines and they displayed the code from the js files) so the references are accurate. Ive played around with the code in my head, eveything is validateing strict xhtml.

              Also tried comparing the tinmce references from the backend/manager screens to the code from my template and they are virtually identical, apart from a parameter at the end of the link.

              I’m now trying to get a "professional" template to work as that should have all the proper snippets/chunks in the right place.

              When I ran the the newspublisher page for the first time, it seemed to put the within a folder, is that correct? What would happen if I moved it out of the folder so the newpublisher page was at the same level as all my other pages, would that cause me problems?

              Thanks again

                • 3749
                • 24,544 Posts
                The &parentid parameter (note the lowercase i ) will let you put new docs wherever you want and the NewsPublisher page itself can be at any level.
                I don’t think that’s going to help you solve any problems getting TinyMCE to show up, because it won’t change the paths to the TinyMCE files, which seems to be your problem.

                BTW, do you have FURLs turned on? The rewrite base in the .htaccess file could be an issue.

                You might also check the site_url value in core/config/config.inc.php to see if it has a leading slash.
                  Did I help you? Buy me a beer
                  Get my Book: MODX:The Official Guide
                  MODX info for everyone: http://bobsguides.com/modx.html
                  My MODX Extras
                  Bob's Guides is now hosted at A2 MODX Hosting
                  • 4948
                  • 33 Posts
                  Hi Bob,

                  Folder structure was a longshot, but I do (did) have the FURLS turned on, I’ve turned this off and Ive also removed the modx rewrite code the in ht.access file. I’ve cleared the site cache and although the pages are now displaying as index.php?id=24 no tinyMCE. Ive compared the javascript/tinyMCE links from my template to that of the manager screen and all the references look identical. When I open up the page in Firebug, all the javascript for the tinyMCE is in the page, so I think the references to files are working ok....

                  I am right in thinking the tinyMCE editor places the editor into the [[*Content]] snippet. Incidentally, I downloaded a proper template from the modx site, which was revolution compatible and applied the template to my newspublisher page, again no editor on the form so I think the template is ok. So if th template is OK and the references to the File look the same as the manager screen which works.

                  Looked into my config file. I have entries for
                  $site_id
                  $site_sessionname

                  however I dont have any entries for site_url

                  So close, think I have a feeling I’m going to lose this battle :’(
                    • 4948
                    • 33 Posts
                    Hi Bob,

                    Been trying to disect and do whatever possible to get the editor working. Still not having much luck. Ive attached a screen of Firefox with Firebug open of my page. It does say the editor is installed doesnt it? If thats the case then I dont think its the paths to the editor? Thought a screenshot might me of some use?

                    Thanks again

                      • 3749
                      • 24,544 Posts
                      Quote from: Chaps at Feb 26, 2011, 01:55 PM

                      Hi Bob,

                      Been trying to disect and do whatever possible to get the editor working. Still not having much luck. Ive attached a screen of Firefox with Firebug open of my page. It does say the editor is installed doesnt it? If thats the case then I dont think its the paths to the editor? Thought a screenshot might me of some use?

                      Thanks again

                      I looks like it’s loaded, but if any part of TinyMCE is missing or corrupted, you’ll usually see nothing in the rich text fields but what you would get without TimyMCE.
                        Did I help you? Buy me a beer
                        Get my Book: MODX:The Official Guide
                        MODX info for everyone: http://bobsguides.com/modx.html
                        My MODX Extras
                        Bob's Guides is now hosted at A2 MODX Hosting