Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 06-20-2002, 09:09 PM
futureal futureal is offline
 
Join Date: Feb 2002
Location: Del Mar, CA, USA
Posts: 556
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default User-Configurable Censorship Options

Hi all,

This might sound like an odd hack, but I am looking for something that would allow users to toggle on/off the censorship feature of the site.

Would this be easy to do?

I have a site with a good number of teenage/young-adult users, some of which don't mind the occasional profanity, others who tend to be offended. I would like to give them the option to censor a default list of words. However, I don't want to do forum-wide censorship.

A "wish list" would include the option for users to individually set a list of words to be censored...
Reply With Quote
  #2  
Old 06-21-2002, 08:33 PM
Chris M's Avatar
Chris M Chris M is offline
 
Join Date: Dec 2001
Location: Northampton, England
Posts: 6,186
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This would be an excellent Idea!

Satan
Reply With Quote
  #3  
Old 06-21-2002, 10:54 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

then code it satan

actually this is doable, but you have to go throug some files to clean the censortext function out of it
change the censortext function in functions.php an other small things, not really hard to code, but timeintensive
Reply With Quote
  #4  
Old 06-22-2002, 05:46 AM
Logician's Avatar
Logician Logician is offline
 
Join Date: Nov 2001
Location: inside vb code
Posts: 4,449
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Xenon is right.

And also IMO the most time intensive part is the SQL integration. You need an extra field in your database (probably in user table or you can make it a table on its own) and you need to code the section in USER CP and Admin CP to edit/modify this field. Adjust necessary templates etc..

It really takes time to code/debug but good idea so I hope somebody takes it on.
Reply With Quote
  #5  
Old 06-22-2002, 12:16 PM
Chris M's Avatar
Chris M Chris M is offline
 
Join Date: Dec 2001
Location: Northampton, England
Posts: 6,186
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I would have liked to, until you said SQL integration

I leave that kinda stuff to you...

I might give it a go...Im pretty busy at the moment though, getting my friend's site back and working, and my site, and other numerous bits...

Satan
Reply With Quote
  #6  
Old 06-22-2002, 12:20 PM
Admin's Avatar
Admin Admin is offline
Coder
 
Join Date: Oct 2023
Location: Server
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not the simplest hack, since censoring is done *before* the post is inserted into the database. You'll need to change that and have it censor the post (title, private messages, events, etc.) on the fly.
Reply With Quote
  #7  
Old 06-22-2002, 03:01 PM
Logician's Avatar
Logician Logician is offline
 
Join Date: Nov 2001
Location: inside vb code
Posts: 4,449
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by FireFly
since censoring is done *before* the post is inserted into the database.
Really? I havent noticed that before. IMO censoring the post before writing to db, is not the best practise. If Admin deletes a cencored word from the list, it stays cencored for all the existing posts. Probably they wanted to save the SQL query/CPU load for threadviews.
Reply With Quote
  #8  
Old 06-22-2002, 03:51 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yes it is, but as i know in pms aso its the other way round.

this is why i said it'll take really time becaus you have to change the censororder often
Reply With Quote
  #9  
Old 06-23-2002, 05:56 PM
futureal futureal is offline
 
Join Date: Feb 2002
Location: Del Mar, CA, USA
Posts: 556
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I knew that it was done beforehand, otherwise I might have tried it myself (although that probably wouldn't have been a good idea anyway!)

I also think it would be better to do the censoring on-the-fly rather than sticking it in the database, since (for reasons already mentioned) it is always nice to have a "fresh copy" of posts in case settings change in the future. Although, would there be performance issues in doing it on-the-fly? It seems like the posts are already being parsed on-the-fly for things like vBB code, smilies, etc.

If any brave soul out there is thinking about giving it a shot, and would like someone to help test it or provide feedback, I'd be glad to help.
Reply With Quote
  #10  
Old 06-23-2002, 06:31 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

postings are censored before inserted in the db, and they are also censored on the fly....

theoretically you have to got through all files and delete the censoring before inserting in db. File like private.php, newreply.php, newthread.php, editpost.php, calendar.php aso.

then when there is only an on the fly censoring, it wouldn't be a problem anymore.
If you need help with the last step i can sure help you, but i won't go throug all files to find out the lines where you have to delete the censoring
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:29 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.04647 seconds
  • Memory Usage 2,251KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete