Post by The Alchemist » Tue Oct 19, 2010 9:21 pm

Q, I am using your shipping per item mod and Im trying to add in the shipping field for this. When I enter in the coding above, it comes up fine, but instead of shipping actually being the 20 dollars it should be or whatever it is, it comes up as "1" for everything.

User avatar
Active Member

Posts

Joined
Sun Nov 22, 2009 11:04 am

Post by Qphoria » Thu Oct 21, 2010 10:02 pm

just add

Code: Select all

<?php echo $this->currency->format($product_info['shipping_by_product']); ?>

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by The Alchemist » Thu Oct 21, 2010 10:42 pm

Curious. I got errors using that. Where does that code go. Into the catalog/controller/product/product.php

Or does it go into the catalog/view/theme/default/product/product.tpl file?

User avatar
Active Member

Posts

Joined
Sun Nov 22, 2009 11:04 am

Post by Qphoria » Fri Oct 22, 2010 12:01 am

tpl

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by The Alchemist » Fri Oct 22, 2010 10:45 pm

Just as I thought, its not working. This is the coding I have inserted into the page and this is the code I get.

Code: Select all

Parse error: syntax error, unexpected '[' in /home/content/a/x/i/axidworks/html/catalog/view/theme/default/template/product/product.tpl on line 52
coding I entered

Code: Select all

<tr>
              <td> <b>Shipping:</b></td>
              <td><?php echo $this->currency->format(product_info['shipping_by_product']); ?></td>
              </tr>
             
              

Code: Select all

<tr>
              <td> <b>Shipping:</b></td>
              <td><?php echo $this->currency->format(product_info['shipping_by_product']); ?></td>
              </tr>
             
              <?php  } ?>

Code: Select all

<?php echo $this->currency->format(product_info['shipping_by_product']); ?>
Tried all three variations into the text and got the same error

User avatar
Active Member

Posts

Joined
Sun Nov 22, 2009 11:04 am

Post by Qphoria » Fri Oct 22, 2010 11:35 pm

You are missing the $ in front of product_info

Image


User avatar
Administrator

Posts

Joined
Tue Jul 22, 2008 3:02 am

Post by The Alchemist » Sat Oct 23, 2010 12:37 am

thanks

User avatar
Active Member

Posts

Joined
Sun Nov 22, 2009 11:04 am

Post by sjsjsj » Sun Nov 07, 2010 11:18 pm

I used $product_info['sku'] varible to show other content in product page. Worked, but how to make if SKU field in admin panel is empty to hide content with $product_info['sku'] in product page? I read some PHP, but i cant understand anything.
How to hide this if field SKU in admin is empty? Opencart 1.44

<a style="float:right;" class='video' href="http://www.youtube.com/v/<?php echo $product_info['sku']; ?>?rel=0" /><img src="./image/video.jpg" alt="видео" /></a>

p.s. ..and the solution is
<?php if ($product_info['sku']) { ?>
<a class='video' style="float:right;" href="http://www.youtube.com/v/<?php echo $product_info['sku']; ?>?rel=0" /><img class="videos" src="./image/video1.jpg" alt="видео" /></a>
<?php } ?>

Newbie

Posts

Joined
Thu Dec 31, 2009 7:10 am

Post by pbenfield » Tue May 31, 2011 3:52 pm

This has been one of the most interesting and practical solutions to adding product information field to a products.

At first I could not get Misc Location to come up until I lookeed at the databse entry for "product". When opening this database all the fields are there to be seen, even shipping.

Misc Location for example ist listed as just "location", the diemensions are listed individually, ideal for my website.

I have used Misc Location as "Information" and entered this as explained earlier in this entry as follows as you can put your own text instead of "Misc Location"

Code: Select all


<tr>
  <td><b>Information:</b></td>
  <td><?php echo $product_info['location']; ?></td>
</tr>
I have completed this for all the dimensions

see http://www.online-biz-uk.co.uk

A great entry in this forum

New member

Posts

Joined
Wed Apr 20, 2011 3:43 pm

Post by webpie it. » Fri Jun 03, 2011 6:03 pm

Followed all through this topic.

Compelted all the ones i want to appear, except this one

Just looking to pull Length Class (Centimeter, Inch, etc...)

anyone?

Thnaks

Chris

Regards

Chris


Active Member

Posts

Joined
Mon Jan 31, 2011 7:28 pm

Post by pbenfield » Mon Jun 06, 2011 11:53 pm

In can not check this as my carts are all down but try the following:

Code: Select all


<tr>
  <td><b>Measurement:</b></td>
  <td><?php echo $product_info['length_class_id']; ?></td>
</tr>

I am not sure if that will work but give it a try. It should

New member

Posts

Joined
Wed Apr 20, 2011 3:43 pm

Post by webpie it. » Tue Jun 07, 2011 1:46 am

Yep worked thanksvman

Regards

Chris


Active Member

Posts

Joined
Mon Jan 31, 2011 7:28 pm

Post by averuga » Wed Mar 21, 2012 4:50 pm

Hello! How to draw a conclusion "Live Demo" button for certain categories?

I have seven categories, "Livе Demo" button for two tedious.

thank you

Newbie

Posts

Joined
Wed Mar 21, 2012 4:01 pm
Who is online

Users browsing this forum: No registered users and 28 guests