Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

Changing product display if sale price = £0.00

Avatar of bogorman
bogorman asked on
14 Comments1 Solution824 ViewsLast Modified:
Am creating an online store for my website using Ubercart.
Basically, it all seems to work but I am stuck one one thing.
Some of the products have the sale price entered as 0.00. This is done deliberately as with these products there are a range of prices (e.g. events where there are two ticket prices - a standard one and one for students or unwaged people) so I cannot state one price when entering the product.
What I want to do is, where the sale price is normally displayed as £0.00 I want to display "click link for prices"
I have created a template file for the field concerned (views-view-field--uc-products--sell-price.tpl.php) and have changed the coding:


$data = $row->{$field->field_alias};
      $output = "Click link for prices";
/*print $data;*/
print $output;

This shows the text string "Click link for prices" for all products even those where the price is £1.00

If I comment the last line and uncomment print $data I get a null.

Can anyone help me in this?
Avatar of bogorman

Our community of experts have been thoroughly vetted for their expertise and industry experience.

This problem has been solved!
Unlock 1 Answer and 14 Comments.
See Answers