Post by james101 » Mon Apr 11, 2011 5:56 am

florinsith wrote:Post the exact code of your add to cart button here. Leave the css alone.

All the respect!
This is the code for add to car in the tpl file.

<a onclick="$('#product').submit();" id="add_to_cart" class="button"><span><?php echo $button_add_to_cart; ?></span></a>


And this is the code for the live demo also in the tlp flie next to add to car.

<a class="button2" target="_blank" href="<?php echo $product_info['sku']; ?>">Live demo</a>

And this is the full code in the stylesheet.

}
.button_add_small, a.button_add_small:visited {
margin-top: 3px;
background: url('../image/button_add_small.png') no-repeat left center transparent;
padding:5px;
text-decoration: none;
cursor:pointer;
.button2 {
padding-left: 8px;
display: inline-block;
margin-right: 5px;
background: url('../image/button_add_small') top left no-repeat;
text-decoration: none;
color:#FFF;
}
.button2 span {
color: #FFF;
display: block;
padding: 4px 12px 5px 5px;
background: url('../image/button_add_small') top right no-repeat;

Thanks James

New member

Posts

Joined
Tue Apr 05, 2011 10:14 pm

Post by inactiveaccount9912 » Mon Apr 11, 2011 6:31 am

Use this one , and leave the css alone. The button add small is the small button from listing.
<a class="button" target="_blank" href="<?php echo $product_info['sku']; ?>"><span>Live demo</span></a>

All the respect!

Expert Member

Posts

Joined
Fri May 14, 2010 2:36 am

Post by james101 » Mon Apr 11, 2011 8:47 am

florinsith wrote:Use this one , and leave the css alone. The button add small is the small button from listing.
<a class="button" target="_blank" href="<?php echo $product_info['sku']; ?>"><span>Live demo</span></a>

All the respect!
Thank you for that its all looking how i want it now.

How would i make it so it will only show on certain pages. ( i dont want the live demo button to show on all the product page ) just some.

Thank you... You have been a real help and its greatly appreciated

James.

New member

Posts

Joined
Tue Apr 05, 2011 10:14 pm

Post by adminzzz » Mon May 23, 2016 9:05 pm

can you please help me how to implements above instruction. I am new to opencart. Please assist me step by step instruction. I am using 2x version.

Tanks in Advance

Newbie

Posts

Joined
Mon May 23, 2016 12:48 pm

Post by adminzzz » Tue May 24, 2016 6:50 pm

Please see the below link of my site , The Live Demo button not redirected the same address but i put the details address in sku of product page.

please help me to figure out the issue.


http://www.templates420.com/templates42 ... h=17_59_60

Newbie

Posts

Joined
Mon May 23, 2016 12:48 pm
Who is online

Users browsing this forum: No registered users and 130 guests