vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Making "Work Safe" Style (https://vborg.vbsupport.ru/showthread.php?t=92647)

.Tim 07-21-2005 08:20 PM

Making "Work Safe" Style
 
I want to make a style where avatars and signatures don't show up at all and images (including attachments) show up as links. Like if the user had turned them off in their options. I don't want to effect any other style except the worksafe one. I know how to get rid of the avatars and signatures but not how to get the images/attachments how I want them. Any suggestions?

Dean C 07-22-2005 09:13 AM

Well make a child style of the current one you have. And just edit out the avatars and signatures from the postbit/userprofile templates :)

.Tim 07-22-2005 10:22 PM

1 Attachment(s)
I already have the avatars and signatures taken care of. It's the attachments/images that I'm having the problem with. I want them to appear as links, like it would if you have them turned off in the options but I only want it like that for the work safe style.

Like this, but only in the work safe style. I want the other styles to work normally and show the images.

Brinnie 07-22-2005 10:31 PM

Bump for .Tim :)


(is this the .Tim from invisionize?)

.Tim 07-22-2005 10:43 PM

Sorry, it's not. :D

.Tim 09-30-2005 02:03 AM

I finally got around to messing with this some more. I was able to get the attachments to show up as links like in the example. But I'm not able to figure out how to get images with the [img] tag to show up as a link.

damnit77 11-22-2005 06:05 PM

BUMP...

I am trying to do the same thing.....make a worksafe theme. .Tim, did you ever figure out how to disable images in a style?

Stangsta 11-22-2005 08:33 PM

Quote:

Originally Posted by .Tim
I finally got around to messing with this some more. I was able to get the attachments to show up as links like in the example. But I'm not able to figure out how to get images with the [img] tag to show up as a link.

how did you do it?

Borgs8472 11-22-2005 09:35 PM

Can conditionals be done with styles?

e.g.

if ( style is not bbuserinfo[style7] )

Show avs here

else

don't

/if

It would be nice...

damnit77 11-22-2005 09:38 PM

Or if anyone wants to let me use their worksafe theme..... :)

.Tim 11-22-2005 09:41 PM

Quote:

Originally Posted by Stangsta
how did you do it?

I don't remember, I'll have to look into it. I gave up on this project for now but I should still have the changes I made somewhere.

merk 11-22-2005 10:35 PM

1 Attachment(s)
Done :)

Not sure if this will work in 3.5.0, only tested on 3.5.1

Upload the attached plugin and modify it (change STYLEID = 67 to STYLEID = <styleid> of your worksafe style).

Stangsta 11-22-2005 11:34 PM

Quote:

Originally Posted by merk
Done :)

Not sure if this will work in 3.5.0, only tested on 3.5.1

Upload the attached plugin and modify it (change STYLEID = 67 to STYLEID = <styleid> of your worksafe style).

working on 3.5.1 here

How would you remove the avatars on that specific style? Remove it from the postbit?

.Tim 11-23-2005 12:13 AM

Quote:

Originally Posted by Stangsta
How would you remove the avatars on that specific style? Remove it from the postbit?

That's what I did.

ZGeek 11-23-2005 09:36 PM

Quote:

Originally Posted by merk
Done :)

Not sure if this will work in 3.5.0, only tested on 3.5.1

Upload the attached plugin and modify it (change STYLEID = 67 to STYLEID = <styleid> of your worksafe style).

Awesome stuff. I have custom bb image code [newsimg] is it possible to modify this to include items like this?

merk 11-23-2005 10:18 PM

It is (afaik) possible to do what you want, except its complex. The way I see you being able to do it is using the bbcode_create hook to modify the $this->tag_list array to modify the replacement html of the bbcode as the bbcode parser starts up.

It would look something like below, but note that i did it based on the tag example [newsimg]url[/newsimg] not [newsimg=url]text[/newsimg]. To do the second one, change no_option to option. I havent tested this and it could break the bbcode parser (with either setting).

PHP Code:

if(STYLEID == XX)
{
$this->tag_list['no_option']['newsimg']['html'] = '<a href="{param}" target="_new">{param}</a>';



moonclamp 11-24-2005 12:10 AM

I would be interested in something like this that could also turn on the swear filter.

I don't filter anything on my site but there have been problems with people getting locked out when their work software detects profanities.

merk 11-24-2005 12:43 AM

in global_start

PHP Code:

if(STYLEID == XX)
{
$vbulletin->options['enablecensor'] = 1;
$vbulletin->options['censorwords'] = "WHATEVER WOULD GO INTO THE CENSOR WORDS INPUT IN THE ADMINCP";
$vbulletin->options['censorchar'] = '*'#only necessary if you dont already have it set, could always set it in admincp and take this line out



ZGeek 12-01-2005 09:02 PM

thanks merk, I will give that a shot.

robgeo 05-08-2006 10:07 AM

Quote:

Originally Posted by Dean C
Well make a child style of the current one you have. And just edit out the avatars and signatures from the postbit/userprofile templates :)


Thanks!!!!

Kooldino 01-06-2008 07:18 PM

Quote:

Originally Posted by merk (Post 828115)
Done :)

Not sure if this will work in 3.5.0, only tested on 3.5.1

Upload the attached plugin and modify it (change STYLEID = 67 to STYLEID = <styleid> of your worksafe style).

Where do I find out the styleID?

Also, how will the user use this? I was looking for some kind of one-click solution to toggle between normal view and no avatars/no signatures.

dismas 01-06-2008 08:16 PM

You can find the styleID by going to your Style Manager and pulling down the menu to "Edit Settings". The resulting page will list the id at the top.

And for switching, the stock vB install include a pull down menu style chooser in the lower left hand corner of every page.


All times are GMT. The time now is 09:02 AM.

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.03234 seconds
  • Memory Usage 1,761KB
  • 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
  • (2)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (22)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