vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=134)
-   -   [Release] Spoiler Code (https://vborg.vbsupport.ru/showthread.php?t=88366)

EyeCrave 07-08-2003 10:00 PM

[Release] Spoiler Code
 
Author: Unknown or eyecravedvd
Description: Hides text that some readers may not want to read.

I'm not sure who did the first code, because I've seen it on a few sites, but if someone wants to step forward I'll give them the credit for sure.

I've redone this code to be completely CSS complient. There are no more tables.

It has only been tested with VB 3.0.3, but I'm sure it will work on older versions as well.

*Update - Error in CSS with width has been fixed. New text file.*

mymilkexpired 07-14-2003 03:14 PM

Thats a pretty nifty hack.. i like that!

EyeCrave 07-15-2003 03:48 AM

Thanks, I'm glad you like it. Comes in handy for my site. DVD & Movies... not too many people like having a movie spoiled.

Tony G 07-15-2003 04:53 AM

Definently, love the spoiler tags. :)

SpeedStreet 07-15-2003 11:48 AM

Nifty idea, but with VB3 this can be executed alot more efficiently.

Remember, the transparent color! This will alleviate the need to hard code something in, so that it can apply to multiple themes. Also, by using conditionals, you open yourself up to allowing Admins the right to view it without having to highlight the information.

Conditionals are your friend :D

imported_ogden2k 07-16-2003 09:09 PM

There needs to be some specific rules here, everything HAS TO BE XHTML compliant! That code is not!
This is how it should be:
Code:

<blockquote>
<table bgcolor="#000000" cellspacing="0">
<tr>
<td><font color="#FFFFFF" size="1">Spoiler:</font>
<br /><font color="black">{param}</font>
</td>
</tr>
</table>
</blockquote>

There's a better way to do it with CSS if you want(XHTML compliant too):
In BB custom codes, add a new custom code:
Code:

<font color="#000000"><strong>Spoiler</strong>:</font>
<br /><font class="spoiler">{param}</font>

Under style manger, Additional CSS Definitions, add:
Code:

.spoiler {
    color: #B7B7B7;
    background: #B7B7B7;
}


EyeCrave 07-16-2003 10:50 PM

There is no point in adding it to the CSS. That just means there's more to add. This is quick and gets the job done.

I added the "'s around the words, just to make it XHTML compliant.

Either way, it'll work fine.

imported_ogden2k 07-17-2003 09:50 PM

Either it will work, but that's not the best way to it. Why not be compliant with the standards?

And CSS works much better, it's easier and less over hall.

Sephiroth 9999 07-19-2003 08:58 AM

Sweet mod - I like it! :)

imported_MaDCaT75 07-21-2003 08:11 PM

Ok but how can I choose different colors?

imported_ogden2k 07-21-2003 11:18 PM

Quote:

Originally Posted by MaDCaT75
Ok but how can I choose different colors?

Try my mod, which is posted above. You can change the color tags however you want.

You can also do the same with the original posters too.

imported_MaDCaT75 07-21-2003 11:27 PM

my code seems to be screwed up somehow.....

I did it exactly like you guys said. I tried adding double spoiler tags.

imported_MaDCaT75 07-22-2003 02:35 AM

Nevermind I got it now :D

Skinny.Demon 10-03-2003 05:34 PM

Am I missing something here. The txt file attached only explains how you add a bbcode function. What else do I need to do to get this working? For instance, where is all the code I need to change the colors etc?..

The Quibbler 10-12-2003 01:52 AM

Great mod! Thanks you! :)

EyeCrave 10-03-2004 01:11 PM

Text file has been updated in the first post. I have now made it fully CSS compatible. Please note, that it doesn't work properly in the admincp. It does work fine in the forums. For an example head here

http://www.eyecravedvd.com/forums/showthread.php?t=423

imported_khaleel 10-04-2004 07:29 PM

Great hack goes well with my harry potter site im sure m1th will agree

Quelyn 03-10-2005 12:39 PM

Finally this was exactly what I was looking for! Thanks so much

commTRU 08-21-2005 07:48 PM

This is a great add-on, thanks :)


All times are GMT. The time now is 04:47 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01270 seconds
  • Memory Usage 1,748KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (19)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete