How can I use .htm or .html extensions with Site Builder? (v. 2.9)
There are two different ways to use .htm extensions with SiteBuilder. They are both optional and are completely independent of each other, so you can just use one or the other (or both - or neither), depending on your needs.
-
Site Pages - You can change all the main site pages so they use .htm (or .html) extensions. In other words, the catalog page is catalog.htm instead of catalog.php, and the contact page is contact.htm instead of contact.php, and a page called 'aboutus' is /pages/aboutus.htm instead of /pages/aboutus.php.
To set up site page mime types:
-
Log in to the site via FTP
- OR -
Log in to the storeadmin area as a master administrator, visit
http://yourwebsiteurl/storeadmin/variables.php?show_htaccess=y
And click 'Change File' to access your main .htaccess file content.
-
Add your MIME type
Find the correct MIME type statement for your site, and add it to the .htaccess file.
- Change your extension
In the storeadmin area, select Site Settings under Administration and change Page Extension to the desired extension.
-
Check your pages
Make sure any direct links that you have hard coded into your templates are pointing to the new link format.
-
-
Catalog Pages - You can also change the page extensions for catalog pages that have an item or category selected (as well as the articles page when an article is selected). This works independently of the site page mime types, and is used mostly for search engine optimization. It changes a page from the format http://website.com/catalog.php?category=7 to http://website.com/category_7/Some-Category.htm
To set up the catalog page redirects:
-
Change your extension
Log in to the storeadmin area, and change Static Ext in Site Settings under Administration to the desired extension. (If this is blank, static pages will not be used.)
-
Change your directories
If desired, change the following:
-
Category Dir: This creates the trigger word in category pages (e.g. "category" in the link http://website.com/category_22/Jewelry.htm)
-
Item Dir: This creates the trigger word in category pages (e.g. "item" in the link http://website.com/item_35/Diamond_Necklace.htm)
-
Article Dir: This creates the trigger word in article pages (e.g. "article" in the link http://website.com/article_41/What_Your_Jewelry_Says_About_You.htm)
-
-
Update settings
Click Update Variables and the system will automatically apply the redirect settings for you. A backup of your .htaccess file will be made.
-