Advertisement
Guest User

Untitled

a guest
May 26th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. (function($) {
  2. 'use strict';
  3.  
  4. $('<style>')
  5. .text([
  6. '.shoutbox-lenny {'
  7. , ' background-color: #ff6600;'
  8. , ' color: white !important;'
  9. , ' display: inline-block;'
  10. , ' line-height: 24px;'
  11. , ' vertical-align: middle;'
  12. , ' border-radius: 12px;'
  13. , ' padding: 0 10px;'
  14. , '}'
  15. ].join('\n'))
  16. .appendTo('head')
  17. ;
  18.  
  19. $(function() {
  20. var $message = $('#shoutbox_message');
  21. var session = $message.next().attr('onclick').replace(/.*'(.*)'.*/, '$1');
  22.  
  23. $('<a>', {
  24. href: '#',
  25. text: '( ͡° ͜ʖ ͡°)',
  26. 'class': 'shoutbox-lenny',
  27. })
  28. .on('click', function(event) {
  29. $message.val($.trim($message.val() + ' ( ͡° ͜ʖ ͡°)'));
  30. Shoutbox_SentMsg(session);
  31. event.preventDefault();
  32. })
  33. .prependTo('#shoutbox table:last td:last div')
  34. ;
  35. });
  36. }(jQuery));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement