Set up a cms page for Magento

2019-07-22 10:28发布

问题:

I've been trying to set up a CMS page in magento to be the home page, and it's just killing me - how hard should this be? no matter what I set up, I get a 404.

Can somebody tell me basic steps to set up a CMS page as the home page for a Magento install, living at:

http://www.mymagentoinstall.com/

I can't have the url key for the CMS page be empty, but setting the default page in the System->Config->Default Pages->CMS Home Page (which seems like it should work), still gives me a 404.

thx for any help

回答1:

Hours of head banging later .... I’ve changed the parameter “Use Web Server Rewrites” on System -> Configuration -> Web from Yes to No. And it worked! My provider set this by default, so had to change it. Only downside is that I now get the /index.php extension added.



回答2:

Did you check to make sure that the page was enabled and visible in your store view?



回答3:

Ok - figured it out. In the System->Config->Web, the Default Web URL needs to be 'cms' (no quotes) - I guess that tells Magento to use the cms page instead of a default url.



回答4:

In csm - pages create some html in the page, eg start simple with

My Homepage

. Give it a name and take care the url is "home" (without the quotes.

Now go to system - configuration - web and select your homepage (name) from the dropdown where in lets you choose the homepage.

That should do it.



回答5:

Your CMS Page Identifier should be home



回答6:

I was running into the same issue. No matter what I did, the home page came back as a 404. I had it working on a test server (with a different database) and compared the options side by side. Absolutely nothing worked, the home page, named 'home' and the 'cms' was properly set, mod_rewrite working, htaccess file just peachy...but domain.com/ wouldn't work. after a few hours I saw that domain.com/home/ did, though I swear it hadn't been.

Finally I wiped the blood off the keyboard where I'd been smashing my head against it and went into url rewrite management and set id path to '/', request path to '/' and target path to '/home/' and it works like it should have all along. Hope this helps someone else!