Post by puyopuy » Sat Feb 11, 2012 11:29 am

Hi guys,

I'm new to OpenCart. I just want to have SEO URLs.

I installed new OpenCart 1.5.1.3 on wampserver 2.2 and enabled SEO URL(Settings->Server) and renamed htaccess.txt to .htaccess. I checked that mod-rewrite is enabled. Restarted the web server but still got the long URL like "index.php?route=product/category&path=25_29".

I did search the forum and I found this topic and I follow the instructions and did the following:

1. Downloaded vqmod-2.1.5-opencart.zip and install successful
2. Downloaded seo_mod.xml and copy it to vqmod\xml
3. Execute the following SQL in phpMyAdmin

Code: Select all

INSERT INTO url_alias (query, keyword) VALUES ('common/home', '');
    INSERT INTO url_alias (query, keyword) VALUES ('account/wishlist', 'wishlist');
    INSERT INTO url_alias (query, keyword) VALUES ('account/account', 'my-account');
    INSERT INTO url_alias (query, keyword) VALUES ('checkout/cart', 'shopping-cart');
    INSERT INTO url_alias (query, keyword) VALUES ('checkout/checkout', 'checkout');
    INSERT INTO url_alias (query, keyword) VALUES ('account/login', 'login');
    INSERT INTO url_alias (query, keyword) VALUES ('account/logout', 'logout');
    INSERT INTO url_alias (query, keyword) VALUES ('account/order', 'order-history');
    INSERT INTO url_alias (query, keyword) VALUES ('account/newsletter', 'newsletter');
    INSERT INTO url_alias (query, keyword) VALUES ('product/special', 'specials');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/account', 'affiliates');
    INSERT INTO url_alias (query, keyword) VALUES ('checkout/voucher', 'gift-vouchers');
    INSERT INTO url_alias (query, keyword) VALUES ('product/manufacturer', 'brands');
    INSERT INTO url_alias (query, keyword) VALUES ('information/contact', 'contact-us');
    INSERT INTO url_alias (query, keyword) VALUES ('account/return/insert', 'request-return');
    INSERT INTO url_alias (query, keyword) VALUES ('information/sitemap', 'sitemap');
    INSERT INTO url_alias (query, keyword) VALUES ('account/forgotten', 'forgot-password');
    INSERT INTO url_alias (query, keyword) VALUES ('account/download', 'downloads');
    INSERT INTO url_alias (query, keyword) VALUES ('account/return', 'returns');
    INSERT INTO url_alias (query, keyword) VALUES ('account/transaction', 'transactions');
    INSERT INTO url_alias (query, keyword) VALUES ('account/register', 'create-account');
    INSERT INTO url_alias (query, keyword) VALUES ('product/compare', 'compare-products');
    INSERT INTO url_alias (query, keyword) VALUES ('product/search', 'search');
    INSERT INTO url_alias (query, keyword) VALUES ('account/edit', 'edit-account');
    INSERT INTO url_alias (query, keyword) VALUES ('account/password', 'change-password');
    INSERT INTO url_alias (query, keyword) VALUES ('account/address', 'address-book');
    INSERT INTO url_alias (query, keyword) VALUES ('account/reward', 'reward-points');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/edit', 'edit-affiliate-account');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/password', 'change-affiliate-password');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/payment', 'affiliate-payment-options');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/tracking', 'affiliate-tracking-code');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/transaction', 'affiliate-transactions');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/logout', 'affiliate-logout');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/forgotten', 'affiliate-forgot-password');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/register', 'create-affiliate-account');
    INSERT INTO url_alias (query, keyword) VALUES ('affiliate/login', 'affiliate-login');

   
And again this doesn't work. Can anyone tell me what do I did wrong? Can OpenCart come up with an easy way to do that?

BTW, I installed OpenCart on my desktop so I cannot a link for you.

Thank you for your help and time in advance.
puyo
Last edited by puyopuy on Sun Feb 12, 2012 8:37 am, edited 1 time in total.

Newbie

Posts

Joined
Fri Feb 10, 2012 11:47 pm

Post by puyopuy » Sat Feb 11, 2012 12:38 pm

After I put change RewriteBase to "RewriteBase /opencart" in .htaccess file, I got some links work as expected but some are not

e.g.
http://localhost:8081/opencart/desktops/mac
http://localhost:8081/opencart/contact-us

but some categories/products still showing like this:

Monitors: http://localhost:8081/opencart/index.ph ... path=25_28
Cameras: http://localhost:8081/opencart/index.ph ... ry&path=33
product page: http://localhost:8081/opencart/index.ph ... duct_id=30

Newbie

Posts

Joined
Fri Feb 10, 2012 11:47 pm

Post by gwp » Sun Feb 12, 2012 2:37 am

make sure you have seo keywords set for each category in your admin.

this happened to me, some had seo keyword, some didnt

gwp
New member

Posts

Joined
Sun Jan 22, 2012 2:48 am

Post by puyopuy » Sun Feb 12, 2012 8:33 am

Thank you very much gwp, you save me a lot of time. I think they should update the documentation to include your tricks. :)

Use SEO URL's
To use Search Engine Friendly SEO URL's with product or page names instead of page numbers, first Apache module mod-rewrite MUST be installed (ask your web host) and you must rename the htaccess.txt to .htaccess. Read the htaccess.txt file for more information

Newbie

Posts

Joined
Fri Feb 10, 2012 11:47 pm
Who is online

Users browsing this forum: No registered users and 44 guests