javascript code to add animated.gif

javascript code to add animated.gif

Page 1 of 1

4 Replies - 2562 Views - Last Post: 30 December 2010 - 05:10 PM

#1 dbeaird727  Icon User is offline

  • D.I.C Head

Reputation: -2
  • View blog
  • Posts: 238
  • Joined: 13-December 10

javascript code to add animated.gif

Posted 30 December 2010 - 09:39 AM

What is wrong with my code. I am very new to javascript and I need to add this (or a corrected variation of this) to a .php file. I need it to run when someone is uploading content so that my animated icon will let the users know something is going on. obviously the animated.gif is not included because i dont know where to put it exactly :/ I'm just trying to learn. Any feedback is great :)




div id= "bs"
display: none

$('toolbar-save').addEvent('click',function(){
$('bs').setStyle('display','block');
});

$('toolbar-apply').addEvent('click',function(){
$('bs').setStyle('display','block');
});



Is This A Good Question/Topic? 0
  • +

Replies To: javascript code to add animated.gif

#2 e_i_pi  Icon User is offline

  • = -1
  • member icon

Reputation: 789
  • View blog
  • Posts: 1,675
  • Joined: 30-January 09

Re: javascript code to add animated.gif

Posted 30 December 2010 - 10:56 AM

What Javascript library are you using? Is it Prototype? What you've got there isn't strict Javascript. Or PHP or HTML for that matter.
Was This Post Helpful? 0
  • +
  • -

#3 dbeaird727  Icon User is offline

  • D.I.C Head

Reputation: -2
  • View blog
  • Posts: 238
  • Joined: 13-December 10

Re: javascript code to add animated.gif

Posted 30 December 2010 - 12:14 PM

Just basic javascript I suppose. This code was taken from a forum and it is used for the same thing im using it for. The code just looks weird in my code editor.. as far as color, etc.
Was This Post Helpful? 0
  • +
  • -

#4 forest51690  Icon User is offline

  • D.I.C Regular
  • member icon

Reputation: 58
  • View blog
  • Posts: 340
  • Joined: 20-March 09

Re: javascript code to add animated.gif

Posted 30 December 2010 - 04:50 PM

It looks like code for a javascript library. To me it looked like jQuery, but I don't use libraries, so idk. Go back to the forum you got the code from and see if they mention using any libraries.
Was This Post Helpful? 0
  • +
  • -

#5 Guest_dbeaird727*


Reputation:

Re: javascript code to add animated.gif

Posted 30 December 2010 - 05:10 PM

It jquery ..sorry I'm not familiar enough to know off thhe top of my head but yes thats it for sure.
Was This Post Helpful? 0

Page 1 of 1