Vergleich admin/modules/config/mycode.php - 1.4.1 - 1.4.12

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * $Id: mycode.php 4048 2008-07-26 03:27:58Z Tikitiki $

 * $Id: mycode.php 4399 2009-07-18 15:29:20Z RyanGordon $

 */

// Disallow direct access to this file for security reasons

 */

// Disallow direct access to this file for security reasons

Zeile 21Zeile 21

if($mybb->input['action'] == "toggle_status")
{


if($mybb->input['action'] == "toggle_status")
{

 
	if(!verify_post_check($mybb->input['my_post_key']))
{
flash_message($lang->invalid_post_verify_key2, 'error');
admin_redirect("index.php?module=config/mycode");
}


	$plugins->run_hooks("admin_config_mycode_toggle_status");

$query = $db->simple_select("mycode", "*", "cid='".intval($mybb->input['cid'])."'");

	$plugins->run_hooks("admin_config_mycode_toggle_status");

$query = $db->simple_select("mycode", "*", "cid='".intval($mybb->input['cid'])."'");

Zeile 65Zeile 71
	
// Send no cache headers
header("Expires: Sat, 1 Jan 2000 01:00:00 GMT");

	
// Send no cache headers
header("Expires: Sat, 1 Jan 2000 01:00:00 GMT");

	header("Last-Modified: " . gmdate("D, d M Y H:i:s") . "GMT");

	header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");

	header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
header("Content-type: text/html");

	header("Cache-Control: no-cache, must-revalidate");
header("Pragma: no-cache");
header("Content-type: text/html");

Zeile 110Zeile 116
			$new_mycode = array(
'title' => $db->escape_string($mybb->input['title']),
'description' => $db->escape_string($mybb->input['description']),

			$new_mycode = array(
'title' => $db->escape_string($mybb->input['title']),
'description' => $db->escape_string($mybb->input['description']),

				'regex' => $db->escape_string($mybb->input['regex']),

				'regex' => $db->escape_string(str_replace("\x0", "", $mybb->input['regex'])),

				'replacement' => $db->escape_string($mybb->input['replacement']),
'active' => $db->escape_string($mybb->input['active']),
'parseorder' => intval($mybb->input['parseorder'])

				'replacement' => $db->escape_string($mybb->input['replacement']),
'active' => $db->escape_string($mybb->input['active']),
'parseorder' => intval($mybb->input['parseorder'])

Zeile 236Zeile 242
			$mycode = array(
'title' => $db->escape_string($mybb->input['title']),
'description' => $db->escape_string($mybb->input['description']),

			$mycode = array(
'title' => $db->escape_string($mybb->input['title']),
'description' => $db->escape_string($mybb->input['description']),

				'regex' => $db->escape_string($mybb->input['regex']),

				'regex' => $db->escape_string(str_replace("\x0", "", $mybb->input['regex'])),

				'replacement' => $db->escape_string($mybb->input['replacement']),
'active' => $db->escape_string($mybb->input['active']),
'parseorder' => intval($mybb->input['parseorder'])

				'replacement' => $db->escape_string($mybb->input['replacement']),
'active' => $db->escape_string($mybb->input['active']),
'parseorder' => intval($mybb->input['parseorder'])

Zeile 404Zeile 410

$popup = new PopupMenu("mycode_{$mycode['cid']}", $lang->options);
$popup->add_item($lang->edit_mycode, "index.php?module=config/mycode&action=edit&cid={$mycode['cid']}");


$popup = new PopupMenu("mycode_{$mycode['cid']}", $lang->options);
$popup->add_item($lang->edit_mycode, "index.php?module=config/mycode&action=edit&cid={$mycode['cid']}");

		$popup->add_item($phrase, "index.php?module=config/mycode&action=toggle_status&cid={$mycode['cid']}");

		$popup->add_item($phrase, "index.php?module=config/mycode&action=toggle_status&cid={$mycode['cid']}&my_post_key={$mybb->post_code}");

		$popup->add_item($lang->delete_mycode, "index.php?module=config/mycode&action=delete&cid={$mycode['cid']}&my_post_key={$mybb->post_code}", "return AdminCP.deleteConfirmation(this, '{$lang->confirm_mycode_deletion}')");
$table->construct_cell($popup->fetch(), array('class' => 'align_center'));
$table->construct_row();

		$popup->add_item($lang->delete_mycode, "index.php?module=config/mycode&action=delete&cid={$mycode['cid']}&my_post_key={$mybb->post_code}", "return AdminCP.deleteConfirmation(this, '{$lang->confirm_mycode_deletion}')");
$table->construct_cell($popup->fetch(), array('class' => 'align_center'));
$table->construct_row();

Zeile 424Zeile 430
function test_regex($regex, $replacement, $test)
{
$array = array();

function test_regex($regex, $replacement, $test)
{
$array = array();

	$array['actual'] = @preg_replace("#".$regex."#si", $replacement, $test);

	$array['actual'] = @preg_replace("#".str_replace("\x0", "", $regex)."#si", $replacement, $test);

	$array['html'] = htmlspecialchars($array['actual']);
return $array;
}

	$array['html'] = htmlspecialchars($array['actual']);
return $array;
}