dharrison:
Just the featured products box in the center column. I'm not using the other ones.
I just would like to move it so it displays before the main page content.
I have tried with the code offline, but no go. I have basic PHP skills if that helps, but I can follow patterns (monkey see, monkey do).
I've been doing the same thing for years and it's the only way to learn this stuff in my not so expert opinion.
bn - you're almost there. See the line above the call for the featured products?
<?php
$show_display_category = $db->Execute(SQL_SHOW_PRODUCT_INFO_MAIN);
while (!$show_display_category->EOF) {
?>
That's what tells the template to check if the featured products needs to be shown. If you only move the call for the featured products, the template won't know to check for it and it won't work. In your case Debbie, it would be easiest to just move the whole block of code (as shown below) to the place on the template that you want it.
<?php
$show_display_category = $db->Execute(SQL_SHOW_PRODUCT_INFO_MAIN);
while (!$show_display_category->EOF) {
?>
<?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_FEATURED_PRODUCTS') { ?>
<?php
/**
* display the Featured Products Center Box
*/
?>
<?php require($template->get_template_dir('tpl_modules_featured_products.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_featured_products.php'); ?>
<?php } ?>
<?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_SPECIALS_PRODUCTS') { ?>
<?php
/**
* display the Special Products Center Box
*/
?>
<?php require($template->get_template_dir('tpl_modules_specials_default.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_specials_default.php'); ?>
<?php } ?>
<?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_NEW_PRODUCTS') { ?>
<?php
/**
* display the New Products Center Box
*/
?>
<?php require($template->get_template_dir('tpl_modules_whats_new.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_whats_new.php'); ?>
<?php } ?>
<?php if ($show_display_category->fields['configuration_key'] == 'SHOW_PRODUCT_INFO_MAIN_UPCOMING') { ?>
<?php
/**
* display the Upcoming Products Center Box
*/
?>
<?php include(DIR_WS_MODULES . zen_get_module_directory(FILENAME_UPCOMING_PRODUCTS)); ?><?php } ?>
<?php
$show_display_category->MoveNext();
} // !EOF
?>
I hope that makes sense - I've got a holiday happy kid yapping in my ear nonstop and am finding it difficult to concentrate. :frusty: If it doesn't, please let me know and I'll try to clarify.