I’m sure this is a simple one for you all, but since I am so new to PHP I have to at least ask.
I am trying to setup a condition where if an attribute = ‘YES’ then show an image. The attribute name is quickships and it needs to be saying ‘YES’ in order for it to show the image, if it says anything else, I just want it to do nothing.
Bascially I tried it both of these ways…and neither is working, so not sure if its my code or if it is not recognizing the getQuickship attribute as saying YES. Is there a way to test this?
I tried this and it killed the site. This is a Magento cart and tends to be a pain in the butt with certain things. I just think maybe that attribute is not coming back as YES and the conditions arent working.
Would you happen to know what else I can try to get this thing working? Getting very frustrated over something that should be so easy to do.
Okay, getting somewhere now…This command var_dump($_product->getQuickship()); returned a NULL. So that means it for whatever reason is not seeing the attribute quickship.
I noticed I left out a ‘s’ on quickships…so now it is returning
String(1) “1”
So now by using this information how would I make this image show if this condition is meet? I tried both ways and still the image is not showing, although now I think it recognizes it.