Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

EZier New Fields


nrlatsha

Recommended Posts

Post your EZier New Fields comments, suggestions and problems here. I receive lots of email on this contrib and thought it would be best to start answering publicly.

 

Get it here: http://www.oscommerce.com/community/contributions,1310

 

Basically it does this:

 

Retail Price : $ 79.99

Our Price : $ 39.99

You Save: 50%

 

I'll get around to the questions ASAP. :D

 

Noel

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

  • Replies 303
  • Created
  • Last Reply

Top Posters In This Topic

Hi, under Step 2 the installation instructions states:

 

line:262

-----------------------------------------------------------------------------------

LOOK FOR: tep_db_query("insert into " . TABLE_PRODUCTS . " (products_quantity, products_model...................

 

 

BEFORE: '" . $product['products_price'] .

ADD: '" . $product['products_retail_price'] . "',

-------------------------------------------------------------------------------------

 

Should this instead read ?

BEFORE: '" . tep_db_input($product['products_price']) . "',

ADD: '" . tep_db_input($product['products_retail_price']) . "',

 

I'm doing my first install and ran into some problems. Just want to make sure I'm doing it correctly. Thanks.

Link to comment
Share on other sites

Hi

 

Is there a quick way to do the same Discount totals for SPECIAL PRICES.

 

IE retail price= Our Special Price= You save=

 

 

I only need this on the PRODUCT INFO PAGE.

 

Thanks for your help.

Link to comment
Share on other sites

gbreynol -

line:262
-----------------------------------------------------------------------------------
LOOK FOR: tep_db_query("insert into " . TABLE_PRODUCTS . " (products_quantity, products_model...................


BEFORE: '" . $product['products_price'] .
ADD: '" . $product['products_retail_price'] . "',
-------------------------------------------------------------------------------------

Should this instead read ?
BEFORE: '" . tep_db_input($product['products_price']) . "',
ADD: '" . tep_db_input($product['products_retail_price']) . "',

 

I'm with ya, and yes, you are right, I will update the instructions, good catch.

 

 

Maz - I'm working on a new version that will work with special prices and customer discount contrib. Should be done in a couple of days, if I didn't have this damned paying job, I'd be done with it. 13 hour nite-shifts just don't allow enough time to update code.

 

Also trying to modify customer contrib so it will take discount off of special prices, this is where I'm finding the hard part...

I'll post the update here when I'm done with it.... I might just give up on the customer contrib one and just make this compat with special prices...

 

Noel

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

New version of EZier out here: http://www.oscommerce.com/community/contributions,1310

 

Change notes: 15 Apr 2004 05:00:59

(1) Updated instructions with completely new code

(2) Works with special prices now!

(3) This release will work if you do/don't have customer contrib installed. Don't need a sep mod

(4) For MS2, if you need it ported for the CVS version, lemme know and I'll post the fix here.

 

As always, questions, comments suggestions, post em here...

 

This does not modify the customer discount contrib as I stated before. Just updated for specials...

 

Noel

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

Installed the contribution and it didn't work right for me. When I updated product with a retail price and updated, it would lose my product description. Now tax is not calculated automatically when entering the net price. It lists both net and gross as 25.9500.

 

One of the instructions went like this:

line:458-461

AFTER THESE LINES: ? ? ? ? ?<tr>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?<td class="main"><?php echo TEXT_PRODUCTS_PRICE; ?></td>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?<td class="main"><?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' ' . tep_draw_input_field('products_price', $pInfo->products_price); ?></td>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ?</tr>

ADD THESE LINES: ? ? ? ? ? ? ?<tr>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?<td class="main"><?php echo TEXT_PRODUCTS_RETAIL_PRICE; ?></td>
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?	<td class="main"><?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' ' . tep_draw_input_field('products_retail_price', $pInfo->products_retail_price); ?></td>
? ? ? ? ? ? ? ? ? ? ? ? ? ?	</tr>

 

The problem I ran into here, was that I couldn't find those lines at all. The closest I could find went TEXT_PRODUCTS_PRICE_NET or TEXT_PRODUCTS_PRICE_GROSS or something along those lines.

 

I uninstalled the contrib so that I could continue adding products until a solution is found and the funny thing is in the admin section under My Store, on the bottom there is still an entry for changing decimal places for the contribution and it still doesn't calculate tax at all. Decimal is still at 4 places such as 25.9900. What could be happening? I undid all the work, uploaded original files and now I run into these problems? I'm at a loss. :(

 

Any help is greatly appreciated! :D

Edited by lostxpinoy
Link to comment
Share on other sites

New Version out there 3.3

 

http://www.oscommerce.com/community/contributions,1310

 

Change notes: 17 Apr 2004 15:35:59

 

(1) Fixed incorrect functions calls for "display_price" for those without customer discount contribution.

 

(2) Fixed inforrect input field for categories.php.

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

lostxpinoy - There shouldn't have been any mods made to the price gross field for updating tax, I'd have to take a look at your categories.php file to determine what caused that. But then again, you said you reverted to your backup files (I love those files!) and it still happened. Forgive me, but the next quesiton I'd have to ask is if you are selecting "taxable goods" under the tax class field.

 

I updated the instructions for the code snippet you placed. I have no idea how that one stayed in there. I looked at new categories.php files and found my instructions have been off since the inception of my mods to this contrib. I'm surprised nobody else found that one.

 

The part about EZier new decimal places will stay there unless you go into your dbase and kill it. This will only affect decimal places for this contribution. Is it still showing 4 decimal places on your products pages?

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

HELP PLease :) I have easy new fields installed and for some reason it only displays 1-3 numbers. eg THe price at top of teh page is correct say $2999 however ez new fields displays it as 2 or 29.... is there a simple fix for this??

Link to comment
Share on other sites

onliner - Which version of EZ do you have installed?

 

Do you have a link to see it at? Or is this just on a testing server?

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

Yup, that is the only code that needs updated, everything else stays the same.

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

Hi, Thankyou for your replies. I am still having major problems with this contribution onmy site. Very possibly i am doing something wrong so i have tried a fresh product_info page. firstly with the existing EZ new feilds contribution and i have the same error of prices above $999 showing as only 1 0r 2 digits "ie $2900 is displayed as the price next to the model on the product info page, but on the ez new feilds section it will display 2, or 29. The same problem happens in teh retail price section." i have tried to replace the code with the new product_info code from a more recent version but doesnt seem to display.. any suggestions? i can post the code if u want.

Link to comment
Share on other sites

HI, I have fixed my above problem. as yet untested and dont no what teh consequences of my change is but what i did was:changed the below code to remove the + 0.0:

 

$list_price = substr(($currencies->display_price($product_info['products_retail_price'], tep_get_tax_rate($product_info['products_tax_class_id']))),1) ;

** $list_price =$list_price + 0.0; //REMOVED +0.0

$our_price = substr(($currencies->display_price($product_info['products_price'], tep_get_tax_rate($product_info['products_tax_class_id']))),1);

** $our_price = $our_price + 0.0; //REMOVED +0.0

$savings_a = (($our_price / $list_price) * 100);

$savings = (100 - $savings_a);

$savings = round($savings);

Link to comment
Share on other sites

Do you have a copy of the code you were originally using? The entire part from the popup function to the stripslash function.

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

Hi, Thankyou for your replies. I am still having major problems with this contribution onmy site. Very possibly i am doing something wrong so i have tried a fresh product_info page. firstly with the existing EZ new feilds contribution and i have the same error of prices above $999 showing as only 1 0r 2 digits "ie $2900 is displayed as the price next to the model on the product info page, but on the ez new feilds section it will display 2, or 29. The same problem happens in teh retail price section." i have tried to replace the code with the new product_info code from a more recent version but doesnt seem to display.. any suggestions? i can post the code if u want.

I have the same problem on MS1

with EZ v. 2.1

Link to comment
Share on other sites

My version of the contrib tested with MS2.

 

This is starting to sound like a problem with MS1...

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

search catalog/includes/application_top.php for PROJECT and post the results of that search here please. will help on knowing what version you are discussing.

Link to comment
Share on other sites

HI, I have fixed my above problem. as yet untested and dont no what teh consequences of my change is but what i did was:changed the below code to remove the + 0.0:

It works!

but I don't know whether it perform some errors in other situations

Link to comment
Share on other sites

It works! 

but I don't know whether it  perform some errors in other situations

$655.00

Retail Price: $1,040.00

You Save: $-65400%

 

:(

the problem is with

($our_price / $list_price)

when

$our_price = $our_price ;

$list_price = $list_price ;

 

655.00 / 1,040.00 = 655

 

 

when

$our_price = $our_price + 0.0;

$list_price = $list_price + 0.0;

 

655 / 1 = 655

Link to comment
Share on other sites

It calculates it like this:

 

List: $1000

Our: $555

 

100 - ((our / list) * 100)

 

100 - (555 / 1000 ) * 100)

100 - (.55 * 100)

100 - 55

44.5

round(44.5)

45

 

Savings: 45%

 

I don't understand where your errors are coming from.

 

iberua & onliner - if this is a problem because you have MS1, please let me know. I don't want to confuse anybody that is using MS2.

 

This contrib is only for MS2 and I will port it to CVS, but no one has asked this to be ported to MS1. I wouldn't understand why anyone is still using MS1, but everyone has their own reasons.

 

So. Are you guys using MS1? If so, could you please start PMing each other for this issue. I don't want anybody confusing this as a poorly written contrib when its not supported/tested for your version.

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

I am getting an error message

 

Fatal error: Call to undefined function: display_price_nodiscount() in /home/adoole2/public_html/osc/product_info.php on line 121

 

 

where is this method?

 

I don't have any other contribution installed, do I need any other contribution?

Link to comment
Share on other sites

benjamine_df - That is correct, nothing broke, I missed a function in the install readme, instructions updated.

9 times out of 10 its a PEBCAK Error (Problem exists between chair and keyboard)

 

Replace that and you're fine...

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...