// ==UserScript== // @name Add Subscription // @author Martin Jonáš // @include http://forum.thesims2.cz/posting.php?mode=reply* // @include http://forum.thesims2.cz/posting.php?mode=newtopic* // @include http://forum.thesims2.cz/posting.php?mode=quote* // ==/UserScript== window.addEventListener('DOMContentLoaded', function() { var textArea = document.getElementsByTagName('textarea')[0]; var position = 0; if (textArea.value.length > 0) { position = textArea.value.length + 2; } var podpis = "\n\n____________\n Podpis :)"; textArea.value += podpis; textArea.focus(); textArea.setSelectionRange(position, position); }, false);