Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...

Bitcrusher

Members
  • Posts

    7
  • Joined

  • Last visited

Bitcrusher's Achievements

1

Reputation

  1. Oh good gravy. So the one thing that I didn't try doing was moving the script references below the divs, I kept it in the <head>. Once I moved that down everything fired up! AND...that is why I should stay away from coding, go back to being an art director. Thanks ohem!!!!!!
  2. I had thought about that and tried it, the animations still wouldn't trigger. This worked fine on the HTML page, though. Sorta odd how this isn't really panning out. The really odd thing is I went through and stripped out all other code in the .js and also the HTML so that it was just the div and the animation code in the .js - and it didn't work. Works perfectly when I have this on the HTML page. Somnamblst - right, it's pointroll and they were a bit particular about running any code on the page, so most of the code was moved over to all be in a .js file. Right now they are still in the works with how to handle everything and unfortunately there isn't something available like the creative manager (app), so things are moving slowly.
  3. as a follow-up, more weirdness. I tried the codes from everyone to see if there might've been something that I was missing but no luck. I then decided to roll it back, stripped out all javascript in my .js file outside of the basic animation function and again, nothing. One thing that I did run into yesterday and again today was an error that pops up in the console Uncaught Cannot tween a null object TweenMax.js 6539 The odd thing is that line in the code is for TweenLite. The version I'm running was * VERSION: 1.18.0 * DATE: 2015-09-05 which I had just downloaded. so, to expand on the code that I have... HTML page: <head> <title></title> <link rel="stylesheet" href="css/pr300x250.css" /> <script src="http://speed.pointroll.com/PointRoll/Media/Asset/Pointroll_HTML_Code_Repository/209670/prTrk.js"></script> <script type="text/javascript" src="js/pr300x250.js"></script> <script type="text/javascript" src="gs/easing/EasePack.js"></script> <script type="text/javascript" src="gs/plugins/CSSPlugin.js"></script> <script type="text/javascript" src="gs/TweenMax.js"></script> </head> <body> <div id='pr300x250BannerCopy'>banner copy to move?</div> </body> </html> CSS didn't change and the .js file (now) just has // JavaScript Document var copyOne = document.getElementById('pr300x250BannerCopy'); function AnimateBanner(){ TweenMax.to(copyOne, 1, {left:'400px', repeat:-1, repeatDelay:1, yoyo:true}); } AnimateBanner(); So pretty stripped down and yet, when I pop this into chrome (locally) nothing happens. Dreamweaver throws a warning/error that TweenMax is not defined in the .js file and I still get the error mentioned above. To add to the bit o' frustration, I had moved the code to the html page and just dropped it into a script tag...and it worked. So how can I get this to work using a separate .js file? thanks!
  4. Thanks! The actual name of the DIV and code was stripped out due to legal reasons (I work in the medical industry), so normally it would start off with some letters pertaining to the campaign versus numbers. Looking over the code that you both had passed over looked about right so the other thing I might be running into would be any other javascript that is killing the actual tween. There are a number of API functions from the company we use to serve out the ads that could be the problem.
  5. Like many I ended up needing a crash course on javascript after the browsers vs. adobe was launched. While I am quite familiar with running GS with actionscript I'm finding that doing the same isn't transitioning over as easily as I thought, generating a ton of questions and hair-pulling. So the company I work for has an expanding banner product that uses javascript (primarily) in a separate file, nothing on the page or inline. Layout is all CSS + DIVs. While trying to set up even some super rudimentary animations I'm finding that either the function doesn't run or there are errors. Questions are... + Possible to set functions in javascript, or do I need to use jquery? I tried to do a simple bit of animation and so far no dice = HTML Page <script src="gs/TweenMax.min.js"></script> <div id='300x250BannerCopy'>banner copy to move?</div> CSS File #300x250BannerCopy { width:200px; height:46px; background-color:#FF8500; padding:10px; font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif; font-size:17px; font-weight:bold; color:#fff; position: relative; display: block; } and in a .js file function 300x250AnimateBanner(){ var copyOne = document.getElementById('300x250BannerContainer'); TweenMax.to(copyOne, 1, {left:'400px'}); } 300x250AnimateBanner(); which I would have expected to move the div over but nothing happens. I went through a number of pages plus tried to do some searches online to see if I could find anything else that might help but nothing really pointed to how to handle running TweenLite or Max through javascript. Also tried to do TweenMax.to('#300x250BannerContainer', 1, {left:'400px'}); but no results. Running TweenMax / Lite in Flash was quite a bit easier... Would I need to use the CSS plugin for this instead? Which I tried but that didn't really do anything either. Any guidance or suggestions would be greatly appreciated!
  6. Balls! that was it - I set autoAlpha to 1 and sure enough, no more rendering issues. I'll need to purge my AS2 ways. Thanks!!
  7. Hi - I'm working on a new project to ramp up my AS3 skills. One thing I have is a MC with a dynamic text filed within. The text field has html copy along with styles provided via external CSS. The MC scrolls, then once it hits the onComplete there's a slight delay, autoAlpha:0 then another onComplete to fade it back in / reposition at 0,0. Everything works fine, however the copy, once the animation is reset has major aliasing issues. The image will show the before and after: when I kill the alpha and just have a normal scroll it looks fine. Frankly I'm baffled as to why the copy went coo coo for cocoa puffs - any help, advice or guidance would be appreciated! Not sure if this is a common bug or not. Thanks!
×