#1
|
||
|
Admin Panel on ANYTHING
I know your all a bit "Cant be assed" (if u know what i mean ) but i was wondering, IF anyone of you could help me and give me a full on guide on how to do an admin panel for any website?
|
#2
|
||
|
it really depends on what admining you need to do.... lol, give some examples and ill help you with some .
|
#3
|
||
|
well say a site, which has a news page, file download page, clan section (such as with roster, results...)
|
#4
|
||
|
Well.. anyone gonna help? =/ PLZ? (A)
|
#5
|
||
|
i should really log in lmao... anyways...
yeah.. its easy to make an admin panel:
config.php <? $Auser = "admin"; $Apass = "password"; ?> admin.php <html><body> <form method=post action=admin.php> <div align=center> <br>Username : <input type=text name=username> Password : <input type=password name=password> <input type=submit name=submit value=ADMIN ME> </div> </form> <? session_start(); //Start a PHP session header("Cache-control: private"); //IE 6 Fix include("config.php"); if isset($_POST[submit]){ if($adminuser == $_POST['username'] && $adminpass == $_POST['password'] || $_SESSION['logged'] == "yes") { //If vars match load up admin panel below is protected $_SESSION['logged'] = "yes"; echo("<a href=panel.php>panel</a><br>"); } else { echo("ERROR"); } } ?> panel.php <? session_start(); //Start a PHP session header("Cache-control: private"); //IE 6 Fix if($_SESSION['logged'] == "yes") { THIS IS PROTECTED AREA!!! TO ADD SECTIONS USE TIS PAGE AS A TEMPLATE! <br><a href=logout.php>Leave the panel</a><br> "); } else { print("ERROR"); } ?> logout.php <? session_start(); //Start a PHP session header("Cache-control: private"); //IE 6 Fix session_destroy(); print(" logged out-"); ?> Hope this helped?? if you need any help or what ever jsut ask msn: carelessrabbit@hotmail.com aim: carelessrabbit However this was lifed from my admin panel so you may need to custom it to you. |
#6
|
||
|
At least i think it will work.
|
#7
|
||
|
Re: i should really log in lmao... anyways...
[quote:42f196b12e="careless_guest"]
<? session_start(); //Start a PHP session header("Cache-control: private"); //IE 6 Fix if($_SESSION['logged'] == "yes") { THIS IS PROTECTED AREA!!! TO ADD SECTIONS USE TIS PAGE AS A TEMPLATE! <br><a href=logout.php>Leave the panel</a><br> "); } else { print("ERROR"); } ?> [/quote:42f196b12e] forgot the print(" or the echo " |
#8
|
||
|
Re: Oh yeah.
[quote:71d5902f8e="PHP-Largo"]
forgot the print(" or the echo "[/quote:71d5902f8e] So i see because i took out all the crap that qwas there before. btw, did anyone use/test this to see if it works, i just extracted it. hope i involved all correct code |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Don't see the Admin Panel | Guest | phphq.Net Forums | 0 | 05-02-2005 10:06 AM |
admin panel | mike | phphq.Net Forums | 1 | 12-19-2004 04:53 AM |