Register Arama Bugünkü Mesajlar Tüm Forumu Okundu Say

Reply
 
Thread Tools
3 methods for enabling debug mode for site admin ONLY
vB.Org Poster
vB.Org Poster has disabled reputation
Kayıt Tarihi: Jul 2018
Mesajlar: 298

Show Printable Version Email this Page
yazan vB.Org Poster 10 Jul 2018, 16:24

We will explain here how to turn on debug mode for LIVE vbulletin website for site admin only.


We all know that we can enable debug mode by add this line to /include/config.php


Kod Blok Kilitli:      (Kayıt veya giriş yapmalısın)  
Engellenmiş, kayıtlı olmayan veya onay bekleyen kişiler kodlara erişemezler.



but .. this will enable debug mode for everyone else .. not just the admin. even if you close your forum, the debug mode still running and showing critical information about your site). This is good only on your private forum on your test server.

why this happen ?? why vbulletin team does not enable debug mode for the admins only ??? I am sure that's because the debug functions must run (before) the forum know that (this visitor is admin!) i.e. before pulling user information from db and checking his user group id/permissions.

so.. what we can do to enable the debug mode for webmaster only ?


Method (1)-By using (Secret Query String):


below the last line in your config.php add this


Kod Blok Kilitli:      (Kayıt veya giriş yapmalısın)  
Engellenmiş, kayıtlı olmayan veya onay bekleyen kişiler kodlara erişemezler.


remember to change your secret debug mode number (i.e. $debug_mode_secret_query variable value)
save & upload config.php

now .. if you want to see your live site in debug mode .. add the query string to any page url in your forum.

Examples:


Kod Blok Kilitli:      (Kayıt veya giriş yapmalısın)  
Engellenmiş, kayıtlı olmayan veya onay bekleyen kişiler kodlara erişemezler.



Advantages:
1- You can turn on the debug mode of your forum from any place, IP or browser.
2- Turn debug mode on only if you want (not every time you open your forum pages)
Disadvantages:
1- You need to add the query string part manually each time you visit new page.
2- Spiders or Alexa may catch that URL with that query string if you have installed a spyware toolbar like alexa, page rank, etc (really ?)






Method (2)-By Adding secret Custom HTTP Request header to your browser:




Firstly, add a custom header to your browser. The best and easiest way to do that is to install (Modify Headers firefox Add-on by Gareth Hunt ) for your firefox, then add your custom request header via its option

Header name: debug
header value: 3003 (change this value to your own secret value)
Always ON the add-on from General tab


check the request header if it is sent correctly along with your other browser request headers.


now .. put this code in your config.php below the last line

Kod Blok Kilitli:      (Kayıt veya giriş yapmalısın)  
Engellenmiş, kayıtlı olmayan veya onay bekleyen kişiler kodlara erişemezler.


Advantages:
1- Turn Debug mode on for that browser for your forum without typing anything manually.
2- Don't care about your IP or ISP.
Disadvantages:
1- Unless you disable your custom header (via the add-on options) you will see your forum in Debug mode every time in that browser.
2- Your custom header will be sent with every request to any page in internet for that browser (emm so what ? )


Method (3)-By Your unchangeable & unique IP:


If your Client Public IP Address is unchangeable and unique, You can make use of it to enable the debug mode for yourself Only

record Your Unique IP then add this code below the last line in your config.php


Kod Blok Kilitli:      (Kayıt veya giriş yapmalısın)  
Engellenmiş, kayıtlı olmayan veya onay bekleyen kişiler kodlara erişemezler.




Advantages:
1- Turn Debug mode on any browser you have installed without typing anything manually.
Disadvantages:
1- You will see your forum in Debug mode every time you visit your forum from that internet line.
2- If your ISP share your public IP with other clients, those clients will also see your forum in debug mode as well as you.
3- If your ISP change your public IP or you visit the forum outside your home, no more debug mode even with the same laptop (unless you change the code again with the new IP).


original thread
http://www.kut-friends.com/Thread-vb...ite-admin-ONLY

Sorry about the weak english


--------------- Added [DATE]1309468098[/DATE] at [TIME]1309468098[/TIME] ---------------

Thanks for information dear ..
Views: 58
Reply With Quote
Reply

Thread Tools

Şunları Yapabilirsin
Yeni Konu Açmak
Konuya Cevap Yazmak
Eklenti Eklemek
Düzenleme Yapabilmek

Forum Atla


LD'de Yeni misin? Yardıma mı ihtiyacın var?

All times are GMT +3. The time now is 03:01.

Tasarım Özelliği | Genişlik: Geniş Renk: 3 methods for enabling debug mode for site admin ONLY 3 methods for enabling debug mode for site admin ONLY 3 methods for enabling debug mode for site admin ONLY 3 methods for enabling debug mode for site admin ONLY 3 methods for enabling debug mode for site admin ONLY