| ||||||||||
![]() |
Shopping cart software Solutions for online shops and malls | |||||||||
![]() |
![]() |
|
X-Cart Home | ![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
custom add to cart button | ||||
![]() |
|
|
Thread Tools | Search this Thread |
#11
|
|||||||
|
|||||||
![]() Each button has multiple pieces and classes - it is meant to be a dynamic button - scales up or down based on the size of the text. You can't just add a graphic without re-coding the whole template. So in order to change the buttons globally, you'd need to slice up your button into the appropriate graphics and then change the CSS as well.
__________________
Padraic Ryan Ryan Design Studio Professional E-Commerce Development |
|||||||
#12
|
|||||||||
|
|||||||||
![]() yes that is possible.
__________________
xcart 5.1.2 |
|||||||||
#13
|
|||||||||
|
|||||||||
![]() The atc button he wants to use is quite a bit bigger than the other buttons.
it's possible to just make the atc button bigger tho, just need to change the CSS to accommodate the size, but will also need to change button.tpl to call the appropriate classes.
__________________
xcart 5.1.2 |
|||||||||
#14
|
|||||||
|
|||||||
![]() I could make the buttons smaller, to fit the size, but its the font styles I would like to keep.
__________________
Helping the world turn X-Cart version 4.3.2 |
|||||||
#15
|
|||||||||
|
|||||||||
![]() if you want to keep the font style, you might as well make them bigger too.
So basically you need to add a custom style to each button. Do this in the customer/buy_now.tpl The add an if statement to customer/button.tpl for the new style. You can change the html in teh buttons.tpl to whatever you want. Here you add your new styles for each state of the buttons. You will need to figure out what classes are currently controlling the buttons, and mimic them with new names, then adjust the styles accordingly. Try it out, and let me know your progress. I'll help as much as I can.
__________________
xcart 5.1.2 |
|||||||||
#16
|
|||||||
|
|||||||
![]() Hi
Thanks for the help, we have been tweaking them all day using firebug to find the correct styles, very awkwardly set out, but we are nearly there, you can have a look here: http://sleepywings.co.uk Once getting into if statement, i get a little confused ![]() There is one problem we are finding troublesome: http://sleepywings.co.uk/error_message.php?need_login The log in box on the right is is still showing, is it possible to write an 'if' statement to use one set of html normally and another for this page? if so how could we do this?
__________________
Helping the world turn X-Cart version 4.3.2 |
|||||||
#17
|
|||||||
|
|||||||
![]() Code:
Goes in the .tpl file where it calls the auth box. Be sure the replace the stuff inside the {if}{/if} with the code that calls the auth box. |
|||||||
#18
|
|||||||||
|
|||||||||
![]() Looks like you are getting it.
Yes it is possible to have thing only show on certain parts of the site. There is a varable called main. so it would go like this.. {$main eq 'certain-section'} html {if} or {$main eq 'certain-section'} certain-section html {elseif $main eq 'different-section' dif-sedtion html {else} html on all pages here {if} you can look in home_main.tpl to find many of the sections. I believe you are looking for {if main eq 'need_login'} tho
__________________
xcart 5.1.2 |
|||||||||
#19
|
|||||||
|
|||||||
![]() I kinda understand,
This would be normal code: <div class="nav_bottom"> </div> </div> <div id="login"> <div class="nav"> <div class="nav_main" style="min-height:35px;"> {if $login eq "" } {include file="customer/auth.tpl" } {else} {include file="customer/authbox.tpl" } {/if} {include file="customer/news.tpl" } {if $active_modules.XAffiliate && $config.XAffiliate.partner_register eq 'Y' && $config.XAffiliate.display_backoffice_link eq 'Y'} {include file="partner/menu_affiliate.tpl" } {/if} {if $active_modules.Interneka} {include file="modules/Interneka/menu_interneka.tpl" } {/if} {include file="poweredby.tpl" } </div> </div> There would be nothing for error_message.php?need_login Gonna have to play with it tomorrow now, been at it 15 hours today ![]() Thanks for your help!!
__________________
Helping the world turn X-Cart version 4.3.2 |
|||||||
#20
|
|||||||
|
|||||||
![]() Code:
Try that out. |
|||||||
|
|||
X-Cart forums © 2001-2020
|