Welcome to Geeklog, Anonymous Friday, November 29 2024 @ 08:06 am EST

Geeklog Forums

Censorship list from a text file ?


Status: offline

emagin

Forum User
Regular Poster
Registered: 08/05/03
Posts: 92
I\'m wondering how I would go about pointing the $_CONF[\'censorlist\'] = array(\'\'); to a text file. Having run a few community sites, I\'ve now got a nice loong censorlist text file which I\'d rather not retype. Plus you could use it across a multitude of sites and just keep updating the one file as nasties get in there. Any thoughts appreciated. I am storing a copy of the current censorlist here. (not for the faint of heart, but hey, it\'s a *censored* world out there) Hey, just think of what a localization effort this would be!
 Quote

Status: offline

tomw

Forum User
Full Member
Registered: 08/12/02
Posts: 300
Quote by emagin: I\'m wondering how I would go about pointing the $_CONF[\'censorlist\'] = array(\'\'); to a text file. Having run a few community sites, I\'ve now got a nice loong censorlist text file which I\'d rather not retype. Plus you could use it across a multitude of sites and just keep updating the one file as nasties get in there. Any thoughts appreciated. I am storing a copy of the current censorlist here. (not for the faint of heart, but hey, it\'s a *censored* world out there) Hey, just think of what a localization effort this would be!
That would be easy to do just add code like this to lib-custom.php: $fd=fopen(\"vulgarity.txt\"); while (!feof($fd)) { $buff=fgets($fd,4096); array_push($_CONF[\'censorlist\'],$buff); } fclose($fd); Of course it would do this every page load which would lengthen load times. TomW
 Quote

Status: offline

emagin

Forum User
Regular Poster
Registered: 08/05/03
Posts: 92
Hmm. I\'ve put vulgarity.txt into my public_html directory When I submit stories with words that should be censored, they are not. Do I also need to modify the config.php to account for this?
 Quote

All times are EST. The time is now 08:06 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content