MyBB Community Forums

Full Version: Content Encoding Error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Content Encoding Error
   
        
          The page you are trying to view cannot be shown because it uses an invalid or unsupported form of compression.

After editing index template. But I've edited my other forums index in the same way and its working fine,
URL? Test account?
URL will not work, because its on my main forum and I've reverted changes, You can see the screen shot

[Image: 335hb8w.jpg]

IMO this is cause by utf-8 conversion, but My database is UTF-8 converted!! I've double checked it
It's probably caused by a plugin. What plugins do you have installed?
(2011-09-25, 08:15 PM)Malcolm. Wrote: [ -> ]It's probably caused by a plugin. What plugins do you have installed?

Well its my own plugin :p but I've checked it on my other forum running mybb 1.6.4 and it is working fine there
Additional details, plugin is fine I've checked it on my friend's forum too and it also works there,
Is it possible that one of your boards is running on a server that supports, say, gzip, the other one isn't, and your plugin (or another plugin you were running) has something to do with the server's compression method?
Nothing, both the boards are on the same host, I've also checked it with gzip, after disabling and enabling it, but didn't work.

Here is the my plugin code, which works well all other forums, but not on my forum
<?php


if(!defined("IN_MYBB"))
{
die ("Direct initialization of this file is not allowed.<br /><br />Please make sure IN_MYBB is defined.");
}

$plugins->add_hook("index_start","test");

function test_info()
		{
return array(
		
		"name"=> "Just a test",
		"description"=> "This plugin is a test",
		"website"=> "http://www.vubscs.tk",
		"author"=> "sunjava1",
		"authorsite"=> "http://www.facebook.com/sunjava1",
		"version"=> "1.0",
			);
		}
		
function test_activate(){
global $db, $mybb;
	
	$test_group = array(
		"name" => "test",
		"title" => "Test settings",
		"description" => "Test and test .",
		"disporder" => "501",
		"isdefault" => "no",
		);
	$group['gid'] = $db->insert_query("settinggroups", $test_group);
	$gid = $db->insert_id();
	
	
	$test_set = array(
		"name" => "test_op",
		"title" => "Number of test",
		"description" => "one more test dude",
		"optionscode" => "select \n30=1 test\n20=2 test",
		"value" => "30",
		"disporder" => "1",
		"gid" => intval($gid),
		);
	$db->insert_query("settings", $test_set);
	require MYBB_ROOT."/inc/adminfunctions_templates.php";
find_replace_templatesets("index", "#".preg_quote('{$forums}')."#i", '{$forums}<br>{$test}'); 
	 	
	rebuild_settings();
}		

function test_deactivate(){
global $db;
	
	$db->query("DELETE FROM ".TABLE_PREFIX."settinggroups WHERE name='test'");
    $db->query("DELETE FROM ".TABLE_PREFIX."settings WHERE name='test_op'");
	
	
  require MYBB_ROOT."/inc/adminfunctions_templates.php";
    find_replace_templatesets("index", "#".preg_quote('{$forums}<br>{$test}')."#i", '{$forums}'); 

	// Rebuilding settings
    
	rebuild_settings();
	}

function test(){
global $test, $mybb;

if ($mybb->settings['test_op']==20)
{

$test=' You have selected  '. $mybb->settings['test_op'] .'  no of test times';	


}

else 
{

	$test='You have not selected anything, default value for test is  '. $mybb->settings['test_op'] .'  Cheers';	

}

}

?>