05 Temmuz 2009, 23:06:31
Mustafa Kemal Atatürk -Adanalı Dizisi -KVP Bölümleri -KVP Müzikleri -Full Programlar -Albümler -Online Dizi İzle -Online Film İzle
Dizi Müzikleri -Dizi Özetleri & Fragmanları -Diziler -Filmler -SW Aktiviteleri -Şiirler -Tiny Portal -Full Oyun Download

Saygı değer Üyelerimiz sitemiz bir forum sitesi olduğu için kullanıcılar her türlü görüşlerini önceden onay olmadan anında siteye yazabilmektedir, bu yazılardan dolayı doğabilecek her türlü sorumluluk yazan kullanıcılara aittir. T.C. Kanunlarına aykırı olan MP3,Warez,Crack,Flim V.b. ürünlerin sitemizde paylaşımı Kesin olarak Yasaktır. Kurallara uymayan üyeler sitemizden uzaklaştırılır ve gerektiğinde yasal kurumlarda kullanılmak üzere IP (Internet Kimlik Numarası)adresi verilecektir.

Sayfa: [1]   Aşağı git
Yazdır
Gönderen Konu: Guest Page View Limit (tp bloc)  (Okunma Sayısı 679 defa)
alp
Admin
******

Rep 144
Çevrimdışı Çevrimdışı

Mesaj Sayısı: 8,455



WWW
« : 28 Ekim 2007, 14:46:14 »

ziyaretçilerin sayfa gösterim limiti (Guest Page View Limit ()
bu blok ziyaretçilerin 3 konu ya baktıktan sonra otomatik olarak kayıt sayfasına açıyor.diğer sayfalara geçisi engelliyor.
*************
php bloc oluşturup kodu kopyalayın

Kod:
//////////////////////////////////////////////
// Guest Page View Limit 1.2
//////////////////////////////////////////////
// Developed by TPH Thurnok
// TinyPortal Hosting - Your premier TP/SMF host
// http://www.tinyportalhosting.com
// November 16, 2006
//
// Last update: March 10, 2007
//    added &gpvl=exceeded to redirect so scripting can be done in registration
//    to allow detecting user got there by exceeding the page view limit
//
// This is designed for a phpblock.
// This allows you to limit the number of pages a guest can view on your site
// before being redirected to the registration page.
//
// Requirements:
// In order for this to work, you must place this in a phpblock that is displayed
// on all pages.  For any pages where this block is not displayed, that page will
// not be counted against the guest.  It is recommended you do not display a title
// or frame for the block so that it is basically invisible to the user.
//
// This script will create a table for the storage of IPs and the count of pages.
// It is a very simple IP based count.  No session info or other info is used.
// Therefore, if you set this to a very high value, and a user has a dynamic IP, you
// may be ineffective as the user may simply get a new IP the next time they visit your site.
//
//////////////////////////////////////////////

/*
****************************************
****************************************
*** !! User Configuration Section !! ***
****************************************
****************************************
*/
// Set the maximum number of pages you want to limit a normal guest to view
$gpvl_MaxPages = 3;
// Set the maximum number of pages to limit "special" guests to (usually for high limit guests)
$gpvl_MaxPagesSpecial = 1000;

// Set the IPs for "special" guests in an array - Example: array('12.1.4.70', '3.88.129.211', '42.150.220.200');
$gpvl_SpecialIPs = array();

// Set the IPs you want excluded from the limit - like google/spiders etc. in an array - same format as "special" guest array
$gpvl_ExcludeIPs = array('127.0.0.1');

// set the table name you want to use (without a prefix - prefix will be auto added)
$gpvl_table = 'guest_page_limit';
/*
****************************************
****************************************
*/

//////////////////////////////////////////////
//
// The rest of this you should leave as is
// unless you are overly industrious :)
//
//////////////////////////////////////////////
// globals for database vars
global $db_prefix, $tp_prefix;
// globals for user information
global $context, $scripturl;

// fix for TP 0.8.6 and lower
if (empty($tp_prefix)){
$tp_prefix = $settings['tp_prefix'];
}
$gpvl_table = $tp_prefix . $gpvl_table;

$myself = $_SERVER['REQUEST_URL'];
// first seperate the parameters from the URL, to avoid possible search string in the URL itself
$parms = str_replace($scripturl, "", $myself);
// then see if we are actually at the registration page (action=register)
$gpvl_at_register = stristr($parms, "action=register") ? true : false;
// or if we are at the login page (action=login)
$gpvl_at_login = stristr($parms, "action=login") ? true : false;
// or if we are at the password reminder page (action=reminder)
$gpvl_at_reminder = stristr($parms, "action=reminder") ? true : false;

// only for limiting guests, so if not a guest - get out (unless at registration/login/reminder page)
if ($context['user']['is_guest'] && !$gpvl_at_register && !$gpvl_at_login && !$gpvl_at_reminder){
// preset to max pages in case we fall thru
$gpvl_NumPages = $gpvl_MaxPages;

// what is our IP?
$gpvl_ip = empty($_SERVER['REMOTE_ADDR']) ? getenv('REMOTE_ADDR') : $_SERVER['REMOTE_ADDR'];
// if we got an IP (and it is not an excluded IP), do the work, otherwise, send them to registration
if ($gpvl_ip && strtoupper($gpvl_ip) != "NULL"){
if (in_array($gpvl_ip, $gpvl_ExcludeIPs)){
$gpvl_NumPages = 0;
} else {
// if they are a "special" guest, set their max pages to the "special" max pages setting
if (in_array($gpvl_ip, $gpvl_SpecialIPs)){
$gpvl_MaxPages = $gpvl_MaxPagesSpecial;
}
// test for table existance
$gpvl_result = @mysql_query('SELECT pageviews FROM '.$gpvl_table.' WHERE ip = "'.$gpvl_ip.'" LIMIT 1');
if (!$gpvl_result){
if (mysql_errno() == 1146){
// table doesn't exist, create it!
@mysql_query('CREATE table '.$gpvl_table.'(ip TEXT, pageviews INT UNSIGNED NOT NULL)');
$gpvl_NumPages = 1;
@mysql_query('INSERT INTO '.$gpvl_table.' VALUES ("'.$gpvl_ip.'", 1)');
} else {
die("Guest Page View Limit - Unexpected error: " . mysql_error());
}
} else {
if (mysql_num_rows($gpvl_result)){
// found this IP already in table
$row = mysql_fetch_assoc($gpvl_result);
$gpvl_NumPages = $row['pageviews'] + 1;
@mysql_query('UPDATE '.$gpvl_table.' SET pageviews = '.$gpvl_NumPages.' WHERE ip = "'.$gpvl_ip.'"');
} else {
// not in table yet, insert it
$gpvl_NumPages = 1;
@mysql_query('INSERT INTO '.$gpvl_table.' VALUES ("'.$gpvl_ip.'", 1)');
}
mysql_free_result($gpvl_result);
}
}
}

// Send to registration if they are at or above max pages
if ($gpvl_NumPages > 0 && $gpvl_NumPages >= $gpvl_MaxPages){
header("Location: ".$scripturl."?action=register&gpvl=exceeded");
}
}


$gpvl_MaxPages = 3;
3 istediğiniz gibi değiştirin siz
« Son Düzenleme: 28 Ekim 2007, 14:48:31 Gönderen: alp » Logged

Robot Moderatör
Anahtar Kelime
*****
Offline Pasif

Mesajlar: 42,063


View Profile
Re: Guest Page View Limit (tp bloc)
« Posted on: 05 Temmuz 2009, 23:06:31 »

 
      uyari
Merhaba ziyaretçi. Öncelikle sitemize hoşgeldiniz. Ben robot moderatör olrak siteden daha fazla yararlanmanız için sitemize üye olmanızı öneririm. iyi eğlenceler.

giris  kayit
Anahtar Kelimeler: Guest Page View Limit (tp bloc) oyunları, Guest Page View Limit (tp bloc) programı, Guest Page View Limit (tp bloc) oyunu indir, Guest Page View Limit (tp bloc) program yükle, Guest Page View Limit (tp bloc) download, Guest Page View Limit (tp bloc) hikayeleri, Guest Page View Limit (tp bloc) resimleri, Guest Page View Limit (tp bloc) haber, Guest Page View Limit (tp bloc) yükle, Guest Page View Limit (tp bloc) videosu, Guest Page View Limit (tp bloc)albüm indir,maçının golleri,seyret,dinle,izle,online izle bedava ödev indir msn eklentisi, şarkı sözleri,kurtlarvadisi,mp3,dizi,şarkı,indir,download, avatar, internet, Öss, Eğitim, Kpss, Üniversite, Lost, Dizi, Kurtlar Vadisi, Avrupa Yakası, Heroes, DVD, Program Download, Windows Xp, Vista, Donanım, Film, Sinema
Logged
aliercan
Yeni Üye
*

Rep 0
Çevrimdışı Çevrimdışı

Mesaj Sayısı: 6

Avatar Yok


« Yanıtla #1 : 06 Şubat 2008, 23:47:49 »

cok güzel bişey ya teşekkürler
Logged
sarıyerli laz
Hamza Sirkeci
Genel Koordinator
*****

Rep 4144
Çevrimdışı Çevrimdışı

Mesaj Sayısı: 4,135



« Yanıtla #2 : 06 Şubat 2008, 23:56:00 »

teşekkürler...
Logged
ScoRPioN35
Acemi Üye
*

Rep 0
Çevrimdışı Çevrimdışı

Mesaj Sayısı: 18

Avatar Yok


« Yanıtla #3 : 29 Mart 2008, 07:42:41 »

Bunu ekledım hatta degerını 10 yaptım hanı 10 konuya baksınlar dıye ama daha 1 konuya bıle gırmeden dırek kayıt yerıne yönlenıyor nerde yanlıslık var   Huh?
Logged
alp
Admin
******

Rep 144
Çevrimdışı Çevrimdışı

Mesaj Sayısı: 8,455



WWW
« Yanıtla #4 : 29 Mart 2008, 13:01:45 »

Bunu ekledım hatta degerını 10 yaptım hanı 10 konuya baksınlar dıye ama daha 1 konuya bıle gırmeden dırek kayıt yerıne yönlenıyor nerde yanlıslık var   Huh?
site içerisinde eğer sayfa yenilemesi yaptıysa onuda sayıyor bu kodu kullanmanı önermiyorum çünkü google indexleyemez siteni
Logged

Sayfa: [1]   Yukarı git
Yazdır
Sanalworld-Anahtar kelimelerGuest Page View Limit (tp bloc)Yeni albümler indir dinle,mp3 indir dinle,oyunlar dizi özetleri fragmanları,haber,yükle,filmi indir izle,online izle,bölüm online dizi izle,kurtlar vadisi pusu yeni bölüm fragmanı indir izle müzikleri,dizi müzikleri ,indir,download,adanalı dizisi,albümü indir,şarkıcı,yemek tarifleri,bedava ödev,ünlü resimleri,görüntüleri fotoğrafları,maçın golleri özetleri,Paylaşım, knight online, garip olaylar, galatasaray, Guest Page View Limit (tp bloc)fenerbahçe, beşiktaş, Film, Dizi, Müzik, Program, Oyun, Download, Dostluk, Sinema, Video, Eğlence, Komik, Mühendislik, Eğitim, Kadın, Siyaset, Resim, Cep, Bilgisayar, Kültür, Sanat, Tarih, Edebiyat, Turizm, Spor Guest Page View Limit (tp bloc)
Gitmek istediğiniz yer:  



TinyPortal v.1.0.6 beta 2 © Bloc
|Sitemap 1| 2| 3| 4| 5| 6| Wap| Wap 2| XML| Arşiv| Arşiv 2|index|Rss| Web Stats