School Map:  Home / Enroll $ Student Records; Class  
$ News @ LIVE Tech Radio * Support/FAQ | Store | FORUMS

Class / Forums / mysql101 Refresh the current page Week #5 ADVANCED To-Do Assignment
 

 (#38 2003-09-05 15:35:43) Post Reply

TDavid
php mySQL Perl C/C++
Principal


Enrolled: Mar 2000
Posts: 193
AP: 1

Your Week #5 ADVANCED TO-DO assignment should be posted here in this thread only. If you have specific questions about the week 5 course text then please also post them in this thread so that other students can learn from the information and we can collectively build a knowledge base.

Here is the details on what you need to do in this assignment:

Add user authentication to the Website-Sponsor application. Enable a multi page span to display all of the data in all of the Websites or through a user controlled switch, all of the data in all of the Sponsors. For each one, display all of it's URL's and relationships as links.

 

 (#62 2003-11-03 16:03:34) Post Reply

pIscIs
Need To Set


Enrolled: Nov 2003
Posts: 5
AP: 1

this script build by logscript basic example. but it didint work, then i choosing a graphic and press submit it returns me tu login page.

<HTML>
<HEAD>
<TITLE>PHP Advance Assignment 5</TITLE>
</HEAD>
<BODY>
<?php

$banners = array("<img src=\"banner1.jpg\">","<img src=\"banner2.jpg\">","<img src=\"banner3.jpg\">","<img src=\"banner4.jpg\">");
$banner_name = array("banner1", "banner2", "banner3", "banner4");

if (isset($_POST['banner_choice']) && !empty($_POST['banner_choice']))
{
print("$banners[$banner_choice]");
exit;
}
if (isset($_POST['action']) && $_POST['action'] == 'true')
{
if ($_POST["username"] == 'phpstudent' && $_POST["password"] == 'phptest')
{
print('You logged on');

?>
<form action=" <?php print $_SERVER['PHP_SELF'];?> " method="POST">
<SELECT NAME="banner_choice" >
<?
for($i = 0; $i < 4; $i++)
{
print("<option value=\"$i\">$banner_name[$i]</option>");
}
?>
</select>
<INPUT TYPE="submit" VALUE="Submit" > <INPUT TYPE=reset VALUE="Reset">
</form>
<?
exit;
}
else
{
print("Username and Password are incorrect. Please enter correct values.");
}
}
?>
<center>Please enter the username and password to continue:<br>
<b>Hint:</b><br> Username: phpstudent<br> Password:phptest
<form action=" <?php echo $_SERVER['PHP_SELF']; ?> " method="POST">
<input type="hidden" name = "action" value = "true">
<input type="text" name="username"><br>
<input type="password" name="password"><br>
<input type="submit" value="submit">
</center>
</FORM>
</BODY>
</HTML>


 

 (#63 2003-11-03 16:08:55) Post Reply

pIscIs
Need To Set


Enrolled: Nov 2003
Posts: 5
AP: 1

not in this forum posted :P
sorry

 

 (#64 2003-11-08 05:23:59) Post Reply

logspirit
Need To Set


Enrolled: Oct 2001
Posts: 63
AP: 1

pIscIs, That post belongs in the PHP forum, not MySQL... I guess You realized that... after clicking the submit button.
logspirit

 

 

View Previous Thread
Print this page Print This Page

View Next Thread

School Map:  Home / Enroll $ Student Records; Class  
$ News @ LIVE Tech Radio * Support/FAQ | Store

Advertising | Link To Us | Privacy 
Copyright 2000-2002 Script School Productions / KMR Enterprises 
No part of this website may be reproduced, copied and/or distributed in any medium 
without express written permission