Jump to content

pasan4you

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by pasan4you

  1. can u tellme the place where i apply it
  2. i have created a web site.In the User page of . it will welcome the User as Good Morning, Good Afternoon or Good Evening according to the Server Time.can any one tell me how to do it. <h1>"Goodqqq Morning"! <?php echo $_SESSION['username'];?> . Welcome to TTl University College</h1> <h2>Course Registration Requests</h2> i need the coording to change the welcome message based on the server time in PHP. thnks
  3. <?phprequire_once 'config.php'; //calls to config.php $login_username = $_POST['login_username'];//getting user name $login_password = $_POST['login_password'];//getting password $conn = new PDO('mysql:host='.DB_HOST.';port='.DB_PORT.';dbname='.DB_NAME,DB_USER,DB_PASS);//connecting to databse $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); try { $sql = 'SELECT login_username, login_password, login_group FROM login WHERE login_username=:login_username'; $stmt = $conn->prepare($sql); $stmt->execute(array(':login_username' => $login_username)); $result = $stmt->fetchAll(); if ( count($result) ) { $row = $result[0]; $_SESSION['login_username']= $row['login_username']; $_SESSION['login_group']= $row['login_group']; $_SESSION['info'][] = "Welcome to Leave Management System Of IDM University College ! "; } else { $_SESSION['info'][] = "Please check your user name and password!"; } } catch (Exception $ex) { $_SESSION['info'][] = "Login Error !"; } header("Location: ".$_SERVER['HTTP_REFERER']); ?>
  4. need cooments wht is done frm these key words $conn = new PDO('mysql:host='.DB_HOST.';port='.DB_PORT.';dbname='.DB_NAME,DB_USER,DB_PASS); $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
  5. need cooments for these key words $conn = new PDO('mysql:host='.DB_HOST.';port='.DB_PORT.';dbname='.DB_NAME,DB_USER,DB_PASS);//connecting to databse $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);

  6. Guys,,i want to do this Write a script to ask a user 3 question about PHP, and keep track of their score from question to question Ask one question at a time, and evaluate one answer at a time :happy0046: THE PROGRAM SHOULD MAKE USING RADIO BUTTONS AND IF CONDITION or SWITCH STATEMENT......SIMPLE CODE,,,(NO JAVA SCRIPT)PLZZ HELP MEEEEEEE........... THNK YOUuuuuuuuuuuuuuuuu
×
×
  • Create New...