<id= "btn"><class= "Iconfont " >& #xe602; </ I > Click </span>
<script src= "Js/jquery.min.js" type= "Text/javascript" ></script><script type= "Text/javascript" >(function($) {$.extend ({tipsbox:function(options) {Options=$.extend ({obj:NULL,//JQ object, to be displayed on that HTML tagSTR: "+1",//string, the content to be displayed, or a piece of HTML, such as: "<b style= ' font-family:microsoft yahei; ' >+1</b> "Startsize: "12px",//the text size at which the animation startsEndsize: "30px",//text size at end of animationinterval:600,//Animation time intervalColor: "Red",//text colorCallbackfunction() { }//callback function}, Options); $("Body"). Append ("<span class= ' num ' >" + options.str + "</span>"); varBox = $ (". Num"); varleft = Options.obj.offset (). Left + options.obj.width ()/2; vartop = Options.obj.offset (). Top-options.obj.height (); Box.css ({"Position": "Absolute", ' Left ': Left + ' px ', "Top": Top + "px", "Z-index": 9999, "Font-size": Options.startsize,"Line-height": Options.endsize,"Color": Options.color}); Box.animate ({"Font-size": Options.endsize,"Opacity": "0", "Top": Top-parseint (options.endsize) + "px"}, Options.interval,function() {box.remove (); Options.callback (); }); } });}) (jQuery);functionNicein (prop) {Prop.find (' I '). addclass (' Nicein '); SetTimeout (function() {Prop.find (' I '). Removeclass (' Nicein '); },1000); }$(function () { $("#btn"). Click (function() {$.tipsbox ({obj: $ ( This), str:"+1", Callback:function () { } }); Nicein ($ ( This)); });});</script>
Search the Internet, keep the spare.
Likes +1 effects