I am working on a DJ login for Bobboid.
With 2 tools. DJ requests and a DJ says.
I am working on the DJ says first because that should be easyer.
[Can I ask you not to use it for the time being, I may let people use it once Its been writen]
In the files I have
- index.htm [Login page]
- login.php [Form handler]
- djsays.txt [Holds the Data for dj says]
- config.php [Holds data like username, passwords ect]
- admin.php [Holds admin tools, and links]
- show.php [Shows data submitten via admin cp, from "djsays.txt"]
Faults are in index.htm [I need to no how to send it to the form handler], admin.php [How can I protect it, via the login? Need help (Dont no how) to use cookies do save your login for "x" seconds]
Here the codes I have writen
index.htm
login.phpHTML Code:<html> <form name="form1" method="post"> <div>Username: <input id="userinput" type="text" value="" name="userinput"> <br> <br>Password: <input id="passinput" type="password" value="" name="passinput"> <br> <br> <input type="submit" value="Submit" name="Submit"> <input type="reset" value="Reset" name="Reset"> <input id="action" type="hidden" value="submit" name="action"> </div></form> </html>
djsays.txtPHP Code:<?php
include('config.php');
if($action == "submit"){
if(($userinput == "")||($passinput == "")){
echo "$info";
} else {
if(($userinput == $user)&&($passinput == $pass)){
header( "Location: $url" );
} else {
echo "$fail";
}
}
}
include('form.php') ;
?>
config.phpAnything you want.
admin.phpPHP Code:<?PHP
//Config
//Writen by Danny for Bobboid.NET
$user = "User";
$pass = "Password";
$email = "[email protected]";
$url = "http://www.test.com/admin.php";
$fail = "Wrong password/user";
$info = "No information";
//End config
?>
show.phpNothing been writen for it yet.
PHP Code:<?php
include ("config.php");
include ("djsays.txt");
?>
</font>
Okay!
Can anyone help me with...
- Making a form to edit the data in "djsays.txt"
- Fix index.htm
- Make admin.php safe...
Thanks people![]()





Reply With Quote







