|
Post by Streamstrider on Sept 20, 2011 22:33:40 GMT -8
Is there a way to cancel the effect of a global footer code in the footer of a single board? Reason being, I want to change the style of the code tags, but only in one board, not the entire forum.
|
|
|
Post by Wormopolis on Sept 20, 2011 23:19:40 GMT -8
you would have to trick it by writing CSS UNDER the CSS you have globally with a document.write statement:
<script type="text/javascript"> if (location.href.match(/board=BOARDID/)) { document.write('<style type="text/css"> CSS IN HERE </sty' + 'le>'); } </script>
and put all the CSS on one line.
|
|
|
Post by Streamstrider on Sept 21, 2011 0:59:50 GMT -8
I forgot to mention, that by style, I didn't necessarily mean CSS.
The following is the code I currently have in my global footer.
<style type="text/css"> .codeArea { border: 1px solid black; } </style> <script type="text/javascript"> /* Code Tag Modification by hpmad Do not repost or claim as your own without permission This header must remain intact */ REDACTED
</script>
I want to have Alex's code to replace this function on one particular board.
|
|
|
Post by Wormopolis on Sept 22, 2011 17:59:39 GMT -8
for that you will need to incorporate your own IF statements blanketing the 2 codes:
hpmad's code would get this:
<script type="text/javascript"> /* Code Tag Modification by hpmad Do not repost or claim as your own without permission This header must remain intact */ if (!location.href.match(/board=BOARDID(&|$)/i)) {
the rest of his code
} </script>
that curly bracket just above </script> is an extra bracket you have to add to match up with the one you added at the top.
then in Alex's code, its almost the same thing:
<script type="text/javascript">
if (location.href.match(/board=BOARDID(&|$)/i)) {
alex's code
} </script>
the boardid is the id you gave it when you created it. NOT the name of the board. example would be the id of this board is "codeother"
|
|
|
Post by Streamstrider on Sept 23, 2011 21:42:56 GMT -8
So, the first one excludes the code from that board, and the second limits it to that board? Do both go in the Global Footer?
|
|
|
Post by Wormopolis on Sept 24, 2011 9:29:44 GMT -8
both can.. OR you can just do the first part to hpmad's code, and put alex's code ONLY in the one boards footer and skip the blanket part of it.
|
|
|
Post by Streamstrider on Sept 24, 2011 15:41:03 GMT -8
Woot! Thank you so much Wormo! That helped a lot!
|
|
|
Post by Wormopolis on Sept 24, 2011 17:45:42 GMT -8
no problem!
extra words again
|
|
|
Post by Streamstrider on Sept 25, 2011 21:10:30 GMT -8
Okay, here's another thing related to this request. Is there any way to exclude a code from entire categories?
|
|