this are the links and they do work
http://opticlubusa.com/index.php?mai...&products_id=5
http://opticlubusa.com/index.php?mai...&products_id=4
Can I see your page? maybe I can help you!
this are the links and they do work
http://opticlubusa.com/index.php?mai...&products_id=5
http://opticlubusa.com/index.php?mai...&products_id=4
Can I see your page? maybe I can help you!
Thanks for offering to have a look.
My site is http://www.designerspecsbypost.co.uk/
and the designer sunglasses without attributes runs well, but the designer frames takes ages too change between the frames due to the numerous attributes.
I have set another site up as a practice site to try out updates and do changes as I have changed things in the past and numerous times I have had the site crash. This is on http://www.cheapspecsbypost.co.uk/ I have changed the files on this site to the ones you posted, but they have had no effect so I am sure there are lots of things I need to change.
Will
This is my tpl_modules_attributes_2.php
save this in includes\templates\CUSTOM\templates\tpl_modules_attributes_2.phpPHP Code:<?php
/**
* Module Template
*
* Template used to render attribute display/input fields
*
* @package templateSystem
* @copyright Copyright 2003-2005 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: tpl_modules_attributes.php 3208 2006-03-19 16:48:57Z birdbrain $
*/
?>
<div id="productAttributes">
<div class="wrapperAttribsOptions">
<table width="100%" cellpadding="0" cellspacing="0" style="border: 1px solid #003399;">
<tr><td><table width="100%" border="0" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td colspan="8" class="leftBoxHeading" id="categoriesHeading2"><strong>Please enter your Rx Information Here</strong> </td>
</tr>
<tr>
<td></td>
<td><strong> + / - </strong></td>
<td><strong>Sphere</strong></td>
<td><strong> + / - </strong></td>
<td><span class="main"><b>Cylinder</b></span></td>
<td><span class="main"><strong>Axis</strong></span></td>
<td><span class="main"><b>Prism</b></span></td>
<td><span class="main"><b>Add</b></span></td>
</tr>
<tr>
<td><div align="left"> O.D:</div></td>
<td><?php echo "\n" . $options_menu[0]; ?></td>
<td><?php echo "\n" . $options_menu[1]; ?> </td>
<td><?php echo "\n" . $options_menu[2]; ?> </td>
<td><?php echo "\n" . $options_menu[3]; ?></td>
<td><?php echo "\n" . $options_menu[4]; ?></td>
<td><?php echo "\n" . $options_menu[5]; ?></td>
<td><?php echo "\n" . $options_menu[6]; ?></td>
</tr>
<tr>
<td><div align="left"> O.S:</div></td>
<td><?php echo "\n" . $options_menu[7]; ?></td>
<td><?php echo "\n" . $options_menu[8]; ?></td>
<td><?php echo "\n" . $options_menu[9]; ?></td>
<td><?php echo "\n" . $options_menu[10]; ?></td>
<td><?php echo "\n" . $options_menu[11]; ?></td>
<td><?php echo "\n" . $options_menu[12]; ?></td>
<td><?php echo "\n" . $options_menu[13]; ?></td>
</tr>
<tr>
<td colspan="2"><?php echo $options_name[14]; ?></td>
<td colspan="6"><?php echo "\n" . $options_menu[14]; ?></td>
</tr>
</table>
</td>
</tr>
<tr>
<td><table width="100%" border="0" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td colspan="4" class="leftBoxHeading" id="categoriesHeading"><strong>Please enter Patient and Doctor's Information Here</strong> </td>
</tr>
<tr>
<td><?php echo $options_name[15]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[15]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[16]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[16]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[17]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[17]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[18]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[18]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[19]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[19]; ?></td>
</tr>
<tr>
<td colspan="4" class="leftBoxHeading" id="categoriesHeading"><strong>Please Choose your Prescription Treatment</strong></td>
</tr>
<tr>
<td><?php echo $options_name[20]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[20]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[21]; ?></td>
<td><?php echo "\n" . $options_menu[21]; ?></td>
<td><?php echo $options_name[22]; ?></td>
<td><?php echo "\n" . $options_menu[22]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[23]; ?></td>
<td><?php echo "\n" . $options_menu[23]; ?></td>
<td><?php echo $options_name[24]; ?></td>
<td><?php echo "\n" . $options_menu[24]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[25]; ?></td>
<td><?php echo "\n" . $options_menu[25]; ?></td>
<td colspan="2"> </td>
</tr>
</table></td>
</tr>
</table>
</div>
</div>
In the Admin section, look for the Category ID # and sub cat
Use this Categry and sub cat ID# to replace te "1"
if($current_category_id=="1")
in My case 1, 12,13,14 for contact lenses
and 2, 5, 6, 7, 8 for prescription lenses
Use this code in your tpl_product info display.php
PHP Code:<!--bof Attributes Module -->
<?php if ($pr_attr->fields['total'] > 0) { ?>
<?php /*** display the product atributes***/
if($current_category_id=="1")
require($template->get_template_dir('/tpl_modules_attributes_1.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_1.php');
if($current_category_id=="12")
require($template->get_template_dir('/tpl_modules_attributes_1.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_1.php');
if($current_category_id=="2")
require($template->get_template_dir('/tpl_modules_attributes_2.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_2.php');
if($current_category_id=="5")
require($template->get_template_dir('/tpl_modules_attributes_2.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_2.php');
if($current_category_id=="6")
require($template->get_template_dir('/tpl_modules_attributes_2.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_2.php');
if($current_category_id=="7")
require($template->get_template_dir('/tpl_modules_attributes_2.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_2.php');
if($current_category_id=="8")
require($template->get_template_dir('/tpl_modules_attributes_2.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_attributes_2.php');
?>
<?php } ?>
<!--eof Attributes Module -->
That help has been fantastic. As you can see from
http://www.cheapspecsbypost.co.uk/in...&products_id=4
I have cobbled things together. Very much by luck and a little understanding.
How do I manage to get the other lens options from the designerspecsbypost.co.uk site onto your format, also do you know how I can get the box to stay in the main area as it is overrunning to the right. I use firefox as my browser, but I think IE does it aswell. Is it just I have to be careful of the size of the boxes for each attribute.
Will
I am also working on a custom attribute page for 1 item. I am working on a page to do pizza toppings. How can I split the $options_menu array so the choices are side by side instead of under each other? I also do not want the description of the option. Something that looks similar to this.
Thanks
Steve
Hi Eye Will,
I see that we are in the same business, :)
1. -- In your admin area change the sort order in your attributes names
use the ones that i give you here
1 - I require
2 - Lens Options
3 - Tint Options
4 - Coating Options
5 - Right Sphere
6 - Right Cylinder
7 - Right Axis
8 - Right Reading Add
9 - Left Sphere
10 - Left Cylinder
11 -Left Axis
12 - Left Reading Add
13 - Pupillary Distance
2. -- Use this php as your tpl_modules_attributes...
After this I hope you are runningPHP Code:<?php
/**
* Module Template
*
* Template used to render attribute display/input fields
*
* @package templateSystem
* @copyright Copyright 2003-2005 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: tpl_modules_attributes.php 3208 2006-03-19 16:48:57Z birdbrain $
*/
?>
<div id="productAttributes">
<div class="wrapperAttribsOptions">
<table width="100%" cellpadding="0" cellspacing="0" style="border: 1px solid #003399;">
<tr><td> </td>
</tr>
<tr>
<td><table width="100%" border="0" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td colspan="4" class="leftBoxHeading" id="categoriesHeading"><strong>Please Choose your Prescription Treatment</strong></td>
</tr>
<tr>
<td><?php echo $options_name[0]; ?></td>
<td colspan="3"><?php echo "\n" . $options_menu[0]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[1]; ?></td>
<td><?php echo "\n" . $options_menu[1]; ?></td>
<td><?php echo $options_name[2]; ?></td>
<td><?php echo "\n" . $options_menu[2]; ?></td>
</tr>
<tr>
<td><?php echo $options_name[3]; ?></td>
<td><?php echo "\n" . $options_menu[3]; ?></td>
<td> </td>
<td> </td>
</tr>
<tr>
<td colspan="4"><table width="100%" border="0" cellpadding="5" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td colspan="8" class="leftBoxHeading" id="categoriesHeading2"><strong>Please enter your Rx Information Here</strong> </td>
</tr>
<tr>
<td></td>
<td> </td>
<td><strong>Sphere</strong></td>
<td> </td>
<td><span class="main"><b>Cylinder</b></span></td>
<td><span class="main"><strong>Axis</strong></span></td>
<td><span class="main"><b>Add</b></span></td>
<td> </td>
</tr>
<tr>
<td><div align="left"> O.D:</div></td>
<td> </td>
<td><?php echo "\n" . $options_menu[4]; ?> </td>
<td> </td>
<td><?php echo "\n" . $options_menu[5]; ?></td>
<td><?php echo "\n" . $options_menu[6]; ?></td>
<td><?php echo "\n" . $options_menu[7]; ?></td>
<td> </td>
</tr>
<tr>
<td><div align="left"> O.S:</div></td>
<td> </td>
<td><?php echo "\n" . $options_menu[9]; ?></td>
<td> </td>
<td><?php echo "\n" . $options_menu[10]; ?></td>
<td><?php echo "\n" . $options_menu[11]; ?></td>
<td><?php echo "\n" . $options_menu[12]; ?></td>
<td> </td>
</tr>
<tr>
<td colspan="2"><?php echo $options_name[13]; ?></td>
<td colspan="6"><?php echo "\n" . $options_menu[13]; ?></td>
</tr>
</table> </td>
</tr>
</table></td>
</tr>
</table>
</div>
</div>
Miri4413