Jump to content

rmember

New Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by rmember

  1. will send multi person mysql login code in mornning cheers
  2. OK let me stop all this foolishness config.php <?php //edit the Username (the id) and password (pass) codes $pass ="admin"; $id="admin"; ?> login.php <?php if(isset($_GET['login'])){ if($_GET['login'] == "logout"){ setcookie ("id", "", time() - 3600); setcookie ("pass", "", time() - 3600); echo '<Center> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta name="author" content="Ron Farmer" /> <link rel="stylesheet" type="text/css" href="/style.css" /> <style type="text/css" media="all"> @import "/style.css"; </style> </head> <body> <div id="container"> die(" You have logged out successfully <br><font size 15><a href='login.php'> Click here to login</a><br></font><br>"); }} if(isset($_POST['id']) && isset($_POST['password'])) { include 'config.php'; if($id == $_POST['id'] && $pass == $_POST['password']){ setcookie("pass", $pass); setcookie("id", $id); echo '<Center> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta name="author" content="Ron Farmer" /> <link rel="stylesheet" type="text/css" href="/style.css" /> <style type="text/css" media="all"> @import "/style.css"; </style> </head> <body> <div id="container"> die( ' Thank you for logging in <br><a href="./mcp.php">Click here to access your member area</a><br>'); }else{ echo '<Center> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <title>Messiah Lutheran Church: Welcome</title> <meta name="author" content="Ron Farmer" /> <meta id="description" content="" /> <meta id="keywords" content="" /> <link rel="stylesheet" type="text/css" href="/style.css" /> <style type="text/css" media="all"> @import "/style.css"; </style> </head> <body> <div id="container"> die('Whoops you may have to try that again!<br><center><font size 15><a href="login.php"> Click here to try again </a><br></font>'); } } ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Login Form</title> <link rel="stylesheet" type="text/css" href="view.css" media="all"> </head> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> <meta name="author" content="Ron Farmer" /> <meta id="keywords" content="" /> <link rel="stylesheet" type="text/css" href="/style.css" /> <style type="text/css" media="all"> @import "/style.css"; </style> </head> <body> <div id="container"> <body id="main_body" > <img id="top" src="top.png" alt=""> <div id="form_container"> <h1><a>Login Form</a></h1> <form id="form_471358" class="appnitro" method="post" action=""> <div class="form_description"> <h2>Login Form</h2> <p>This is where you enter your administration information</p> </div> <ul > <li id="li_1" > <label class="description" for="element_1">User ID </label> <div> <input id="element_1" name="id" class="element text medium" type="text" maxlength="255" value=""/> </div> </li> <li id="li_2" > <label class="description" for="element_2">Password </label> <div> <input id="element_2" name="password" class="element text medium" type="password" maxlength="255" value=""/> </div> </li> <li class="buttons"> <input type="hidden" name="form_id" value="471358" /> <input id="saveForm" class="button_text" type="submit" name="submit" value="Log me in!" /> </li> </ul> </form> </div> <img id="bottom" src="bottom.png" alt=""> </body> </html> mcp.php the page you need the signed on for <?php include 'config.php'; if ($id == $_COOKIE['id'] && $pass == $_COOKIE['pass']) { //your members stuff }else{ die("please sign in");}?>
  3. you forgot the action="mypage.php" lol thats all
  4. lol yeah seriously just copy the file once its uploaded <?php $file = 'example.txt'; $newfile = 'example.txt.bak'; if (!copy($file, $newfile)) { echo "failed to copy $file...\n"; } ?>
  5. oh this is easy OK so I am assume you have different files or CSS themes or what not already design so before the theme is set <?php if(!isset($_COOKIE['theme'])) setcookie("theme", $default_css); if(isset($_POST["theme_selection"])){ $default_css = $_POST["theme_selection"];} else{$default_css = "defaultbalagahalsdjjaklsd";} ?> <link rel=StyleSheet href="<?php $default_css; ?> " type="text/css" /> then on every page <?php if(isset($_COOKIE["theme"])){ $default_css = $_COOKIE['theme']; else{$default_css = "defaultbalagahalsdjjaklsd";} ?> <link rel=StyleSheet href="<?php $default_css; ?> " type="text/css" /> Or something like that! Hope that helps!
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.