title: Changing jQuery marquee text and css/style
body: <p>I have div</p>
  
  <pre><code>&lt;div id="rotatingText" class="marquee"&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>and marquee on that div is initialized on window load</p>
  
  <pre><code>jQuery('.marquee').marquee({
          duration: 3000,
          gap: 50,
          delayBeforeStart: 0,
          direction: 'left',
          duplicated: false
      });
  </code></pre>
  
  <p>Now i need to change text and css of that div on ajax aftersuccess. I get new text and css properties in that ajax response. With that text and css I invoke following:</p>
  
  <pre><code>function setRotatingTextProperties( value, css, objectId )
  {
      var object = document.getElementById( objectId );
      object.innerHTML = value;
      jQuery ( object ).attr( 'style', css );
  }
  </code></pre>
  
  <p>After that marquee stops working. 
  I think that jQuery marquee sets some style in that div and i override it with:</p>
  
  <pre><code>jQuery ( object ).attr( 'style', css );
  </code></pre>
  
  <p>if I just add my css to existing with </p>
  
  <pre><code>var currentCss = jQuery ( object ).attr( 'style');
  jQuery ( object ).attr( 'style', currentCss + css );
  </code></pre>
  
  <p>with multiple changes I will end up with huge amount of unusable css. And that css will change regularly ( every fiew seconds )...
  Any advice and idea will be much appreciated.
  Thx in advance.</p>