hdknr’s posterous

 
Filed under

eccube

 

EC-CUBEのメールテンプレート追加 LUNARAVE WEBクリエーターの仕事と休息/ウェブリブログ

それぞれのメールテンプレートはDBに保存されているものの、テンプレートの数自体はシステムの設定ファイルで管理されている。


それは、/data/conf/conf.phpであり、「$arrMAILTEMPLATE = array(略)」 に追加することで可能だ。


// メールテンプレートの種類
$arrMAILTEMPLATE = array(
  1 => "注文受付メール"
 ,2 => "注文キャンセル受付メール"
 ,3 => "取り寄せ確認メール"
 ,4 => "配送連絡メール"
 ,5 => "予備"
);



加えて、その下の「$arrMAILTPLPATH = array(略)」には上記で追加した4、5に合わした形で利用するテンプレートを設定する。


// 各テンプレートのパス
$arrMAILTPLPATH = array(
1 => "mail_templates/order_mail.tpl",
2 => "mail_templates/order_mail.tpl",
3 => "mail_templates/order_mail.tpl",
4 => "mail_templates/custom_templates.tpl",
5 => "mail_templates/custom_templates.tpl",
);



ここで4、5で「custom_templates.tpl」を追加したが、現在このファイルは存在しないので、以下を記述して「custom_templates.tpl」という名前で保存する。









このファイルを「/data/Smarty/templates/mail_templates/」に保存する。

Filed under  //   EC-CUBE  

Comments [0]

オーダーメールテンプレート追加

■無いテンプレートを指定した場合は、「/data/Smarty/templates/mail_templates/」に作成して保存。

自分の場合。。
「注文受付メール」
「注文キャンセル受付メール」
「取り寄せ確認メール」
「注文確定振込依頼メール」(追加)
「配送連絡メール」(追加)

です。4は別テンプレが使っている風だったので、5と6に追加しておきました。

Filed under  //   EC-CUBE  

Comments [0]

EC-CUBEインストールマニュアル/オンラインマニュアル [サービスご利用中のお客様向け情報] −  専用レンタルサーバー|レンタルサーバーのWADAX  @Next Style

2.インストール時のパーミッション設定

tar.gzファイルの解凍コマンド
tar xvzfpeccube-2.*.*.tar.gz

上記コマンドによって権限エラーが出ずにインストールできます。

権限を与えるコマンド
chmod-R 777 data/cache/
chmod-R 777 html/install/temp
chmod666 data/install.php
chmod-R 777 html/user_data/
chmod-R 777 html/cp
chmod-R 777 html/upload/
chmod-R 777 data/class
chmod-R 777 data/Smarty/
chmod-R 777 data/logs/
chmod-R 777 data/downloads/

既にdata,htmlを設置済みの場合など。上記コマンドで解凍した場合は必要なし。

Filed under  //   EC-CUBE  

Comments [0]

EC-CUBE : インストール

deblen:/var/www/hdknr.deb# wget http://downloads.ec-cube.net/src/eccube-2.3.4.tar.gz
--2009-04-28 09:58:45--  http://downloads.ec-cube.net/src/eccube-2.3.4.tar.gz
downloads.ec-cube.net をDNSに問いあわせています... 210.188.195.143
downloads.ec-cube.net|210.188.195.143|:80 に接続しています... 接続しました。
HTTP による接続要求を送信しました、応答を待っています... 200 OK
長さ: 7092503 (6.8M) [application/x-gzip]
`eccube-2.3.4.tar.gz' に保存中

100%[======================================>] 7,092,503    451K/s 時間 16s    

2009-04-28 09:59:01 (443 KB/s) - `eccube-2.3.4.tar.gz' へ保存完了 [7092503/7092503]

deblen:/var/www/hdknr.deb# tar xvf eccube-2.3.4.tar.gz
解凍

deblen:/var/www/hdknr.deb# mv eccube-2.3.4 shop_wine

deblen:/var/www/hdknr.deb# vi conf/httpd.conf.d/shop_wine.conf
Alias /shop/wine /var/www/hdknr.deb/shop_wine/html

<Location /shop/wine >
    Options All
    Order allow,deny
    Allow from all

</Location>

deblen:/var/www/hdknr.deb# mkdir -p mysql/shop_wine
deblen:/var/www/hdknr.deb# echo "shop_wine shop_wine" > mysql/shop_wine/owner.txt

deblen:/var/www/hdknr.deb# cat /var/www/bin/mysql_new.sh
#!/bin/sh

DB=`basename $1`
ID=$1/owner.txt

if [ -f $ID ] ; then
  cat $ID | while read FILE ; do
    set -- $FILE ;
    CMD1="create database $1 DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ; "
    CMD2="grant all privileges on $DB.* to '$1'@'localhost' identified by '$2'"
    echo $CMD1
    echo $CMD2
    if [ $2 != '' ] ; then
       echo "Executiing..."
       echo $CMD1 | mysql -p
       echo $CMD2 | mysql -p
    fi
  done
fi

deblen:/var/www/hdknr.deb# /var/www/bin/mysql_new.sh mysql/shop_wine RUN

deblen:/var/www/hdknr.deb/shop_wine# more /var/www/bin/ec-cude.sh
#!/bin/sh
cat <<EOF | while read LINE ;do chmod -R 777 $1/$LINE ; done
data/install.php
html/user_data
html/cp
html/upload
data/cache
data/class
data/Smarty
data/logs
data/downloads
EOF

deblen:/var/www/hdknr.deb/shop_wine# /var/www/bin/ec-cude.sh shop_wine

deblen:/var/www/hdknr.deb/shop_wine# chown -R www-data:www-data .
deblen:/var/www/hdknr.deb/shop_wine# ls -al
合計 36
drwxr-xr-x  4 www-data www-data  4096 2009-02-26 21:08 .
drwxr-xr-x  7 root     root      4096 2009-04-28 10:05 ..
-rw-r--r--  1 www-data www-data 17987 2007-10-17 18:25 COPYING
drwxr-xr-x 14 www-data www-data  4096 2009-02-26 21:08 data
drwxr-xr-x 26 www-data www-data  4096 2009-04-28 11:33 html

deblen:/var/www/hdknr.deb# /etc/init.d/apache2 restart
Restarting web server: apache2 ... waiting .









deblen:/var/www/hdknr.deb# rm shop_wine/html/install/index.php








Filed under  //   EC-CUBE  

Comments [0]

ec-cube:install on VirtualBox Lenny

1. MySQLデータベース作成
  DB/USER/PWD = shop/shop/shop
 
2. http://hdknr.box/shop/ でアクセス
 
  443 ln -sf /home/hdknr/sites/hdknr.box/eccube-2.3.4/html /home/hdknr/sites/hdknr.box/www/shop
 
 
3. File permission : いい加減
 
453 chmod 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/data/cache/
  454 chmod 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/html/install/temp
  455 chmod 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/html/user_data
  456 chmod 666 /home/hdknr/sites/hdknr.box/eccube-2.3.4/data/install.php
  457 chmod -R 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/html/user_data
  458 chmod -R 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/html/upload
  459 chmod -R 666 /home/hdknr/sites/hdknr.box/eccube-2.3.4/data/class
  460 sudo chmod -R 666 /home/hdknr/sites/hdknr.box/eccube-2.3.4/data/class
  461 sudo chmod -R 777 /home/hdknr/sites/hdknr.box/eccube-2.3.4/data
 
4. httpd.conf
 
$ more /home/hdknr/sites/hdknr.box/conf/httpd.conf | grep -v "^$"

#Basic
  ServerAdmin admin@mishima.ms
  ServerName hdknr.box:80
  DocumentRoot /home/hdknr/sites/hdknr.box/www/
#Log
  ErrorLog /home/hdknr/sites/hdknr.box/logs/error_log
  LogLevel warn
  CustomLog /home/hdknr/sites/hdknr.box/logs/access_log combined
# Virtual Directories and Others
  Include /home/hdknr/sites/hdknr.box/conf/httpd.conf.d/*.conf
# phpmyadmin
  Include /etc/phpmyadmin/apache.conf

 
5. install 削除
 
hdknr@deblen:~/sites/hdknr.box/www/shop$ rm -rf install/

Filed under  //   EC-CUBE   Lenny   VirtualBox  

Comments [0]