ITEMS FOR SALE
Greetings everyone. I want to have a "ITEMS FOR SALE PAGE", is there a way to setup a query using "Price " and "List Price", so for every item whose list price is for example $20.00 over current price, then that item would be returned in the query and can be classified as an item ON SALE. I will figure it out eventually but anyhelp is appreciated!! Thanks.
|
i moved your post as the custom mods forum is for finished mods only.
The best place to start here is taking a look at the bestsellers module. You can adjust the idea behind this to fit your needs |
ON SALE PAGE COMPLETE
I said I would figure it out and I did. I will post in 5 min!!
|
ON SALE CONTINUED ...........
1) First create a file called "on_sale.php" --> customer/on_sale.php:
Code:
<? 2) The create a file called "sales_items.php" ---> customer/sales_items.php: Code:
<? PLEASE NOTE IN: "$sql_tbl[products].list_price - $sql_tbl[pricing].price > 20" THAT 20 can be any number you choose!!! 3) Now go to "skin1/customer" and create the following 3 files: - #new_sales.tpl# Code:
{capture name=dialog} - #on_sale.tpl# Code:
{* $Id: onsale.tpl,v 1.2 2003/04/24 09:50:33 svowl Exp $ *} And finally: - #sales.tpl# Code:
{* $Id: sales.tpl,v 1.3 2003/04/09 10:13:30 olga Exp $ *} Now where ever you have your main links, whether in "head.tpl" or in "rectangle_bottom.tpl" go and add your link to the on_sale.php page there!! Remember if you're using DHTML Drop down menus, you have to add you javascript code to the meta.tpl file, without "{literal} {/literal}. That's it. I will continue to post as I figure new things out. I appreciate all of the posts that everyone has made. They have helped me tremendously. I will do the same in return!! |
and back to custom mods we go :wink:
|
CORRECTION
The the query in the "sales_items.php" shoulb be:
Code:
// the database query Sorry |
How to add link?
Hello daddyroy,
I am trying out your mod, and I am not sure how to link the code to the on_sale.php file? I tried a few things and nothing has worked. Could you tell me how to link it? Thanks! :D |
LINKING ON_SALE.php
Hello how are you. You can simply add the code in the ../skin1/head.tpl like I did. Here is my modified version of head.tpl:
Code:
{* $Id: head.tpl,v 1.3 2003/04/24 09:50:33 svowl Exp $ *} OR You can add the links to .../skin1/rectangle_bottom.tpl like this. Again my modified verson of rectangle_bottom.tpl: Code:
{* $Id: rectangle_bottom.tpl,v 1.3.2.1 2003/09/17 11:52:12 svowl Exp $ *}<table border=0 cellpadding=0 cellpadding=0 width=750><tr><td width=750 valign=top><center>Home |My Account | Recover Password | Contact Us | Privacy Policy | Return Policy | F.A.Q. This works!!! :D |
The on_sale.php
Code:
$sql_tbl[products].list_price - $sql_tbl[pricing].price > 19 This > 19 could be any number you set. I just set it that any item that is $19 or more less than the list price would be considered ON SALE. |
blank page
Hello daddroy. Thanks for answering !:) . I know this will be a nice mod. I put the link in, but when I click it, the on_sale.php gives me a blank screen. I haven't been able to figure out why. One of the things I had to change was the "require" section on the on_sale.php to the following, because it couldn't find the template engine:
Quote:
The template error messages went away when I did that, but now the screen just goes blank. If you have any ideas, please let me know. Otherwise, thanks for your help and the mod info, and I will try to see what I am doing wrong. By the way, what version of xcart was this written on? |
All times are GMT -8. The time now is 06:27 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.