Cart button transfer

Rate this topic: Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.Evaluations: 1, 1.00 on the average.1.00 out of 6 based on 1 vote(s)
GK User
Wed Feb 26, 2014 10:27 am
Reply with quote
Report this post
Hi,

which part do I have to transfer/copy when I want to use the cart-button in the template "Shop and Buy"

Best regards
ocean
User avatar
Senior Boarder

teitbite
Wed Feb 26, 2014 10:42 am
Reply with quote
Report this post
Hi

I'm afraid it's a customisation request and we do not support that. Try using Firebug to determine the HTML code of this button and than copy all css related to it. Javascript related is in /js/gk.script.js file.
User avatar
Moderator

GK User
Wed Feb 26, 2014 11:08 am
Reply with quote
Report this post
the html I already found
the javascript I don't until now :-)
but I don't want to change the gk.script.js because when there are updates I have to change that part again.
User avatar
Senior Boarder

teitbite
Thu Feb 27, 2014 8:48 pm
Reply with quote
Report this post
Hi

This is the part responsible for the move effect. If You want to copy that, than adding it to javascript file is required.

Code: Select all
         var btn = document.id('btnCart');
         
         window.addEvent('scroll', function(e) {
            var scroll = window.getScroll().y;
            var max = document.id('gkMainWrap').getSize().y;
            var final = 0;
            if(scroll > 70) {
               if(scroll < max - 122) {
                  final = scroll - 50;
               } else {
                  final = max - 172;
               }
            } else {
               final = 20;
            }
            btn.setStyle('top', final + "px");
         });
User avatar
Moderator


cron