opencart notes

Site implemented

http://www.hsinglu.idv.tw/

Steps to setup

  1. create subdomain
  2. opencart 1.5.2.1 http://www.opencart.com/
  3. google vqmod for opencart http://code.google.com/p/vqmod/
  4. 中文包 安裝 http://www.opencart.com/index.php?route=extension/extension/info&extension_id=2483
  5. vqmod add more (tweet, google+ facebook; no plurk)
  6. vqmod manufacturer top navigation http://www.opencart.com/index.php?route=extension/extension/info&extension_id=3633 (中文化needs to be addressed)
  7. vqmod view product in admin http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5838
  8. vqmod negative price to contact us button http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5295
  9. vqmod category filter http://www.opencart.com/index.php?route=extension/extension/info&extension_id=2663
  10. vqmod facebook comment http://www.opencart.com/index.php?route=extension/extension/info&extension_id=6026
  11. vqmod admin email format http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4137
  12. city (區) selection module – http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4372
  13. google map and corresponding module configuration
  14. US date format http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4504
  15. import/export tool http://www.opencart.com/index.php?route=extension/extension/info&extension_id=17
  16. 測試
  17. 語系設定
  18. address format configuration http://opencart-hk.blogspot.com/2012/02/translatecountry.html
  19. 貨幣設定
  20. mail setting to notify admin upon registration and order placed
  21. test shopper registration and email notifcation
  22. 收費方式設定
  23. 運送方式設定
  24. 現金回饋/gift certificate and coupon.
  25. backup
  26. update current store listing
  27. enable google analytics
  28. opencart SEO URL
  29. site/product meta tag key words and description
  30. google sitemap generator http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5985
  31. enable google sitemap
  32. submit sitemap to google
  33. facebook OC plugin http://www.opencart.com/index.php?route=extension/extension/info&extension_id=6015

Ajax quick edit (plugin) – Chinese encoding fix

http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4202

in tableditajax.php
 <?php
header('Content-Type: text/html;charset=utf8');
include("../../config.php");
 $bd = mysql_connect(DB_HOSTNAME, DB_USERNAME, DB_PASSWORD) or die("Could not connect database");
mysql_select_db(DB_DATABASE, $bd) or die("Could not select database");
 if($_POST['id'])
{
$id=mysql_escape_String($_POST['id']);
$name=mysql_escape_String($_POST['name']);
$model=mysql_escape_String($_POST['model']);
$price=mysql_escape_String($_POST['price']);
$quantity=mysql_escape_String($_POST['quantity']);
$sort_order=mysql_escape_String($_POST['sort_order']);
$sql = "update ". DB_PREFIX ."product_description set name='$name' where product_id='$id'";
mysql_query('SET NAMES "utf8"');
mysql_query($sql);
$sql = "update ". DB_PREFIX ."product set model='$model' , price='$price' , quantity='$quantity' , sort_order='$sort_order' where product_id='$id'";
mysql_query($sql);
 }
?>

Theme modification

powered by content – /catalog/language/zh-HK/common/footer.php

powered by alignment – /catalog/view/theme/default/stylesheet/stylesheet.css

 

#powered {
margin-top: 5px;
text-align: left;
clear: both;
}

Shipping Module & Customization

  1. admin\controller\shipping\flat.php
  2. admin\language\zh-HK\shipping\flat.php – change text
  3. admin\view\template\shipping\flat.tpl – change image path
  4. catalog\language\zh-HK\shipping\flat.php – change text
  5. catalog\model\shipping\flat.php
  6. admin\view\image\711.gif
  7. text on register page
  8. order of fields on register page
  9. 國家設置 – disable all other countries except Taiwan via SQL
use pnc_blmojhnenc;
select * from oc_country;
UPDATE oc_country SET status = 0 WHERE country_id <> 206;

 

SEO/FB

Opencart setup in 20 minutes

  1. install opencart (1.5.3.1)
  2. install following packages
    • google map
    • facebook comment
    • social
    • chat
    • keepalive admin
    • import/export
  3. setting up zh_TW language
  4. replace US$ to NT$ (TWD)
  5. edit store setting
    • store description
    • store name
    • owner
    • address
    • telephone number
    • fax number
    • email
    • location
    • default language
    • default currency
  6. disable all countries- UPDATE oc_country SET status = 0 WHERE country_id <> 206
  7. set zone setting – convert all english zone names to zh_TW
  8. remove  稅率類別from 商品稅類
  9. covert 區域群組

 

## remove 台中縣 台南縣 高雄縣

 

DELETE FROM oc_zone WHERE country_id =206 AND code IN (‘KH’,’TA’,’TG’);
## 中文名字
update oc_zone set name=’彰化縣’ where code=’CH’ and country_id=206;
update oc_zone set name=’嘉義縣’ where code=’CI’ and country_id=206;
update oc_zone set name=’新竹縣’ where code=’HS’ and country_id=206;
update oc_zone set name=’花蓮縣’ where code=’HL’ and country_id=206;
update oc_zone set name=’宜蘭縣’ where code=’IL’ and country_id=206;
update oc_zone set name=’金門縣’ where code=’KM’ and country_id=206;
update oc_zone set name=’連江縣’ where code=’LC’ and country_id=206;
update oc_zone set name=’苗栗縣’ where code=’ML’ and country_id=206;
update oc_zone set name=’南投縣’ where code=’NT’ and country_id=206;
update oc_zone set name=’澎湖縣’ where code=’PH’ and country_id=206;
update oc_zone set name=’屏東縣’ where code=’PT’ and country_id=206;
update oc_zone set name=’新北市’ where code=’TC’ and country_id=206;
update oc_zone set name=’台東縣’ where code=’TT’ and country_id=206;
update oc_zone set name=’桃園縣’ where code=’TY’ and country_id=206;
update oc_zone set name=’雲林縣’ where code=’CC’ and country_id=206;
update oc_zone set name=’嘉義市’ where code=’YL’ and country_id=206;
update oc_zone set name=’基隆市’ where code=’CL’ and country_id=206;
update oc_zone set name=’新竹市’ where code=’HC’ and country_id=206;
update oc_zone set name=’台中市’ where code=’TH’ and country_id=206;
update oc_zone set name=’台南市’ where code=’TN’ and country_id=206;
update oc_zone set name=’高雄市’ where code=’KC’ and country_id=206;
update oc_zone set name=’台北市’ where code=’TP’ and country_id=206;
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

Up ↑

%d bloggers like this: