Jump to content

lushlongboards

Members
  • Content count

    43
  • Joined

  • Last visited

1 Follower

Profile Information

  • Real Name
    Chris
  1. lushlongboards

    Custom Computer Creator v9 Support

    hey safoo - I'm thinking of installing this (and modding it!) for the Lush Longboards and Session1 stores but I'm wary of it after reading your warnings. Are there any similar, better contributions you have used? As you say, there is very little on this one in terms of support. I can write my own, but would rather not spend hours at it! chris
  2. lushlongboards

    [Contribution] Ultimate SEO URLs v2.0

    First up - awesome contribution and great instructions! It worked perfectly first time on my regular store (www.session1.com) . I also have a second store with a copy of the php running on a different server (www.lushatb.com) but using the same mySQL database. I get this error/warning on the second store ... is it something to do with the server being different? "Warning: gzinflate: buffer error in /includes/classes/cache.class.php on line 152" thanks! chris
  3. lushlongboards

    Dangling Carrot (Free Gift/Discount Contrib)

    thanks safoo! It seems my code is quite buggy for regular OSC stores ...
  4. lushlongboards

    Dangling Carrot (Free Gift/Discount Contrib)

    thanks for that ... I'd missed them :) lobotomia - I have not had that problem before ... can anybody else help with this? chris
  5. lushlongboards

    Dangling Carrot (Free Gift/Discount Contrib)

    don't create a new category - you can hide them (I haven't tried, but everything is possible!) but everyone uses such different menus... I have just set all my special products to inactive since they don't show up in my shop. If your "inactive" or "out of stock" products still show in your shop then you might have to work out the category thing. Yes, this is the same as I use in my shop, but I also have the bundled products module installed. (it makes no difference to the gift mod though really). all it means is that when someone buys the gift the stock level of the original product is updated.
  6. lushlongboards

    Dangling Carrot (Free Gift/Discount Contrib)

    let's call this the official thread. for discounted products, you need to copy the original product and change the price. Also change the name to say "Towel worth ?10 for just ?2" or similar. It's a bit crude, but it works. Currencies - perhaps someone can help out with this one? I haven't figured out the discounted category yet - this mod works on "copied" products rather than modifying product properties (which would ultimately be more powerful). Maybe someday, but don't hold your breath ... chris
  7. lushlongboards

    Bundled products

    when you update a bundle, the script should delete all entries from the bundles table that relate to that bundle, before writing the new contents of the javascript drop down system. what browser are you using? maybe it's a javascript thing? ... c
  8. lushlongboards

    Bundled products

    without having access to an osC with a preview step, I would say that it was def. to do it with the extra page that gets pulled up (the preview page). I reckon if you don't need preview then skip it!
  9. lushlongboards

    Bundled products

    rpain - here is one solution. The script looks at the product model on the invoice and pulls up the current bundle contents from the products database (which is the limitation since this is not necessarily the same as the bundle contents at time of order) add $bundleContents = ''; $bundle_query = tep_db_query("SELECT pb.subproduct_id, pb.subproduct_qty, p.products_id, pd.products_name, pd.language_id FROM " . TABLE_PRODUCTS . " p LEFT JOIN products_bundles pb ON (pb.bundle_id=p.products_id) LEFT JOIN " . TABLE_PRODUCTS_DESCRIPTION . " pd ON (pd.products_id=pb.subproduct_id) WHERE p.products_model = '" . $order->products[$i]['model'] . "' AND pd.language_id = '1'"); while ($bundle = tep_db_fetch_array($bundle_query)) { echo "<br> <i>" . $bundle['subproduct_qty'] . " x " . $bundle['products_name'] . "</i>"; } into invoice.php just before the closing echo ' </td>' . "\n" . after the products_name is written to the user. Here's my invoice.php that you can drop into your cart to see what it looks like. <?php /* $Id: invoice.php,v 1.6 2003/06/20 00:37:30 hpdl Exp $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2003 osCommerce Released under the GNU General Public License */ require('includes/application_top.php'); require(DIR_WS_CLASSES . 'currencies.php'); $currencies = new currencies(); $oID = tep_db_prepare_input($HTTP_GET_VARS['oID']); $orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . (int)$oID . "'"); include(DIR_WS_CLASSES . 'order.php'); $order = new order($oID); ?> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html <?php echo HTML_PARAMS; ?>> <head> <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>"> <title><?php echo TITLE; ?></title> <link rel="stylesheet" type="text/css" href="includes/stylesheet.css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF"> <!-- body_text //--> <table border="0" width="100%" cellspacing="0" cellpadding="10"> <tr> <td> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td valign="top"> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><b> Ship to:</b></td> </tr> <tr> <td class="smallText"> <?php echo "[" . $oID . "] " . tep_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br>'); ?> </td> </tr> <tr> <td class="smallText"> <?php echo $order->customer['telephone']; ?> </td> </tr> <tr> <td class="smallText"> <font color="#666666"><b><font color="#000066">From:</font> <br> Lush, Unit 30, 62 Hoyland Rd, Sheffield, S3 8AB </b></font></td> </tr> </table> </td> <td valign="top"> <table width="100%" border="0" cellspacing="0" cellpadding="2"> <tr> <td class="smallText"><b> Billing Address:</b></td> </tr> <tr> <td class="smallText"> <?php echo tep_address_format($order->customer['format_id'], $order->customer, 1, '', '<br>'); ?> </td> </tr> </table> </td> </tr> </table> </td> </tr> <tr> <td class="pageHeading"> <p> </p> <p> </p> <p><?php echo 'Order ref ' . $oID . ' , Time: ' . $order->info['date_purchased']; ?></p> </td> </tr> <tr> <td> <table border="0" cellspacing="0" cellpadding="2"> <tr> <td class="main"><b> <?php echo ENTRY_PAYMENT_METHOD; ?> </b></td> <td class="main"> <?php if ($order->info['payment_method']) { echo $order->info['payment_method']; } else { echo 'Manual or phone sale'; } ?> </td> </tr> </table> </td> </tr> <tr> <td class="main"> <?php $comments_query = tep_db_query("SELECT comments, date_added FROM " . TABLE_ORDERS_STATUS_HISTORY . " where orders_id = '" . $oID . "'"); while ($comments = tep_db_fetch_array($comments_query)) { if ($comments['comments']) { echo '<br><b>Order comments:</b><br>' . $comments['date_added'] . ' : <font color="red">' . $comments['comments'] . "</font>"; } } ?> </td> </tr> <tr> <td> <table border="0" width="100%" cellspacing="0" cellpadding="2"> <tr class="dataTableHeadingRow"> <td class="dataTableHeadingContent" colspan="2"> <?php echo TABLE_HEADING_PRODUCTS; ?> </td> <td class="dataTableHeadingContent"> <?php echo TABLE_HEADING_PRODUCTS_MODEL; ?> </td> <td class="dataTableHeadingContent" align="right"> </td> <td class="dataTableHeadingContent" align="right"> </td> <td class="dataTableHeadingContent" align="right"> <?php echo TABLE_HEADING_PRICE_INCLUDING_TAX; ?> </td> <td class="dataTableHeadingContent" align="right"> </td> <td class="dataTableHeadingContent" align="right"> <?php echo TABLE_HEADING_TOTAL_INCLUDING_TAX; ?> </td> </tr> <?php for ($i = 0, $n = sizeof($order->products); $i < $n; $i++) { echo ' <tr class="dataTableRow">' . "\n" . ' <td class="dataTableContent" valign="top" align="right">' . $order->products[$i]['qty'] . ' x</td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['name']; if (isset($order->products[$i]['attributes']) && (($k = sizeof($order->products[$i]['attributes'])) > 0)) { for ($j = 0; $j < $k; $j++) { echo '<br><nobr><small> <i> - ' . $order->products[$i]['attributes'][$j]['option'] . ': ' . $order->products[$i]['attributes'][$j]['value']; if ($order->products[$i]['attributes'][$j]['price'] != '0') echo ' (' . $order->products[$i]['attributes'][$j]['prefix'] . $currencies->format($order->products[$i]['attributes'][$j]['price'] * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . ')'; echo '</i></small></nobr>'; } } $bundleContents = ''; $bundle_query = tep_db_query("SELECT pb.subproduct_id, pb.subproduct_qty, p.products_id, pd.products_name, pd.language_id FROM " . TABLE_PRODUCTS . " p LEFT JOIN products_bundles pb ON (pb.bundle_id=p.products_id) LEFT JOIN " . TABLE_PRODUCTS_DESCRIPTION . " pd ON (pd.products_id=pb.subproduct_id) WHERE p.products_model = '" . $order->products[$i]['model'] . "' AND pd.language_id = '1'"); while ($bundle = tep_db_fetch_array($bundle_query)) { echo "<br> <i>" . $bundle['subproduct_qty'] . " x " . $bundle['products_name'] . "</i>"; } echo ' </td>' . "\n" . ' <td class="dataTableContent" valign="top">' . $order->products[$i]['model'] . '</td>' . "\n"; echo ' <td class="dataTableContent" align="right" valign="top"></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']), true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"></td>' . "\n" . ' <td class="dataTableContent" align="right" valign="top"><b>' . $currencies->format(tep_add_tax($order->products[$i]['final_price'], $order->products[$i]['tax']) * $order->products[$i]['qty'], true, $order->info['currency'], $order->info['currency_value']) . '</b></td>' . "\n"; echo ' </tr>' . "\n"; } ?> <tr> <td align="right" colspan="8"> <table border="0" cellspacing="0" cellpadding="2"> <?php for ($i = 0, $n = sizeof($order->totals); $i < $n; $i++) { echo ' <tr>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['title'] . '</td>' . "\n" . ' <td align="right" class="smallText">' . $order->totals[$i]['text'] . '</td>' . "\n" . ' </tr>' . "\n"; } ?> </table> </td> </tr> <tr> <td class="smallText" colspan="8"> <p>Thanks for your order! Don't forget you can view the status of any of your past orders online.</p> <p> </p> </td> </tr> <tr> <td class="smallText" colspan="8"> <p> <?php echo nl2br(STORE_NAME_ADDRESS); ?> </p> </td> </tr> </table> </td> </tr> </table> <!-- body_text_eof //--> <br> </body> </html> <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?> The other solution I see is adding another table to the database to hold bundle contents at order stage. The order process as it is at the moment creates so much data per order that I'd be hesitant to create more ... :) chris
  10. lushlongboards

    Bundled products

    rpain - I think it might be because I have removed the "preview" step in my admin system. I had completely forgotten that the original osC had the preview step! There's a mod somewhere that I used, and I guess that step forgets the bundle data somehow. as for more than 6 subproducts: in categories.php, find function fillCodes() { for (var n=0;n<6;n++) { and change the "6". then find all occurences of for ($i=0, $n=6; $i<$n; $i++) { and change the "6".... there are two places, one where the input fields are written to html and one where the database is written on an "update". updating stock when you delete an order? I've not worked on it yet... Chris
  11. lushlongboards

    Bundled products

    cdamianou - it looks like you have not added the extra field (products_bundle) into your products_description table. You need to do this via a database admin page. fzx5co - what version of osC are you running? safoo/aism - what's the collaborative filtering mod you're talking about? chris
  12. lushlongboards

    Bundled products

    Andreas - can you post your categories.php after you have modified it and I'll see if I can spot anything. chris
  13. lushlongboards

    Bundled products

    this looks like it could be something missed out while you are editing categories.php ... I don't have a server where I can test this mod against a clean copy of OSC, but it looks like CC has got it working fine with the instructions I wrote. chris
  14. lushlongboards

    Bundled products

    cool :) I'd be interested to see some other sites that use this mod when you have it running ... chris
  15. lushlongboards

    Bundled products

    hi costas - what part of the install is troubling you? You need to edit your version of the files given in the instructions then upload them to your server. No extra files are needed. You also need to alter your database using an admin tool that should be provided by your server, such as myPhpAdmin. chris
×