Forums / Templates, Stylesheets, Page Layout / Adding a new Product Type Info Page Layout options :: Product - General

Adding a new Product Type Info Page Layout options :: Product - General

Locked

Views: 1,960

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
30 Aug 2010, 6:56 AM
#1
bn17311 avatar

bn17311

Zen Follower

Join Date:
Apr 2010
Posts:
319
Plugin Contributions:
0

Adding a new Product Type Info Page Layout options :: Product - General

Hi,
i want a despatch time to show in product lay out but would like to be able to switch it on and off, heres what ive done but it isnt working

in database i entered

INSERT INTO product_type_layout (configuration_id, configuration_title, configuration_key, configuration_value, configuration_description, product_type_id, sort_order, last_modified, date_added, use_function, set_function) VALUES ('','Show Despatch Time','SHOW_PRODUCT_INFO_DESPATCH','0','Display Despatch Time on Product Info 0= off 1= on',1,'','2010-04-26 17:33:15','2010-04-22 20:59:42',NULL,'zen_cfg_select_drop_down(array(array('id'=>'1', 'text'=>'True'), array('id'=>'0', 'text'=>'False')), ');

then in

/httpdocs/includes/templates/lite_red/templates/tpl_product_info_display.php

<?php echo (($flag_show_product_info_despatch == 1) ? '<li><span class="product-info-label">'. 'Despatch Time' . '</span>' . ' : 1 - 3 Working Days' . '</li>' : '') . "\n"; ?>

i can see the switch in admin but switching it on or off doesnt make a difference

i can get my message to show using the quantity switch but would prefer to do it with seperate on off

hope this makes sense
thanks
bryan

30 Aug 2010, 5:42 PM
#2
amandagero avatar

amandagero

Zen Follower

Join Date:
Feb 2009
Posts:
188
Plugin Contributions:
0

Re: Adding a new Product Type Info Page Layout options :: Product - General

try this:

<?php
  if (SHOW_PRODUCT_INFO_DESPATCH == 'true') {
?>
<li><span class="product-info-label">Despatch Time</span>: 1 - 3 Working Days</li>
<?php
  }
?>