mirror of
https://github.com/scratchfoundation/jquery-timeago.git
synced 2024-11-23 07:47:54 -05:00
Adding .timeago('updateFromDOM') function
This commit is contained in:
parent
d52af89018
commit
30d5b47d5b
1 changed files with 4 additions and 0 deletions
|
@ -134,6 +134,10 @@
|
|||
update: function(time){
|
||||
$(this).data('timeago', { datetime: $t.parse(time) });
|
||||
refresh.apply(this);
|
||||
},
|
||||
updateFromDOM: function(){
|
||||
$(this).data('timeago', { datetime: $t.parse( $t.isTime(this) ? $(this).attr("datetime") : $(this).attr("title") ) });
|
||||
refresh.apply(this);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue