Post by Trill on Feb 5, 2010 15:28:08 GMT -8
I'm having a little trouble with Greasemonkey. I've created a little table to easily post automated messages/replies:
awardstest.proboards.com/index.cgi?board=general&action=post&thread=1"e=2&page=1
I've tried to add that to Greasemonkey, but it doesn't seem to work. Does Greasemonkey only work with Javascript? I tried adding HTML and CSS, but that doesn't work. Then I tried document.write in JS, but that didn't seem to work either (probably because I didn't do something correctly). Here's what I have:
document.write('<table id="supporttab" class="bordercolor" cellpadding="4px" cellspacing="1px"><tr><td align="center" class="titlebg">Support Quicklinks</td></tr><tr><td class="windowbg"><center><a href="javascript:add(\'%20Search (CTRL+F) the [codeindex] for%20\')">Search Code Index</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><hr><font size="1">Created by <a href="http://support.proboards.com/index.cgi?action=viewprofile&user=ghbraingle" target="_blank">Trill</a> at ProBoards® Support <br /><a href="http://support.proboards.com/index.cgi?action=pmsend&to=ghbraingle&subject=Support%20Quicklinks">Suggest</a> a quicklink.</font></center></td></tr></table>');
Once I get this working, I'll add:
if(document.title.match(/- Post Message$/)) {
code
}
Then, would there be a way to style the table using CSS to set these attributes?
position: absolute;
top: 40px;
right: 40px;
position: fixed;
Would I just add this to the opening table tag? style="position: absolute; top: 40px; right: 40px; position: fixed;"
Thanks in advance for any help.
awardstest.proboards.com/index.cgi?board=general&action=post&thread=1"e=2&page=1
I've tried to add that to Greasemonkey, but it doesn't seem to work. Does Greasemonkey only work with Javascript? I tried adding HTML and CSS, but that doesn't work. Then I tried document.write in JS, but that didn't seem to work either (probably because I didn't do something correctly). Here's what I have:
document.write('<table id="supporttab" class="bordercolor" cellpadding="4px" cellspacing="1px"><tr><td align="center" class="titlebg">Support Quicklinks</td></tr><tr><td class="windowbg"><center><a href="javascript:add(\'%20Search (CTRL+F) the [codeindex] for%20\')">Search Code Index</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><a href="javascript:add(\'%20Bye\')">Bye</a><br /><hr><font size="1">Created by <a href="http://support.proboards.com/index.cgi?action=viewprofile&user=ghbraingle" target="_blank">Trill</a> at ProBoards® Support <br /><a href="http://support.proboards.com/index.cgi?action=pmsend&to=ghbraingle&subject=Support%20Quicklinks">Suggest</a> a quicklink.</font></center></td></tr></table>');
Once I get this working, I'll add:
if(document.title.match(/- Post Message$/)) {
code
}
Then, would there be a way to style the table using CSS to set these attributes?
position: absolute;
top: 40px;
right: 40px;
position: fixed;
Would I just add this to the opening table tag? style="position: absolute; top: 40px; right: 40px; position: fixed;"
Thanks in advance for any help.