Home | Add News | Edit News | Options | Help/About | Logout


Enable Hack Manually - SE Friendly Links v1.3

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

				$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showcomments&amp;template=$template&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]', '_News', '$config_comments_popup_string');return false;\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  // 				$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showcomments&amp;template=$template&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]', '_News', '$config_comments_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showcomments&template=$template&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]");
$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php$QUERY', '_News', '$config_comments_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

				$output = str_replace("[com-link]","<a href=\"$PHP_SELF?subaction=showcomments&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  // 				$output = str_replace("[com-link]","<a href=\"$PHP_SELF?subaction=showcomments&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showcomments&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]&$user_query");
$output = str_replace("[com-link]", "<a href=\"$PHP_SELF$QUERY\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

        $output = str_replace("[link]","<a href=\"$PHP_SELF?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  //         $output = str_replace("[link]","<a href=\"$PHP_SELF?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showfull&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]&$user_query");
$output = str_replace("[link]","<a href=\"$PHP_SELF$QUERY\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

            	$output = preg_replace("/\\[full-link\\]/","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;template=$template', '_News', '$config_full_popup_string');return false;\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  //             	$output = preg_replace("/\\[full-link\\]/","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;template=$template', '_News', '$config_full_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showfull&id=$news_arr[0]&archive=$archive&template=$template");
$output = preg_replace("/\\[full-link\\]/","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php$QUERY', '_News', '$config_full_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

            	$output = str_replace("[full-link]","<a href=\"$PHP_SELF?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  //             	$output = str_replace("[full-link]","<a href=\"$PHP_SELF?subaction=showfull&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showfull&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]&$user_query");
$output = str_replace("[full-link]","<a href=\"$PHP_SELF$QUERY\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

			$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showcomments&amp;template=$template&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]', '_News', '$config_comments_popup_string');return false;\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  // 			$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php?subaction=showcomments&amp;template=$template&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]', '_News', '$config_comments_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showcomments&template=$template&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]");
$output = str_replace("[com-link]","<a href=\"#\" onclick=\"window.open('$config_http_script_dir/show_news.php$QUERY', '_News', '$config_comments_popup_string');return false;\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

			$output = str_replace("[com-link]","<a href=\"$PHP_SELF?subaction=showcomments&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);

With:

// SE Friendly Links v1.3 - changeblock - Old
  // 			$output = str_replace("[com-link]","<a href=\"$PHP_SELF?subaction=showcomments&amp;id=$news_arr[0]&amp;archive=$archive&amp;start_from=$my_start_from&amp;ucat=$news_arr[6]&amp;$user_query\">", $output);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("subaction=showcomments&id=$news_arr[0]&archive=$archive&start_from=$my_start_from&ucat=$news_arr[6]&$user_query");
$output = str_replace("[com-link]","<a href=\"$PHP_SELF$QUERY\">", $output);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

        $prev_next_msg = preg_replace("'\[prev-link\](.*?)\[/prev-link\]'si", "<a href=\"$PHP_SELF?start_from=$prev&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">\\1</a>", $prev_next_msg);

With:

// SE Friendly Links v1.3 - changeblock - Old
  //         $prev_next_msg = preg_replace("'\[prev-link\](.*?)\[/prev-link\]'si", "<a href=\"$PHP_SELF?start_from=$prev&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">\\1</a>", $prev_next_msg);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("start_from=$prev&archive=$url_archive&subaction=$subaction&id=$id&$user_query");
$prev_next_msg = preg_replace("'\[prev-link\](.*?)\[/prev-link\]'si", "<a href=\"$PHP_SELF$QUERY\">\\1</a>", $prev_next_msg);
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

        if($pages_start_from != $start_from){ $pages .= "<a href=\"$PHP_SELF?start_from=$pages_start_from&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">$j</a> "; }

With:

// SE Friendly Links v1.3 - changeblock - Old
  //         if($pages_start_from != $start_from){ $pages .= "<a href=\"$PHP_SELF?start_from=$pages_start_from&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">$j</a> "; }
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("start_from=$pages_start_from&archive=$url_archive&subaction=$subaction&id=$id&$user_query");
if($pages_start_from != $start_from){ $pages .= "<a href=\"$PHP_SELF$QUERY\">$j</a> "; }
// SE Friendly Links v1.3 - End changeblock

Change block in "./inc/shows.inc.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Replace this:

        $prev_next_msg = preg_replace("'\[next-link\](.*?)\[/next-link\]'si", "<a href=\"$PHP_SELF?start_from=$i&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">\\1</a>", $prev_next_msg);

With:

// SE Friendly Links v1.3 - changeblock - Old
  //         $prev_next_msg = preg_replace("'\[next-link\](.*?)\[/next-link\]'si", "<a href=\"$PHP_SELF?start_from=$i&amp;archive=$url_archive&amp;subaction=$subaction&amp;id=$id&amp;$user_query\">\\1</a>", $prev_next_msg);
// SE Friendly Links v1.3 - changeblock - New
$QUERY = convert_seo("start_from=$i&archive=$url_archive&subaction=$subaction&id=$id&$user_query");
$prev_next_msg = preg_replace("'\[next-link\](.*?)\[/next-link\]'si", "<a href=\"$PHP_SELF$QUERY\">\\1</a>", $prev_next_msg);
// SE Friendly Links v1.3 - End changeblock

Add block in "./show_news.php":

Automatically Generated, be sure to be very precise on tabs and spaces.

Add this:

// SE Friendly Links v1.3 - addblock
if ($seo_init !== true) {
  function convert_seo($QUERY) {
    $QUERY = str_replace("&amp;", "&", $QUERY);
    $result = "";
    if (preg_match_all("'([^&=]+)=([^&=]+)'", $QUERY, $matches)) {
      foreach ($matches[0] as $index => $match) {
        $result .= "/{$matches[1][$index]}/{$matches[2][$index]}";
      }
    }
    return $result;
  }

  $QUERY_STRING = @explode("&", $QUERY_STRING) or $QUERY_STRING = array();
  if ($_SERVER["PATH_INFO"] != "" ) {
    $data = explode("/", $_SERVER["PATH_INFO"]);
    reset($data);
    while (list(,$name) = each($data)) {
      if (in_array($name, array("start_from", "archive", "subaction", "id", "ucat"))) {
        each($data);
      } elseif ($name != "") {
        list(,$value) = each($data);

        $_GET[$name] = $value;
        $HTTP_GET_VARS[$name] = $value;
        $$name = $value;
        $QUERY_STRING[] = "$name=$value";
      }
    }
  }
  foreach ($QUERY_STRING as $name => $value) {
    $value = explode("=", $value);
    if ($value[0] == "" or
        $value[1] == "") {
      unset($QUERY_STRING[$name]);
    }
  }
  $QUERY_STRING = implode("&", $QUERY_STRING);
  $_SERVER["QUERY_STRING"] = $QUERY_STRING;
  $HTTP_SERVER_VARS["QUERY_STRING"] = $QUERY_STRING;

  $seo_init = true;
}
$PHP_SELF = explode(".php", $PHP_SELF);
$PHP_SELF = $PHP_SELF[0] . ".php";
// SE Friendly Links v1.3 - End addblock

Between:

error_reporting (E_ALL ^ E_NOTICE);

And:

$cutepath =  __FILE__;

End installation notes:

You won't have to configure anything, just check out your website and it should be working :)

Powered by CuteNews v1.3.1 © 2003 CutePHP.