Zen Cart Logo
Forums / All Other Contributions/Addons / Dynamic Price Updater

Dynamic Price Updater

Views: 342,231

Results 181 to 200 of 1,701
25 Jun 2008, 22:32
#181
stevenlee avatar

stevenlee

New Zenner

Join Date:
Jun 2008
Posts:
85
Plugin Contributions:
0

Dynamic Price Updater

actually the code to have the price and the add to cart button float on the top right is

<DIV style="position: fixed; top: 56px; right: 30px; width: 240px; height: 40px;" id=cartAdd><H2 class=productGeneral id=productPrices>Starting at: $281.00</H2>Add to Cart: <INPUT maxLength=6 size=4 value=1 
      name=cart_quantity><BR><BR><INPUT type=hidden value=180 
      name=products_id><INPUT title=" Add to Cart " type=image alt="Add to Cart" 
      src="HOPC1 [HOPC1] - $281_00  OZM Systems, Powerful Custom Computers_files/button_in_cart.gif"> 
      </DIV>

but again this is only works when I save the product page and add this code

obviously I need it to be done by the cart but I'm not sure what code to edit
I know the site is compiled from a bunch of files, I just need to find the file that calls for the div id=cartadd on the product detail page I think

any help would be greatly appreciated

25 Jun 2008, 23:11
#182
stevenlee avatar

stevenlee

New Zenner

Join Date:
Jun 2008
Posts:
85
Plugin Contributions:
0

Re: Dynamic Price Updater

ok, figured it out

you need to open the file tpl_product_info_display.php which is located in \includes\templates\template_default\templates

before the <!--bof Product Price block -->

I added

<div style="position: fixed; top: 56px; right: 30px; width: 240px; height: 40px;">

and a closing div tag after <!--eof Product Price block -->

also I edited the div id="cartAdd" to

<div style="position: fixed; top: 76px; right: 30px; width: 240px; height: 40px;" id="cartAdd">

(the closing div is already there)

then save it and upload it, the look of the box is a thin black line which I will try and also get the price breakdown to display too

WOW Zen Cart Rocks, together we can do anything with it

25 Jun 2008, 23:16
#183
stevenlee avatar

stevenlee

New Zenner

Join Date:
Jun 2008
Posts:
85
Plugin Contributions:
0

Re: Dynamic Price Updater

argh... only works on firefox...I will have to find out how to position it correctly in IE:oops:

26 Jun 2008, 13:18
#184
blackjm75 avatar

blackjm75

New Zenner

Join Date:
May 2008
Posts:
20
Plugin Contributions:
0

Re: Dynamic Price Updater

Chrome,

Hows the new version coming along? I want to install this but I dont want to do it if there the new version coming soon. Also have you got it to work with quantity discounts?

Joe

26 Jun 2008, 22:11
#185
momokui avatar

momokui

New Zenner

Join Date:
Jan 2007
Posts:
32
Plugin Contributions:
0

Re: Dynamic Price Updater

When the option type is RADIO and the value 0 is selected, the price doesn't change back to previous amount.

i.e:

Price: $100
option 1: +0
option 2: +100

option 1 selected -> price $100
option 2 selected -> price $200
option 1 reselected (option 2 automatically unselected) -> price stays at $200, doesn't go back to $100.

Any idea how to work around this issue?

Thanks

27 Jun 2008, 05:33
#186
stevenlee avatar

stevenlee

New Zenner

Join Date:
Jun 2008
Posts:
85
Plugin Contributions:
0

Re: Dynamic Price Updater

you can use checkboxes to get around the price adjustment issue

the code for positioning I posted works in IE7+, FF, Opera and others

I'm still working on getting the code to place the information in a decent spot on IE6

I figured out how to put the price breakdown on the side so it scrolls with the page too (you will need to turn it off in the admin under tools layout box controller)

insert this code anywhere, end of the page is fine

<div style="position: fixed; top: 426px; right: 30px; width: 200px; height: 30px;"; align="center"> 
<!--// bof: priceupdatersidebox //-->

<div class="rightBoxContainer" id="priceupdatersidebox" style="width: 150px">
<h3 class="rightBoxHeading" id="priceupdatersideboxHeading">Price Breakdown</h3>
<div id="priceupdatersideboxContent" class="sideBoxContent"></div></div>
<!--// eof: priceupdatersidebox //-->
</div>

add a div tag before the <!--bof Product Price block --> and a closing div tag like so

<div style="position: fixed; top: 266px; right: 30px; width: 200px; height: 30px;"; align="center">
<!--bof Product Price block -->
<h2 id="productPrices" class="productGeneral">
<?php
// base price
  if ($show_onetime_charges_description == 'true') {
    $one_time = '<span >' . TEXT_ONETIME_CHARGE_SYMBOL . TEXT_ONETIME_CHARGE_DESCRIPTION . '</span><br />';
  } else {
    $one_time = '';
  }
  echo $one_time . ((zen_has_product_attributes_values((int)$_GET['products_id']) and $flag_show_product_info_starting_at == 1) ? TEXT_BASE_PRICE : '') . zen_get_products_display_price((int)$_GET['products_id']);
?></h2>
<!--eof Product Price block -->
</div>

style the div id="cartAdd" like so

<div style="position: fixed; top: 306px; right: 60px; width: 100px; height: 40px; background-color:#81c481" id="cartAdd" align="center">
    <?php
      echo $display_qty;
      echo $display_button;
            ?>
			  </div>

This will display the price, add this to my cart button and the price breakdown
This doesn't work on IE6 and below, I'm still working on a viable workaround for IE6 not supporting fixed positioning

27 Jul 2008, 21:46
#187
nick_h avatar

nick_h

New Zenner

Join Date:
Apr 2008
Location:
Nottingham, UK
Posts:
46
Plugin Contributions:
0

Re: Dynamic Price Updater

Excellent contribution, thanks :)

27 Jul 2008, 23:53
#188
jill8026 avatar

jill8026

Totally Zenned

Join Date:
May 2007
Posts:
461
Plugin Contributions:
0

Re: Dynamic Price Updater

Thank you so much for this great mod! The only thing I cannot get to work is my Radio Button choice. For example:

http://www.ilovephotogifts.com/index.php?main_page=product_info&cPath=65_48&products_id=131

I have it set to option 4 where the element is below image and option name--this will not work with the price updater...neither does option 5, but 0-3 work fine?!?!!?

I just read this whole thread but have not been able to find anything relevant to this issue?

05 Aug 2008, 21:58
#189
jynkz avatar

jynkz

New Zenner

Join Date:
Aug 2008
Posts:
1
Plugin Contributions:
0

Re: Dynamic Price Updater

same problem with "Momokui"
Issue of Price Updater. if i select price by attribute in product entry.

Price: $100
option 1: +0
option 2: +100

option 1 selected -> price $100
option 2 selected -> price $200
option 1 reselected (option 2 automatically unselected) -> price stays at $200, doesn't go back to $100.

please help... thanks :smile:

                                                                                  JYNKZ™
21 Aug 2008, 19:13
#190
terpsnation avatar

terpsnation

New Zenner

Join Date:
Jun 2008
Posts:
34
Plugin Contributions:
0

Re: Dynamic Price Updater

For some reason I seem to be getting a (1) around the price of the product when an attribute is selected. I'm using radio buttons, and the price scales up and down correctly depending on which attribute I choose, yet the (1) still stays at the top of the page next to the price.

I've looked through this thread a few times trying to get everything figured out, but can't find a solution to this problem. Anyone able to help me out? :)

Thanks,

Terps

21 Aug 2008, 20:09
#191
terpsnation avatar

terpsnation

New Zenner

Join Date:
Jun 2008
Posts:
34
Plugin Contributions:
0

Re: Dynamic Price Updater

EDIT: Nevermind this post. Still getting (1) next to the price.

22 Aug 2008, 04:26
#192
lankeeyankee avatar

lankeeyankee

Totally Zenned

Join Date:
Jan 2007
Posts:
1,514
Plugin Contributions:
1

Re: Dynamic Price Updater

The (1) is the quantity, change the quantity and the number will change and show the correct price for that quantity of items. If you don't want that to display go to the jscript_updater.php file and around line 17 change this:
var showQuantity = true;
to
var showQuantity = false;

23 Aug 2008, 16:57
#193
terpsnation avatar

terpsnation

New Zenner

Join Date:
Jun 2008
Posts:
34
Plugin Contributions:
0

Re: Dynamic Price Updater

Thank you lankee. Works perfectly :)

26 Aug 2008, 07:15
#194
stevenlee avatar

stevenlee

New Zenner

Join Date:
Jun 2008
Posts:
85
Plugin Contributions:
0

Re: Dynamic Price Updater

jynkz:

same problem with "Momokui"
Issue of Price Updater. if i select price by attribute in product entry.

Price: $100
option 1: +0
option 2: +100

option 1 selected -> price $100
option 2 selected -> price $200
option 1 reselected (option 2 automatically unselected) -> price stays at $200, doesn't go back to $100.

please help... thanks :smile:

                                                                                  JYNKZ™

for the option you want to show as 0 input .001 as the price, it will show as 0, that way if someone picks an option and then wants to take it off they can, (also drop down menus work, but they will display first in the pricebreakdown, if you are using all dropdowns this isn't a problem)

29 Aug 2008, 17:48
#195
momokui avatar

momokui

New Zenner

Join Date:
Jan 2007
Posts:
32
Plugin Contributions:
0

Re: Dynamic Price Updater

stevenlee:

for the option you want to show as 0 input .001 as the price, it will show as 0, that way if someone picks an option and then wants to take it off they can, (also drop down menus work, but they will display first in the pricebreakdown, if you are using all dropdowns this isn't a problem)

Didn't work, maybe I did wrong, would you please explain more detail. Thanks

29 Aug 2008, 18:02
#196
momokui avatar

momokui

New Zenner

Join Date:
Jan 2007
Posts:
32
Plugin Contributions:
0

Re: Dynamic Price Updater

I forgot to mention that drop down menus is not an option in my case, because it always shows the price different, unless you can tell me how to hide that price different.
drop down menu: $123 (+100) -> only shows $123

Thanks.

03 Sep 2008, 20:22
#197
elaforet avatar

elaforet

New Zenner

Join Date:
Jan 2007
Posts:
6
Plugin Contributions:
0

Re: Dynamic Price Updater

Hi all

I tried to use the Dynamic Price Updater but I don t understand anything.

I installled the jscript_updater.php file in the includes/modules/pages/product_info/ folder.

But that does not work !! When I change attributes to an object, the price is not updated.

Can anyone explain me how to set it up ?

Thanks !!

21 Sep 2008, 18:08
#198
shepherd348 avatar

shepherd348

New Zenner

Join Date:
Mar 2008
Location:
Florida
Posts:
30
Plugin Contributions:
0

Re: Dynamic Price Updater

Guess I'm jumping into the end of the fray, but I just came into the issue because of the company I did the install for now has their shorts in a knot because they feel ( and I agree) that it is confusing for the customer to see a drop-down menu that gives information on a product and lists the price as +1.86, which they are supposed to add to the original $3.29.

The simplest solution to me seems to alter the data that is being displayed in the drop-down menu, and not that which deals with the price of the product as it is in the payment structure. What is confusing to the customer is the price that is displayed (+$1.86). Wouldn't it be a simple fix to change the formula that says: display the amount of increase/decrease to: display the amount of increase/decrease + the original price, and let the rest of the calculations stand as is?

Thanks. Shepherd

01 Oct 2008, 05:42
#199
terpsnation avatar

terpsnation

New Zenner

Join Date:
Jun 2008
Posts:
34
Plugin Contributions:
0

Re: Dynamic Price Updater

I've been using this addon on my website for a while now and its been working excellently. But I've recently ran into a problem...

I need a product to be priced by attributes (with some attributes set to be selected on default), but when I set it to this and I load the product page, the price updater makes the total price = the priced by attributes price + the price of the attributes selected.

This makes the dynamic price 2x what the price is when you add the item to your cart. Is there any way around this?

03 Oct 2008, 12:59
#200
chrome avatar

chrome

Zen Follower

Join Date:
Jul 2005
Location:
Wales, UK
Posts:
392
Plugin Contributions:
0

Re: Dynamic Price Updater

Hi all

I've been away for ages and I'm sorry for that... Things have been, er, odd to say the least

I'll reply in a largely random order :smile:

terpsnation: there is a post on this thread about how to fix this issue... Essentially the fix is to get the display price for a single unit to 0... Unfortunately I can't remember how exactly the fix works... Have a trawl through the previous posts to see if you can find it... If not shout back and I'll see what i can do :smile:

Shepherd348: In theory adjusting the display of the attribute values to match the selected attributes is a great idea... In fact someone suggested it just the other day... At the moment, with the current incarnation of the Updater, I think it will cause issues when the attributes are 'read' to be adjusted... This is something I'm looking into

I've only had a chance to quickly skim the latest posts on the thread so if I've missed anyone please let me know

I know I've said this before but I'm restarting development on the Updater (I haven't worked on ZC for a number of months and need time to get back into it)... I'll try to keep regular updates and post files for those daring enough to test

Thanks to everyone for the support and, I hope, patience :smile:

Cheers

Dan