Thread: Forum Display Enhancements - Encheferizer
View Single Post
  #43  
Old 01-01-2007, 10:52 PM
cheesegrits's Avatar
cheesegrits cheesegrits is offline
 
Join Date: May 2006
Posts: 500
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cherylferraro View Post
On my board unregistered posters are moderated. I just noticed that all of their posts have been Encheferizerized. Have I set something up incorrectly?

I had to disable the hack to get their posts to display normally...
I think I have a fix for this. It's a little hard for me to be sure, as I'm on the road and don't have access to my actual test server ... so I'm having to (very carefully!) test it on a couple of live servers.

[Edit - I just got into my test board, and this fix works for me just fine. I set guests to be moderated, posted, approved, posts show up normally.]

Could you try this. Find your "Encheferizer - main postbit", and replace the PHP with the following. There's actually only one small change, but it's easier to just copy & paste the whole thing in there:

PHP Code:
// Product: Encheferizer 1.05
// Author: Hugh Messenger (cheesegrits)

global $thread$encheferize_all_perps$encheferize_perps$chef_parser$swedish_chef$chefids$chefforumids$vuserid$chef_tag_list;

$safeScripts = array(
    
'showpost',
    
'showthread'
);

if (
in_array(THIS_SCRIPT$safeScripts) and (
        
in_array($GLOBALS['forumid'],$chefforumids) or (
            
$this->post['userid'] and (
                
in_array($this->post['userid'],$chefids) and (
                    !
$vuserid or
                    !
in_array($vuserid,$chefids) or
                    
$encheferize_all_perps or (
                        
$encheferize_perps and
                        
$this->post['userid'] == $vuserid
                    
)
                )
            )
        )
    )
)  
{
    
$this->post['title'] = $swedish_chef->encheferize(strip_bbcode($this->post['title'], true)); 
    
$cheftext $chef_parser->do_parse($swedish_chef->bb_encheferize($this->post['pagetext'],0,$chef_tag_list,$didCut),0,1,1,1,1);

Let me know if this fixes your problem, and I'll wrap this and another change up and release 1.05.

-- hugh
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01122 seconds
  • Memory Usage 1,794KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.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_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • 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
  • showpost_complete