PDA

View Full Version : price always 0??


neoteric
5-26-04, 05:51 PM
Hi

I have been stripping out bits of oscommerce to create a Search facility for a customer and have it almost working as he requested, but somewhere along the way I have screwed something up. The price appears as 0 no matter what I set the price as in the admin page. I have tried every setting I can find in admin, but fear I may have messed up the coding somewhere. Can anyone give me any clues as to which files I should be looking at to sort this?

Thanks

stevel
5-26-04, 08:16 PM
The price comes from the database. There's no way we can guess what you may have changed to prevent it from showing, though in general if the PHP is referencing an undefined variable, it can display as zero.

neoteric
5-27-04, 03:48 AM
Thanks heaps.

Got another wee problem. Customer wants a mailto: link on the products page but this email address varies depending on the product. I was intending to use the website link but it automatically puts http:// in front of everything. Where do I find the code to change this to mailto: instead of http://

Cheers.

stevel
5-27-04, 08:57 AM
Just do it yourself, like this:


<a href=<?php echo '"mailto:product" . $HTTP_GET_VARS['products_id'] . '@example.com"' ?> >Mail us</a>


This has to go in the code of product_info.php, not in the text of the product description in the database.