Jump to content
Search Community

Cursor not changing on mouseover (Animate html5 banner)

kili0601 test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Hi, new to these forums. I have a html5 banner I created in Animate for DCM with a click tag. Everything works fine, the link works if you click the banner, it validates in DCM html checker, but when i view the banner in a browser the cursor doesn't change to the hand/pointer cursor like it does on all links, banners. Any idea why this would happen? Any help would be much appreciated!

 

Thanks!

Link to comment
Share on other sites

Hello kili0601 and welcome to the GreenSock forum!

 

This is more of a CSS related question then a question regarding the GSAP API

 

So depending on what element you want  the CSS cursor:pointer property on.. then add this to your CSS style-sheet or style tag

.element-you-want-hand-cursor-on {
    cursor: pointer;
}

If you still don't see the hand cursor, then some other style is overriding the cursor CSS property in another CSS rule or even inline on the tag. In that case you could add this

.element-you-want-hand-cursor-on {
    cursor: pointer !important;
}

Resource:

CSS cursor property: https://developer.mozilla.org/en-US/docs/Web/CSS/cursor

 

If your still having an issue please create a reduced codepen so we can see your code live:

 

 

:)

Link to comment
Share on other sites

This is a little confusing since we don't actually use the button to click through. Just having a button symbol gives you a cursor, and it adds this to your published HTML

 

stage.update();
stage.enableMouseOver();
 
and then on your canvas div right before ending >
onclick="javascript:window.open(window.clickTag)
 
Alternately you could wrap your canvas div with an HREF but its not valid. (though it does work)
Link to comment
Share on other sites

Hey guys, with Animate and CreateJS I found that using the stage.enableMouseOver() a bit laggy even if you bump of the rate.

 

Check out the template in this thread where we use Animate CC and GSAP together. There are 2 Profile templates for Standard and Rich Media DC Banners

http://greensock.com/forums/topic/13774-animate-cc-gsap-starter-file-needed/#entry58050

 

Depending on how you need the cursor to perform this may or may not work for you. In most banner cases this template should serve you fine.

 

Take a look and let me know how it works for you

 

Good luck

- Patrick

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...