Hello,
I have an issue. My knowledge in php is rather limited, and this is nothing but agravated by the use of JHTML and J* stuff that i don't really understand. Here is my problem:
I want to completely remove the Product details button and and it's link to the thumbnail of the product. No modal popup for image, just the link to product details. I have tried doing it myself but due to limited know how in php couldn't achieve anything.
While i continue my research and i try to fix the problem myself, i really hope someone can help me with these, i feel like i`m not moving at all.
here is the website:
http://www.xquisiteart.com
Change in:
templates/your_template/html/com_virtuemart/category/default.php or components/com_virtuemart/views/category/tmpl/default.php
echo $product->images[0]->displayMediaThumb('class="browseProductImage" border="0" title="'.$product->product_name.'" ',true,'class="modal"');
with this one
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
templates/your_template/html/com_virtuemart/virtuemart/default_products.php or components/com_virtuemart/views/virtuemart/tmpl/default_products.php
if ($product->images) {
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',true,'class="modal"' ) );
}
with this one:
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
}
This should work.
I found that helpful as well. I removed the product details button as it seems redundant and made the font for the product name line larger. It looks much better. Thanks.
i have done some changins in productdetailede and improved the look of it :D
[attachment cleanup by admin]
Thank you very much Adi! It worked like a charm!
I like what you have done. Would you car to share some of your work with me? I am guessing that you used the custome fields to create the specifications? Send me a PM?
Yes indeed i use custom field for specifications.
any suggestions where this can be in virtuemart 1.9?
Hi adrianpaun. You said to edit two files but if I apply the edit you suggested to only templates/your_template/html/com_virtuemart/category/default.php my thumbnails from my category page direct fine to my product details page. What is the purpose of also editing the templates/your_template/html/com_virtuemart/virtuemart/default_products.php page?
Thanks!
Quote from: adrianpaun on April 12, 2012, 02:05:09 AM
Change in:
templates/your_template/html/com_virtuemart/category/default.php or components/com_virtuemart/views/category/tmpl/default.php
echo $product->images[0]->displayMediaThumb('class="browseProductImage" border="0" title="'.$product->product_name.'" ',true,'class="modal"');
with this one
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
templates/your_template/html/com_virtuemart/virtuemart/default_products.php or components/com_virtuemart/views/virtuemart/tmpl/default_products.php
if ($product->images) {
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',true,'class="modal"' ) );
}
with this one:
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
}
This should work.
Quote from: furtherdg on September 20, 2012, 21:05:45 PM
Hi adrianpaun. You said to edit two files but if I apply the edit you suggested to only templates/your_template/html/com_virtuemart/category/default.php my thumbnails from my category page direct fine to my product details page. What is the purpose of also editing the templates/your_template/html/com_virtuemart/virtuemart/default_products.php page?
Thanks!
Quote from: adrianpaun on April 12, 2012, 02:05:09 AM
Change in:
templates/your_template/html/com_virtuemart/category/default.php or components/com_virtuemart/views/category/tmpl/default.php
echo $product->images[0]->displayMediaThumb('class="browseProductImage" border="0" title="'.$product->product_name.'" ',true,'class="modal"');
with this one
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
templates/your_template/html/com_virtuemart/virtuemart/default_products.php or components/com_virtuemart/views/virtuemart/tmpl/default_products.php
if ($product->images) {
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',true,'class="modal"' ) );
}
with this one:
echo JHTML::_ ( 'link', JRoute::_ ( 'index.php?option=com_virtuemart&view=productdetails&virtuemart_product_id=' . $product->virtuemart_product_id . '&virtuemart_category_id=' . $product->virtuemart_category_id ), $product->images[0]->displayMediaThumb( 'class="featuredProductImage" border="0"',false,'class="modal"' ) );
}
This should work.
the first one does not apply to the featured products; the second one does.