We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36747
    • 138 Posts
    I was thinking that many of the MODx sites uses SEF URL and I’d be great if instead of getting a 404 page when the url doesn’t exist you could get a search in the site of that URL.

    For example:
    url: www.modxcms.com/test.html

    If test.html doesn’t exist, I’d like to get a page saying that the url is wrong and a list of suggestion where the visitor could get information about ’test’.

    I couldnt find anything like this in the forums!

    cheers
    emi
      patagonia, argentina
      • 18397
      • 3,250 Posts
      Look at the url string when you hit a MODx 404 page and you will see some interesting things.
        • 22303 MODX Staff
        • 10,725 Posts
        Also, if you have the default content installed somewhere, you can go to your Administration --> System Configuration in the manager, then on the Site Settings tab, find the Error Page and set the ID to 7 (this will be already set in future releases), and you’ll get an example of this when navigating to non-existent URLs that presents a site map and some search options.
          • 32241
          • 1,495 Posts
          I believe that mark refer to the query string that are being produced by the error. So in the error page you can use snippet to parse that error querystring and do what you want with it. Either using search or display it again with some special formating and etc.

          Is that correct mark?


          Regards,
          Wendy Novianto
            Wendy Novianto
            [font=Verdana]PT DJAMOER Technology Media
            [font=Verdana]Xituz Media
            • 18397
            • 3,250 Posts
            Yup.
              • 3760
              • 7 Posts
              How do you set the 404 page?

              On my website the wrong page is just blank.