Re: Dynamic Price Updater
Get well soon chrome :smile:
Please can someone help me with this little problem. I don't know PHP very well at all but I've tried my best.
I'm using DPUv2 which is working great BTW! The problem is I have replaced the code from "<!--bof Add to Cart Box -->" to "<!--eof Add to Cart Box -->" in my "tpl_product_info_display.php" with this code that I got from another thread:
Code:
<!--bof Add to Cart Box -->
<?php
if (CUSTOMERS_APPROVAL == 3 and TEXT_LOGIN_FOR_PRICE_BUTTON_REPLACE_SHOWROOM == '') {
// do nothing
} else {
?>
<?php
$display_qty = (($flag_show_product_info_in_cart_qty == 1 and $_SESSION['cart']->in_cart($_GET['products_id'])) ? '<p>' . PRODUCTS_ORDER_QTY_TEXT_IN_CART . $_SESSION['cart']->get_quantity($_GET['products_id']) . '</p>' : '');
if ($products_qty_box_status == 0 or $products_quantity_order_max== 1) {
// hide the quantity box and default to 1
$the_button = '<input type="hidden" name="cart_quantity" value="1" />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
} else {
// show the quantity box
$the_button = PRODUCTS_ORDER_QTY_TEXT . '<input type="text" name="cart_quantity" value="' . (zen_get_buy_now_qty($_GET['products_id'])) . '" maxlength="6" size="4" /><br />' . zen_get_products_quantity_min_units_display((int)$_GET['products_id']) . '<br />' . zen_draw_hidden_field('products_id', (int)$_GET['products_id']) . zen_image_submit(BUTTON_IMAGE_IN_CART, BUTTON_IN_CART_ALT);
}
$display_button = zen_get_buy_now_button($_GET['products_id'], $the_button);
?>
<?php if ($display_qty != '' or $display_button != '') { ?>
<?php
echo $display_qty;
?>
<div id="cartAdd" style="display:none;"> Wait ..... images are uploading ......<br>
This can take several minutes .... Please wait ...<br> <img border="0" src="/includes/templates/pc020/images/progress.gif" width="350" height="50"> </div><a href="javascript:ShowDiv()"></a> <div onclick="ShowDiv()">
<center><br>
<?
if ($pr_attr->fields['total'] > 0 && (!$_SESSION['customer_id'])) {
echo '<a href=index.php?main_page=login><b><font size="3" color="red">IMPORTANT:<br>You have to login before order this item<br>
--- Log in here ---</a></font></b>';
} else {
echo $display_button;
}
?>
</div>
</div>
<script language="javascript">
function ShowDiv()
{
document.getElementById("cartAdd").style.display = '';
}
</script>
<?php } // display qty and button ?>
<?php } // CUSTOMERS_APPROVAL == 3 ?>
<!--eof Add to Cart Box-->
What it does is hides the add to cart function until the user logs in. I want this in order to prevent the user uploading files without logging in.
The problem, this has caused with DPU is that the price is displayed as 0 until the user logs in. I would like the user to be able to see the prices whether logged in or not.
I'm not very good at PHP but have played around to try and get the price to display with no luck. Does anyone have any idea if I could make this work.
Any help very much appreciated!!!
Re: Dynamic Price Updater
Hi all,
just a question, do someone menage DPU to work with Dual pricing mod?
The thing i'm looking for is the showing of the two different prices in the product_info page.
With Dual pricing if you are logged and you are a wholesaler you will see 2 prices Retail and Wholesale.
After installing DPU when you load the product page the prices will show for a sec and after the "Wholesale price" and "retail price" will disappear leaving only "price" which will show the correct price by the way. It should be a java issue maybe, if someone solved it please just tell me how :-)
Re: Dynamic Price Updater
Hi all
gl3ny: Sorry, the Updater uses the cart to derive its prices. If the cart says that someone has to be logged in then I'm afraid it has to be so
izar74: Again, sorry, at the minute at least the Updater doesn't support dual-pricing
These are all things that are on the backburner as I tackle some issues with other parts of the mod
Apologies for the huge delays involved here; it just seems to be the way my life is going currently :laugh:
Dan
Re: Dynamic Price Updater
For Products with Specials/Sales I cheated ... :cool:
I have the normal price display also shown when there is a special or sale ... and then I have the 2 magic prices that work based on the quantity ...
Re: Dynamic Price Updater
Can this module be applied to certain categories only? I have wholesale and retail pricing but store owner does not want the retail price of a certain category not show up. When I removed the retail price, the dynamic Price Updater stopped working in this area due to the item store owner not wanting to show is the lowest price of the sizes offered.
Is there a work around for this to show the next price in line?
BTW...I love this module, looks great on sites.
Thanks!
Re: Dynamic Price Updater
Quote:
Originally Posted by
Ajeh
For Products with Specials/Sales I cheated ... :cool:
I have the normal price display also shown when there is a special or sale ... and then I have the 2 magic prices that work based on the quantity ...
How did you go around this linda? I know on the category page it would display the slashed out pricingas well but once you go into the detailed page the DPU goes to work. I was thinking about hardcoding the reg price with a slash out but if you have a cheat....hook me up! :D
also off topic here would you please take a look at this
http://www.zen-cart.com/forum/showth...726#post824726
thanks !!!!
Re: Dynamic Price Updater
The display is manage by the class in the template ... so I made the one at the top use a different class so the price did not change and put one at the bottom where the add to cart quantity is put in that had the class that gets changed ...
This way, the original price always shows on the page and the changing price of what the "actual" price will be based on quantity etc. would show right where the customer is working down by the attributes and add to cart quantity box ...
Re: Dynamic Price Updater
Hi all,
Im still struggling on removing the ( X ) at the end of the price:
http://www.realfairtrade.com/set-of-...lates-490.html
Where 'Your Price' is and the price Im fine with but those brackets look unprofessional. Does anyone else have this issue, or has someone solved it?
Thanks
Steve
Re: Dynamic Price Updater
Hi stiggy
If you open up dpu_ajax.php in an editor you should see this line:
Code:
define('DPU_SHOW_QUANTITY', true);
Change this to
Code:
define('DPU_SHOW_QUANTITY', false);
That should sort your problem :smile:
Dan
Re: Dynamic Price Updater
Hey Dan, did you ever get an update out to fix the mod. Still dont work for me.