I followed that to find product_is_always_free_shipping in the collect_info.php file..
so that will be the line to use for the change of the product_status either a 1 or 0, right ?
I followed that to find product_is_always_free_shipping in the collect_info.php file..
so that will be the line to use for the change of the product_status either a 1 or 0, right ?
ok trying
<?php
if ($products->fields['product_is_always_free_shipping'] == '1') {
echo '<a href="' . zen_href_link(FILENAME_CATEGORIES, 'action=setflag&flag=0&pID=' . $products->fields['products_id'] . '&cPath=' . $cPath . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')) . '">' . zen_image(DIR_WS_IMAGES . 'free_shipping_set.png', IMAGE_ICON_STATUS_ON) . '</a>';
} else {
echo '<a href="' . zen_href_link(FILENAME_CATEGORIES, 'action=setflag&flag=1&pID=' . $products->fields['products_id'] . '&cPath=' . $cPath . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')) . '">' . zen_image(DIR_WS_IMAGES . 'icon_red_on.gif', IMAGE_ICON_STATUS_OFF) . '</a>';
}
?>
and in the categories I am trying :
break;
case 'setflag':
if ( ($_GET['flag'] == '0') || ($_GET['flag'] == '1') ) {
if (isset($_GET['pID'])) {
zen_set_product_status($_GET['pID'], $_GET['flag']);
}
}
break;
case 'setflag':
if ( ($_GET['flag'] == '0') || ($_GET['flag'] == '1') ) {
if (isset($_GET['pID'])) {
zen_set_product_is_always_free_shipping($_GET['pID'], $_GET['flag']);
}
}
well I got my little trucks, looks funny, as I need to find where the lable status is writen uptop and add free shipping next to it to line it up,
and when I click the truck the caegories shifts and I lose all the edit, move, attrib icons is close I think though.
Hope this is also helping anyone out there, trying to write down what I am doing, would be shorter if I was not trial and error.
messed something up as the products that are linked and have the yellow status for it, those items are showing red,green and yellow all at the same time.
ok, I put the category_product_listing.php code in the table
and cleared up the look of it, but now clicking the truck it triggering the disable product link and turning off the item from showing in the cart. so must just be a call to the wrong item,
and when clicking the truck all the other icons are gone until I start again by going to the categories from the top menu to get them back.
but now I have :
<td class="dataTableContent" width="50" align="left">
<?php
if ($products->fields['product_is_always_free_shipping'] == '1') {
echo '<a href="' . zen_href_link(FILENAME_CATEGORIES, 'action=setflag&flag=0&pID=' . $products->fields['products_id'] . '&cPath=' . $cPath . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')) . '">' . zen_image(DIR_WS_IMAGES . 'free_shipping_set.png', IMAGE_ICON_STATUS_ON) . '</a>';
} else {
echo '<a href="' . zen_href_link(FILENAME_CATEGORIES, 'action=setflag&flag=1&pID=' . $products->fields['products_id'] . '&cPath=' . $cPath . (isset($_GET['page']) ? '&page=' . $_GET['page'] : '')) . '">' . zen_image(DIR_WS_IMAGES . 'icon_red_on.gif', IMAGE_ICON_STATUS_OFF) . '</a>';
}
?>
</td>
for the header to say free shipping I search for
TABLE_HEADING_STATUS
and copied right next to it and renamed to my new
TABLE_HEADING_SHIPPING I setup in /includes/lang/english/categories.php
to look like
<td class="dataTableHeadingContent" width="50" align="center"><?php echo TABLE_HEADING_STATUS; ?></td>
<td class="dataTableHeadingContent" width="50" align="center"><?php echo TABLE_HEADING_SHIPPING; ?></td>
so under the main products page from the top menu it looks funny as a space for the new
<td class="dataTableHeadingContent" width="50" align="center"><?php echo TABLE_HEADING_STATUS; ?></td>
<td class="dataTableHeadingContent" width="50" align="center"><?php echo TABLE_HEADING_SHIPPING; ?></td>
needs to be made, but when you go under a main category the space appers there and the page looks normal.
the main products page categorie/products is missing part of the bigger table so all the icons for editing on the far right are under sort and the sort numbers are now under the new free shipping title, so just need to find WHERE to add to the table for the editing icons to shove them right and be back under the title action.
got the 1st page categories format :
in the category_product_listing.php "where most of all the editing is done" search for
<td class="dataTableContent" align="right"><?php echo $categories->fields['sort_order']; ?></td>
around line 175 and simple add the other needed colume
<td class="dataTableContent" align="right"></td>
right ABOVE the searched for line so it is in the proper place,
hint turn the table borders to 1, one at a time until you find the right table.
<td valign="top"><table border="1" width="100%" cellspacing="0" cellpadding="2">
<tr class="dataTableHeadingRow">
<?php if ($action == '') { ?>
last item is clicking the status on/off for shipping and not the product, as right now the truck icon is doing just that.
Bookmarks