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

    I am trying to generate an XML Sitemap using Wayfinder. I followed the technique described in this forum post - http://modxcms.com/forums/index.php?topic=30354.0 - and it produces the sitemap as desired, with the exception of one oddity! Each of the links has had the "http://" munged into "http:/", so for example, I get something like the following:

    <?xml version="1.0" encoding="UTF-8" ?>
    <urlset xmlns="http:/www.sitemaps.org/schemas/sitemap/0.9" xmlns:xsi="http:/www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http:/www.sitemaps.org/schemas/sitemap/0.9 http:/www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
    <url>
    <loc>http:/www.foo.com/</loc>
    <changefreq>weekly</changefreq>
    </url>
    etc, etc...
    </urlset>

    The content for the <loc> tag comes from the wf.link variable in the template. However, notice that even the xmlns address has been munged, so this problem might not be specific to the Wayfinder code (if so, apologies for posting in the wrong place!). Does anyone have any suggestions as to where the slash might be being consumed? I noticed that if if use the string "http:////" for the hardcoded xmlns directive, it appears as "http://" in the final sitemap, so this looks like an character escaping problem somewhere.

    I am using MODx 1.0.0 presently.

    Regards,

    Dan
      • 20126
      • 4 Posts
      Hi All,

      I’ve done some more poking and this is a very, very strange problem and I can’t blame Wayfinder at all! I will post in another forum shortly.

      The symptom seems to be this - if I create a new page for my site, all double slashes (ie, "//") get munged into a single slash (ie, "/"). All existing pages do not exhibit this behavior. In fact, if I edit an old page and add "http://foo.bar.com/" to the content, it displays fine, while in a newly created page it gets displayed as "http:/foo.bar.com/".

      This is very strange and quite inexplicable! Any suggestions would be greatly appreciated!’

      Cheers,

      Dan
        • 26610
        • 25 Posts
        I’ve got the same problem! Please help us...
          • 20413
          • 2,877 Posts
            @hawproductions | http://mrhaw.com/

            Infograph: MODX Advanced Install in 7 steps:
            http://forums.modx.com/thread/96954/infograph-modx-advanced-install-in-7-steps

            Recap: Portland, OR (PDX) MODX CMS Meetup, Oct 6, 2015. US Bancorp Tower
            http://mrhaw.com/modx_portland_oregon_pdx_modx_cms_meetup_oct_2015_us_bancorp_tower