質問 > 管理機能 > ログインすれば価格を表示できる設定について? |
管理機能
スレッド表示 | 新しいものから | 前のトピック | 次のトピック | 下へ |
投稿者 | スレッド |
---|---|
irony |
投稿日時: 2009/8/5 11:59
対応状況: −−−
|
半人前 登録日: 2008/5/2 居住地: 投稿: 30 |
ログインすれば価格を表示できる設定について? ログインすれば価格を表示できる設定について
http://xoops.ec-cube.net/modules/newbb/viewtopic.php?viewmode=thread&topic_id=4104&forum=2&post_id=17765#forumpost17765 上記の過去ログを参考に設定しておりますが、実現出来ず困っております。 そこで質問させていただくのですが、 list.tpl のどのあたりに下記を追加すれば宜しいのでしょうか? <!--{if $tpl_login}--> <!--{else}--> <!--{/if}--> LC_Page_Products_List.phpの方は、下記のように編集しております。 184行目付近 $objCartSess->setPrevURL($_SERVER['REQUEST_URI']); $objCartSess->addProduct(array($_POST['product_id'], $classcategory_id1, $classcategory_id2), $_POST[$quantity]); $this->sendRedirect($this->getLocation(URL_CART_TOP)); exit; } // ログイン判定 $objCustomer = new SC_Customer(); if($objCustomer->isLoginSuccess()) { //お気に入りボタン表示 $this->tpl_login = true; } サイトデータ EC-CUBEバージョン 2.3.3-comu PHPバージョン PHP 5.2.5 DBバージョン PostgreSQL 8.3.1 宜しくお願い致します。 |
kishik |
投稿日時: 2009/8/5 14:34
対応状況: −−−
|
仙人 登録日: 2009/4/3 居住地: 東京 投稿: 382 |
Re: ログインすれば価格を表示できる設定について? <!--{if $tpl_login}-->
(ログイン時に表示する内容) <!--{else}--> (ログインしていない時に表示する内容) <!--{/if}--> なので、 あとは価格表示をさせたくないのであれば、 テンプレート内の希望部分に当てはめてやればいいと思いますよ。 ----- カスタマイズ承ります http://ec-cube-mall.jp/ http://ec-cube.ec-orange2.jp/ http://wiki.ec-orange2.jp/ |
irony |
投稿日時: 2009/8/5 15:31
対応状況: −−−
|
半人前 登録日: 2008/5/2 居住地: 投稿: 30 |
Re: ログインすれば価格を表示できる設定について? kishik 様
ご返信ありがとうございます。 下記のように変更いたしましたが、改善されませんでした。 修正箇所などわかりましたら、ご教授いただけないでしょうか? 編集前 <span class="pricebox sale_price"> <!--{$smarty.const.SALE_PRICE_TITLE}--><span class="mini">(税込)</span>: <span class="price"> <!--{if $arrProducts[cnt].price02_min == $arrProducts[cnt].price02_max}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{else}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}-->〜<!--{$arrProducts[cnt].price02_max|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{/if}-->円</span> </span> 編集後 <!--{if $tpl_login}--> <span class="pricebox sale_price"> <!--{$smarty.const.SALE_PRICE_TITLE}--><span class="mini">(税込)</span>: <span class="price"> <!--{if $arrProducts[cnt].price02_min == $arrProducts[cnt].price02_max}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{else}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}-->〜<!--{$arrProducts[cnt].price02_max|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{/if}-->円</span> <!--{/if}--> </span> |
ecbg |
投稿日時: 2009/8/5 15:39
対応状況: −−−
|
仙人 登録日: 2009/2/25 居住地: 東京 投稿: 387 |
Re: ログインすれば価格を表示できる設定について? 確認してませんが、ログインしていないときに何も表示しないのであれば、<!--{else}-->から<!--{/if}-->の間に何も必要ありませんよ。
<!--{if $tpl_login}--> <span class="pricebox sale_price"> <!--{$smarty.const.SALE_PRICE_TITLE}--><span class="mini">(税込)</span>: <span class="price"> <!--{if $arrProducts[cnt].price02_min == $arrProducts[cnt].price02_max}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{else}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}-->〜<!--{$arrProducts[cnt].price02_max|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{/if}-->円</span> </span> <!--{else}--> <!--{/if}--> |
irony |
投稿日時: 2009/8/5 15:53
対応状況: −−−
|
半人前 登録日: 2008/5/2 居住地: 投稿: 30 |
Re: ログインすれば価格を表示できる設定について? ecbg 様
ありがとうございます。 教えていただいた通りにソースを変更してみましたが、 改善されませんでした。 商品一覧のページで、販売価格(税込)が表示されたままです。 |
ecbg |
投稿日時: 2009/8/5 16:00
対応状況: −−−
|
仙人 登録日: 2009/2/25 居住地: 東京 投稿: 387 |
Re: ログインすれば価格を表示できる設定について? ちなみに先ほどのソースの上に<!--{$tpl_login}-->を記入したときにログインとログアウトで「」内の数値は変わりますか?
「<!--{$tpl_login}-->」 <!--{if $tpl_login}--> |
irony |
投稿日時: 2009/8/5 16:26
対応状況: −−−
|
半人前 登録日: 2008/5/2 居住地: 投稿: 30 |
Re: ログインすれば価格を表示できる設定について? ecbg 様
ありがとうございます。 >ちなみに先ほどのソースの上に<!--{$tpl_login}-->を >記入したときにログインとログアウトで「」内の数値は変わりますか? こちらの 「」内の数値は変わりますか? とはどういう意味になりますでしょうか? 確認する方法を教えていただけますでしょうか? |
ecbg |
投稿日時: 2009/8/5 16:31
対応状況: −−−
|
仙人 登録日: 2009/2/25 居住地: 東京 投稿: 387 |
Re: ログインすれば価格を表示できる設定について? phpファイルから$tpl_loginがちゃんと取り出せているのであれば、以下のように記載したときにログイン状態とログアウト状態では違う数値が入る(0か1)のでテスト的にテンプレートに「<!--{$tpl_login}-->」を記入してみてブラウザで確認してみてはどうですかという意味だったのですが。
「<!--{$tpl_login}-->」 <!--{if $tpl_login}--> <span class="pricebox sale_price"> <!--{$smarty.const.SALE_PRICE_TITLE}--><span class="mini">(税込)</span>: <span class="price"> <!--{if $arrProducts[cnt].price02_min == $arrProducts[cnt].price02_max}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{else}--> <!--{$arrProducts[cnt].price02_min|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}-->〜<!--{$arrProducts[cnt].price02_max|sfPreTax:$arrSiteInfo.tax:$arrSiteInfo.tax_rule|number_format}--> <!--{/if}-->円</span> </span> <!--{else}--> <!--{/if}--> |
kishik |
投稿日時: 2009/8/5 17:48
対応状況: −−−
|
仙人 登録日: 2009/4/3 居住地: 東京 投稿: 382 |
Re: ログインすれば価格を表示できる設定について? あと一つ確認したいのですが、
現在はどういう風に表示されているのか もう少し具体的に教えてもらえませんか? ----- カスタマイズ承ります http://ec-cube-mall.jp/ http://ec-cube.ec-orange2.jp/ http://wiki.ec-orange2.jp/ |
seasoft |
投稿日時: 2009/8/6 0:22
対応状況: −−−
|
神 登録日: 2008/6/4 居住地: 投稿: 7367 |
Re: ログインすれば価格を表示できる設定について? 関係無さそうですが、下記の方が良いような。(未検証)
↓
|
(1) 2 » |
スレッド表示 | 新しいものから | 前のトピック | 次のトピック | トップ |