Google Ziyareti

phpBB 2.0.x sürümleri için yapılmasını istediğiniz veya arayıpta bulamadığınız MODları buraya yazabilirsiniz.
Kilitli
Kullanıcı avatarı
by-keskin
Kayıtlı Kullanıcı
Mesajlar: 425
Kayıt: 10.10.2006, 21:09
İletişim:

Google Ziyareti

Mesaj gönderen by-keskin »

Arkadaslar plustaki gibi google .... kere ziyaret etti modunu isteyebilirmiyim ?
Kullanıcı avatarı
Mirach
Destek Ekibi Lideri
Destek Ekibi Lideri
Mesajlar: 1664
Kayıt: 27.03.2006, 01:06
Konum: İstanbul

Mesaj gönderen Mirach »

sitede mevcut , arama yapınız.
Profilinde phpBB forumunun adresini girmemiş üyelere ve kurallara aykırı şekilde açılmış başlıklara destek verilmez.
Resim Resim Resim
ckr
Kayıtlı Kullanıcı
Mesajlar: 125
Kayıt: 22.12.2006, 20:44
Konum: Ew
İletişim:

Mesaj gönderen ckr »

Download :http://www.phpbbservice.nl/ownmods/botsmodv1.3.1.rar

Kod: Tümünü seç

##############################################################
## MOD Title: Bot Indexing Mod 1.3.1
## MOD Author:  Raimon <Raimon@phpBBservice.nl> htp://phpBBservice.nl
## MOD Author: addit     <N/A> (N/A)N/A
## MOD Description: Show search engine spiders by name instead of as guest in the admin cp in who's online.
##    Show bots in who's online on forum index and on viewforum pages.
##    Bots can index your forums as SIDs are removed.
##    To clarify, this mod allows your site to be indexed by removing SIDs,
##    however it does not by default optimise your site to be indexed.
##    It does however log bot visits and allow you to create custom made styles for certain bots.
##
## MOD Version: 1.3.1
##
## Installation Level: (Easy)
## Installation Time: 20 Minutes
##
## Files To Edit:8
## templates/subSilver/admin/index_body.tpl,
## includes/sessions.php,
## viewonline.php,
## includes/page_header.php,
## common.php,
## admin/index.php,
## includes/constants.php,
## includes/functions.php
##
## Included Files: 6
##
## admin/admin_bots.php,
## language/lang_english/lang_bot_admin.php,
## templates/subSilver/admin/bots_add_body.tpl,
## templates/subSilver/admin/bots_added.tpl,
## templates/subSilver/admin/bots_body.tpl,
## bot_install.php
##
##
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2
##############################################################
## For security purposes, please check: http://www.phpbb.com/mods/
## for the latest version of this MOD. Although MODs are checked
## before being allowed in the MODs Database there is no guarantee
## that there are no security problems within the MOD. No support
## will be given for MODs not found within the MODs Database which
## can be found at http://www.phpbb.com/mods/
##############################################################
## Author Notes:
##
## MOD only tested on phpBB version 2.0.21
## This MOD is compatible with Extreme Styles MOD as well as the standard phpbb2 template system.
## This MOD was originally written by Adam Marcus, with his permission I've taken over the project. After
## installation you should be left with a page in the admin panel called "Manage Bots".
##
##
##             To install:
##
## 0) If you have installed any previous BOT related mods please uninstall them as it
## may hinder this mod!!!
##
## 1) First copy all the files from this zip (with the exception of this file
## "INSTALL.txt and UPDATE.txt") to the root directory of your phpBB install.
##
## 2) This MOD version already contains the code changes in the UPDATE to 1.3.0 so you don't need to make the code changes in UPDATE.txt,
## all you need is this file, INSTALL.txt.
##
## 3) Run "bot_install.php" - so for example in your web browser type:
## www.yourdomain.com/yourphpbbinstall/bot_install.php
##
## 4) Follow the instructions and type in the required data, if any.
##
## 5) Delete "bot_install.php" from your server. This is just a security measure.
##
## 6) Lastly follow the MOD below to adjust your other core phpbb files.
##
## 7) The mod should be fully operational, enjoy your forum being indexed!
##
##
##############################################################
## MOD History:
##
##   2006-06-05 - Version 1.3.1
##     -Smal fixes added for to prevent many the same bots show online
##     - Putting more ips on the input field to prevent that the field is full
##
##  2006 19-11  Version 1.3.0
##     - Project taking over by Raimon (Raimon)
##
##   2006-06-05 - Version 1.3.0
##     -Project took over by Chris Russell (chris3471)
##     -Since the original MOD Author didn't use the MOD Template I don't have the complete history,
##      MOD was at version 1.2.0 at the time I assumed the project.
##
##       -Added Features
##       -Show search engine spiders by name instead of as guest in the admin cp in who's online.
##       -Show bots in who's online on forum index and on viewforum pages.
##
##      -Fixed 3 bugs
##      - Adding your own details as a bot will consquently lock you out from the admin panel.
##      - Made it so you can't enter your own Ip.
##      - Not really a bug -Increased IP input string length to 1000 characters so more IPs can be entered at once
##
##      - Two bots can be given the same bot name.
##        - Added an error checking rutine to verify that a bot name doesn't already exist.
##
##  2004-06-01
##      - Initial Release Version 1.0.0
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#

#
#-----[ COPY ]------------------------------------------
#

copy admin/admin_bots.php to admin/admin_bots.php
copy language/lang_english/lang_bot_admin.php to language/lang_english/lang_bot_admin.php
copy templates/subSilver/admin/bots_add_body.tpl to templates/subSilver/admin/bots_add_body.tpl
copy templates/subSilver/admin/bots_added.tpl to templates/subSilver/admin/bots_added.tpl
copy templates/subSilver/admin/bots_body.tpl to templates/subSilver/admin/bots_body.tpl
copy bot_install.php to bot_install.php

#
#-----[ OPEN ]------------------------------------------
#

templates/subSilver/admin/index_body.tpl


#
#-----[ FIND ]------------------------------------------
#

<!-- BEGIN guest_user_row -->

#
#-----[ BEFORE, ADD ]------------------------------------------
#

<!-- BEGIN spider_user_row -->
  <tr>
  <td width="20%" class="{spider_user_row.ROW_CLASS}">&nbsp;<span class="gen">{spider_user_row.USERNAME}</span>&nbsp;</td>
  <td width="20%" align="center" class="{spider_user_row.ROW_CLASS}">&nbsp;<span class="gen">{spider_user_row.STARTED}</span>&nbsp;</td>
  <td width="20%" align="center" nowrap="nowrap" class="{spider_user_row.ROW_CLASS}">&nbsp;<span class="gen">{spider_user_row.LASTUPDATE}</span>&nbsp;</td>
  <td width="20%" class="{spider_user_row.ROW_CLASS}">&nbsp;<span class="gen"><a href="{spider_user_row.U_FORUM_LOCATION}" class="gen">{spider_user_row.FORUM_LOCATION}</a></span>&nbsp;</td>
  <td width="20%" class="{spider_user_row.ROW_CLASS}">&nbsp;<span class="gen"><a href="{spider_user_row.U_WHOIS_IP}" target="_phpbbwhois">{spider_user_row.IP_ADDRESS}</a></span>&nbsp;</td>
  </tr>
  <!-- END spider_user_row -->
  <tr>
  <td colspan="5" height="1" class="row3"><img src="../../../../phpBB2/templates/subSilver/templates/subSilver/images/spacer.gif" width="1" height="1" alt="."></td>
  </tr>


#
#-----[ OPEN ]------------------------------------------
#

includes/sessions.php



#
#-----[ FIND ]------------------------------------------
#

//
  // Create or update the session
  //

#
#-----[ BEFORE, ADD ]------------------------------------------
#
  $robot = ( ( defined('IS_ROBOT') ) ? IS_ROBOT : 0 );


#
#-----[ FIND ]------------------------------------------
#

$sql = "UPDATE " . SESSIONS_TABLE . "
    SET session_user_id = $user_id, session_start = $current_time, session_time = $current_time, session_page = $page_id, session_logged_in = $login, session_admin = $admin
    WHERE session_id = '" . $session_id . "'
      AND session_ip = '$user_ip'";


#
#-----[ IN-LINE FIND ]------------------------------------------
#

session_page = $page_id, session_logged_in = $login


#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#

, is_robot = '$robot'

#
#-----[ FIND ]------------------------------------------
#

$sql = "INSERT INTO " . SESSIONS_TABLE . "
      (session_id, session_user_id, session_start, session_time, session_ip, session_page, session_logged_in, session_admin)


#
#-----[ IN-LINE FIND ]------------------------------------------
#

session_page, session_logged_in

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#

, is_robot

#
#-----[ FIND ]------------------------------------------
#


VALUES ('$session_id', $user_id, $current_time, $current_time, '$user_ip', $page_id, $login, $admin)";



#
#-----[ IN-LINE FIND ]------------------------------------------
#

'$user_ip', $page_id, $login

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#

, '$robot'

#
#-----[ FIND ]------------------------------------------
#

global $SID;

if ( !empty($SID) && !preg_match('#sid=#', $url) )

#
#-----[ REPLACE WITH ]------------------------------------------
#

global $SID;

if ( !empty($SID) && !preg_match('#sid=#', $url) && !IS_ROBOT )

#
#-----[ OPEN ]------------------------------------------
#

viewonline.php

#
#-----[ FIND ]------------------------------------------
#

$sql = "SELECT u.user_id, u.username, u.user_allow_viewonline, u.user_level, s.session_logged_in, s.session_time, s.session_page, s.session_ip
  FROM ".USERS_TABLE." u, ".SESSIONS_TABLE." s
  WHERE u.user_id = s.session_user_id
    AND s.session_time >= ".( time() - 300 ) . "
  ORDER BY u.username ASC, s.session_ip ASC";

#
#-----[ IN-LINE FIND ]------------------------------------------
#

s.session_page, s.session_ip

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#

, s.is_robot

#
#-----[ FIND ]------------------------------------------
#
      $username = $lang['Guest'];
#
#-----[ REPLACE WITH ]------------------------------------------
#
      if($row['is_robot'])
      {
        $username = $row['is_robot'] . ' ( Bots )';
      } else {
        $username = $lang['Guest'];
      }
#
#-----[ OPEN ]------------------------------------------
#

includes/page_header.php



#
#-----[ FIND ]------------------------------------------
#

$sql = "SELECT u.username, u.user_id, u.user_allow_viewonline, u.user_level, s.session_logged_in, s.session_ip
    FROM ".USERS_TABLE." u, ".SESSIONS_TABLE." s
    WHERE u.user_id = s.session_user_id
      AND s.session_time >= ".( time() - 300 ) . "
      $user_forum_sql
    ORDER BY u.username ASC, s.session_ip ASC";


#
#-----[ IN-LINE FIND ]------------------------------------------
#

s.session_logged_in, s.session_ip

#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#

, s.is_robot

#
#-----[ FIND ]------------------------------------------
#


$userlist_ary = array();
  $userlist_visible = array();

  $prev_user_id = 0;
  $prev_user_ip = $prev_session_ip = '';

#
#-----[ AFTER, ADD ]------------------------------------------
#

$prev_is_robot = '';

#
#-----[ FIND ]------------------------------------------
#
        $guests_online++;
      }
    }

    $prev_session_ip = $row['session_ip'];

#
#-----[ REPLACE WITH ]------------------------------------------
#

                             $guests_online++;

        if (($row['is_robot'] != '0') && ($row['is_robot'] != $prev_is_robot))
        {



              if ( strpos ($online_userlist,$row['is_robot']) == FALSE )
   {
     $row['is_robot'] = '<span style="color:#' . $theme['body_link'] . '"><b>' . $row['is_robot'] . '</b></span>';
     $online_userlist = $row['is_robot'] . (($online_userlist!='') ? ', ' : '') . $online_userlist;
   }

          }

      }

    }
        $prev_is_robot = $row['is_robot'];
       $prev_session_ip = $row['session_ip'];


#
#-----[ OPEN ]------------------------------------------
#

common.php

#
#-----[ FIND ]------------------------------------------
#

?>

#
#-----[ BEFORE, ADD ]------------------------------------------
#

define('IS_ROBOT', is_robot() );


#
#-----[ OPEN ]------------------------------------------
#

admin/index.php

#
#-----[ FIND ]------------------------------------------
#

$sql = "SELECT session_page, session_logged_in, session_time, session_ip, session_start
    FROM " . SESSIONS_TABLE . "
    WHERE session_logged_in = 0

#
#-----[ AFTER, ADD ]------------------------------------------
#

AND is_robot = '0'


#
#-----[ FIND ]------------------------------------------
#

$onlinerow_guest = $db->sql_fetchrowset($result);

#
#-----[ AFTER, ADD ]------------------------------------------
#


$sql = "SELECT session_page, session_logged_in, session_time, session_ip, session_start, is_robot
    FROM " . SESSIONS_TABLE . "
    WHERE session_logged_in = 0
    AND is_robot !='0'
      AND session_time >= " . ( time() - 300 ) . "
    ORDER BY session_time DESC";
  if(!$result = $db->sql_query($sql))
  {
    message_die(GENERAL_ERROR, "Couldn't obtain spiders online information.", "", __LINE__, __FILE__, $sql);
  }
  $onlinerow_spider = $db->sql_fetchrowset($result);


#
#-----[ FIND ]------------------------------------------
#


else
  {
    $template->assign_vars(array(
      "L_NO_GUESTS_BROWSING" => $lang['No_users_browsing'])
    );
  }


#
#-----[ AFTER, ADD ]------------------------------------------
#


        //
  // search engine spiders
  //

if ( count($onlinerow_spider) )
  {

    $spider_users = 0;

    for($i = 0; $i < count($onlinerow_spider); $i++)
    {
      $spider_userip_ary[] = $onlinerow_spider[$i]['session_ip'];
      $spider_users++;

      if( $onlinerow_spider[$i]['session_page'] < 1 )
      {
        switch( $onlinerow_spider[$i]['session_page'] )
        {
          case PAGE_INDEX:
            $location = $lang['Forum_index'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_POSTING:
            $location = $lang['Posting_message'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_LOGIN:
            $location = $lang['Logging_on'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_SEARCH:
            $location = $lang['Searching_forums'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_PROFILE:
            $location = $lang['Viewing_profile'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_VIEWONLINE:
            $location = $lang['Viewing_online'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_VIEWMEMBERS:
            $location = $lang['Viewing_member_list'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_PRIVMSGS:
            $location = $lang['Viewing_priv_msgs'];
            $location_url = "index.$phpEx?pane=right";
            break;
          case PAGE_FAQ:
            $location = $lang['Viewing_FAQ'];
            $location_url = "index.$phpEx?pane=right";
            break;
          default:
            $location = $lang['Forum_index'];
            $location_url = "index.$phpEx?pane=right";
        }
      }
      else
      {
        $location_url = append_sid("admin_forums.$phpEx?mode=editforum&" . POST_FORUM_URL . "=" . $onlinerow_spider[$i]['session_page']);
        $location = $forum_data[$onlinerow_spider[$i]['session_page']];
      }

      $row_color = ( $spider_users % 2 ) ? $theme['td_color1'] : $theme['td_color2'];
      $row_class = ( $spider_users % 2 ) ? $theme['td_class1'] : $theme['td_class2'];

      $spider_ip = decode_ip($onlinerow_spider[$i]['session_ip']);

      $template->assign_block_vars("spider_user_row", array(
        "ROW_COLOR" => "#" . $row_color,
        "ROW_CLASS" => $row_class,
        "USERNAME" => $onlinerow_spider[$i]['is_robot'],
        "STARTED" => create_date($board_config['default_dateformat'], $onlinerow_spider[$i]['session_start'], $board_config['board_timezone']),
        "LASTUPDATE" => create_date($board_config['default_dateformat'], $onlinerow_spider[$i]['session_time'], $board_config['board_timezone']),
        "FORUM_LOCATION" => $location,
        "IP_ADDRESS" => $spider_ip,

        "U_WHOIS_IP" => "http://network-tools.com/default.asp?host=$spider_ip",
        "U_FORUM_LOCATION" => append_sid($location_url))
      );
    }

  }
  else
  {
    $template->assign_vars(array(
      "L_NO_Spiders_BROWSING" => $lang['No_users_browsing'])
    );
  }

#
#-----[ OPEN ]------------------------------------------
#

includes/constants.php

#
#-----[ FIND ]------------------------------------------
#

?>

#
#-----[ BEFORE, ADD ]------------------------------------------
#

define('BOTS_TABLE', $table_prefix . "bots");

#
#-----[ OPEN ]------------------------------------------
#



includes/functions.php

#
#-----[ FIND ]------------------------------------------
#

  global $board_config, $theme, $images;

#
#-----[ REPLACE WITH ]------------------------------------------
#
  global $board_config, $theme, $images, $db, $table_prefix;

#
#-----[ FIND ]------------------------------------------
#
  $theme = setup_style($board_config['default_style']);

#
#-----[ REPLACE WITH ]------------------------------------------
#
  if (IS_ROBOT)
  {
    $sql = "SELECT bot_style FROM " . $table_prefix . "bots WHERE bot_name='" . IS_ROBOT . "'";
    $result = $db->sql_query($sql);
    $row = $db->sql_fetchrow($result);
    $theme = setup_style($row['bot_style']);
  } else {
    $theme = setup_style($board_config['default_style']);
  }

#
#-----[ FIND ]------------------------------------------
#

?>

#
#-----[ BEFORE, ADD ]------------------------------------------
#

//
// Part of bot MOD: This function checks whether the user agent or ip is
// listed as a bot and returns true otherwise false.
//

function is_robot()
{
  global $db, $HTTP_SERVER_VARS, $table_prefix;


  // get required user data
  $user_ip = $HTTP_SERVER_VARS['REMOTE_ADDR'];
  $user_agent = $HTTP_SERVER_VARS['HTTP_USER_AGENT'];

  // get bot table data
  $sql = "SELECT bot_agent, bot_ip, bot_id, bot_visits, last_visit, bot_pages, bot_name
  FROM " . BOTS_TABLE;

  if ( !($result = $db->sql_query($sql)) )
  {
    message_die(GENERAL_ERROR, 'Could not obtain bot data.', '', __LINE__, __FILE__, $sql);
  }

  // loop through bots table
  while ($row = $db->sql_fetchrow($result))
  {
    // clear vars
    $agent_match = 0;
    $ip_match = 0;

    // check for user agent match
    foreach (explode('|', $row['bot_agent']) as $bot_agent)
    {
      if ($row['bot_agent'] && $bot_agent != '' && preg_match('#' . preg_quote($bot_agent, '#') . '#i', $user_agent)) $agent_match = 1;
    }

    // check for ip match
    foreach (explode('|', $row['bot_ip']) as $bot_ip)
    {
      if ($row['bot_ip'] && $bot_ip != '' && strpos($user_ip, $bot_ip) === 0)
      {
        $ip_match = 1;
        break;
      }
    }

    // if both ip and agent matched update table and return true
    if ($agent_match == 1 && $ip_match == 1)
    {
      // get time - seconds from epoch
      $today = time();

      $last_visits = explode('|', $row['last_visit']);

      // if half an hour has passed since last visit
      if (($today - (($last_visits[0] == '') ? 0 : $last_visits[0])) > 2700)
      {
        for ($i = ((4 > sizeof($last_visits)) ? sizeof($last_visits) : 4); $i >= 0; $i--)
        {
          if ($last_visits[$i-1] != '') $last_visits[$i] = $last_visits[$i-1];
        }

        // increment the new visit counter
        $row['bot_visits']++;

        // clear prior indexed pages
        $row['bot_pages'] = 1;
      } else {
        // add to indexed pages
        $row['bot_pages']++;
      }

      $last_visits[0] = $today;

      // compress it all together
      $last_visit = implode("|", $last_visits);

      // update table
      $sql = "UPDATE " . BOTS_TABLE . "
      SET last_visit='$last_visit', bot_visits='" . $row['bot_visits'] . "', bot_pages='" . $row['bot_pages'] . "'
      WHERE bot_id = " . $row['bot_id'];

      if ( !($result2 = $db->sql_query($sql)) )
      {
        message_die(GENERAL_ERROR, 'Couldn\'t update data in bots table.', '', __LINE__, __FILE__, $sql);
      }

      return $row['bot_name'];

    }
    else
    {
      if ($agent_match == 1 || $ip_match == 1)

      {

        // get data from table
        $sql = "SELECT pending_" . ((!$agent_match) ? 'agent' : 'ip') . "
        FROM " . BOTS_TABLE . "
        WHERE bot_id = " . $row['bot_id'];

        if ( !($result2 = $db->sql_query($sql)) )
        {
          message_die(GENERAL_ERROR, 'Could not obtain bot data.', '', __LINE__, __FILE__, $sql);
        }

        $row2 = $db->sql_fetchrow($result2);

        // add ip/agent to the list
        $pending_array = (( $row2['pending_' . ((!$agent_match) ? 'agent' : 'ip')] ) ? explode('|', $row2['pending_' . ((!$agent_match) ? 'agent' :  'ip')]) : array());

        $found = 0;

        if ( sizeof($pending_array) )
        {
          for ($loop = 0; $loop < count($pending_array); $loop+=2)
          {
            if ($pending_array[$loop] == ((!$agent_match) ? $user_agent : $user_ip)) $found = 1;
          }
        }

        if ($found == 0)
        {
          $pending_array[] = ((!$agent_match) ? str_replace("|", "|", $user_agent) : $user_ip);
          $pending_array[] = ((!$agent_match) ? $user_ip : str_replace("|", "|", $user_agent));
        }
        $pending = implode("|", $pending_array);

        // update table
        $sql = "UPDATE " . BOTS_TABLE . "
        SET pending_" . ((!$agent_match) ? 'agent' : 'ip') . "='$pending'
        WHERE bot_id = " . $row['bot_id'];

        if ( !($result2 = $db->sql_query($sql)) )
        {
          message_die(GENERAL_ERROR, 'Couldn\'t update data in bots table.', '', __LINE__, __FILE__, $sql);
        }
      }
    }

  }

  return 0;
}

#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
I'm Offline
Kullanıcı avatarı
Kartal23
Kayıtlı Kullanıcı
Mesajlar: 384
Kayıt: 31.10.2006, 23:58
Konum: İstanbul
İletişim:

Mesaj gönderen Kartal23 »

Google ziyareti ne işe yarıyor arkadaşlar? Benim de 1 hafta da ziyaret bölümü 1.300' e yükseldi..
http://www.boraboy.net

Türkçe' ye Sahip Çık;
Yok Olmasına İzin Verme.
Kilitli

“2.0.x MOD İstekleri” sayfasına dön

Kimler çevrimiçi

Bu forumu görüntüleyen kullanıcılar: Hiç bir kayıtlı kullanıcı yok ve 4 misafir