Welcome to Geeklog, Anonymous Thursday, April 18 2024 @ 08:37 pm EDT

Geeklog Forums

Ip / icons tweaking help


Anonymous

Anonymous
I am quite a noobie in php coding but i do have some experience in porgrammin, i have 2 questions that i hoope someone could answer. 1. How can i block people from seeing my site (by showing a block html page that i prepared). I can easily find out what the ip of that person is (thx geeklog) but i need a way to block an individual or 2 from viewing my site as i don't want to get rid of anonymous posting (and disable him from signing up again) 2. I implemented chatterblock just recently i wanted to know where and how can i implement emoticons into my standard comments section. I've tried but failed lol. Thank you very much guys Geeklog is awesome!!
 Quote

Status: offline

efarmboy

Forum User
Moderator
Registered: 02/26/02
Posts: 147
I don't believe you can restrict access to the site for a range of IP's but you can enable login required to submit, access most features other then news on the front page and you can restrict access to registed users for topics. That may not be what your looking for. Adding smilie support for articles can be hacked in. The best place may be for you to hook into the COM_checkWorlds function since it's called anytime anything is posted to remove restricted works. Blaine
 Quote

Anonymous

Anonymous
okay, now bear with me... i think i did somethiing similar b4, but yeh well i tried putting it in there and correct me if i am wrong... in lib-common $EditedMessage = $Message; $EditedMessage= cb_useSmilieCode($row['msgtext']); $EditedMessage = cb_replacesmile($EditedMessage); if( $_CONF['censormode'] != 0 )...................... (assuming i leave the different lengths section out) but this totally crashed the functionality of my comments..., where should i put it and what else in terms of coding do i need?
 Quote

Anonymous

Anonymous
Oh and about the blocking thing, i didn;t want to come as far as blocking people, there is only one individual that is causing me trouble, and i support anonymous postings, and i don't want him to sign up to my site again... any idea?
 Quote

Anonymous

Anonymous
On my site the only way to get access is to submit a registration form that I approve myself. I then email the username and password to the registrant. You just disable the "new user" registration in the language file. This membership request is just a "form" on a static page. This allow me to ask for more informations as phone number, birth date, or whatever you want. You can also include the ip address on the request form but it's useless since it can be changed anytime. I'll never have more than 200 members on that site. But if you get thousands, it's another problem.
 Quote

Status: offline

efarmboy

Forum User
Moderator
Registered: 02/26/02
Posts: 147
Well, I see your using the functions for chatterblock and thats should work but I have coded the replacement of the smilie code in two steps. This was done before I decided to use a series of tables to format the display and I needed to know the exact line length and the img tags was throughing off my calculations. Thats probally TMI but I should have revisited this code and made it just one function to do the series of str_replace calls to replace the smilie code for the image.

Since these chatterblock functions are in a include file released with the plugin you need to do a have add the include to where you are trying to use the functions or they are not known.

Here is what you need to do - assuming Chatterblock Plugin is installed. Modify COM_checkHTML function in lib-common

  • Add the following line after the global statment
    Text Formatted Code
     include_once($_CONF['path_html'] . "/chatterblock/include/cb_functions.php");
  • At the end of the and before the return stmt. Add the following
    Text Formatted Code
    $str = cb_useSmilieCode($str);
    $str = cb_replacesmile($str);

    I've tested this and it works and you can now include smilies in stories and comments - asuming you are posting in HTML format.

    Enjoy,
    Blaine

  •  Quote

    Anonymous

    Anonymous
    THX alot...
     Quote

    All times are EDT. The time is now 08:37 pm.

    • 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