Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Custom homepage not working: 404 Not Found

edited December 2011 in Vanilla 2.0 - 2.8

I would like to change my homepage, and found out how to do so, but when I change it, I get a 404 not found, even though it does exist. I have http://www.yourcorner.org showing All Categories right now, but would really like it to show http://yourcorner.org/pages/homepage/ (which does exist). When I put in "pages/homepage" in the "Enter the url to the page you would like to use as your homepage" box, I get the error. And ideas?

Answers

  • ToddTodd Chief Product Officer Vanilla Staff

    I'm not familiar with the pages plugin, but I'm guessing that it needs to look at the url to determine which page to display. When there is no page in the url due to the default route then it doesn't know where you are.

    I recommend doing something like the following in a plugn:

    public function ProfileController_Homepage_Create($Sender) {
       // Put your homepage.php file into the /views folder of this plugin.
       $Sender->Render('Homepage', '', 'plugins/NameOfThisPlugin');
    }
    

    You can then browse to profile/homepage and make that your homepage.

  • Thank, but actually I am not using that plugin. I just created a directory myself with an HTML file in it that is very similar to the actual design. Should I try what you said anyways?

  • sahotataransahotataran Developer, Bay Area - CA ✭✭✭

    i would suggest you download the Custom pages plugin and create you this page in that plugin.
    the plugin will tell you what is the URL for this page and then you can use this URL as your home page.

    There was an error rendering this rich post.

  • Did you find a solution for this?
    I'm facing with this exact issue
    I do have the pages plugin, but the result is the same (404)

  • vrijvlindervrijvlinder Papillon-Sauvage MVP

    Please start a new discussion this one is in necromancy ...

Sign In or Register to comment.