¹C«È:  µù¥U | µn¿ý | ·j¯Á | À°§U | VIPÃÙ§U¥»¯¸ | ¥ZµnÃÙ§U¼s§i | ³]¬°­º­¶ | ¥[¤J¦¬Âà | ÁcÅ餤¤å

 

your gf Ú»­ø¨ì¤ù ¥î¼äóa ¤£¯à³X°ÝSOPCAST­¶­± ¶Â¦â­I´º ¤ÑÀs¤K³¡·tª÷Ä_ ¸Ý¥Ponline©xºô ¤p¤t¬ü ½u¤WH°Êµe §K¶O§Y®É³ø»ù ªá¼Ë¤Ö¦~¤Ö¤k¢ê¢ü ¤Ó»×¥ß§Ó¶Ç ¤H¶¡¤¿¾¹º©µe Hebe·s¾v«¬ Media calssic I miss you³¯¬f¦t seed H LostPlanet¯}¸Ñ ¤Ñ°ó¨pªA³Ü¤ôµ{¦¡ ¤Ñ¥~2 online ¯]®ü®á®³¤p©j¥þ®M

 




·j¯Á¿ï¶µ ¯Á¤Þ¨t²Î¤u¨ãµ¡
 
¼ÐÃD: PHP + session°ÝÃD
http://manyway.net ÃÙ§Uºô¯¸¸ü¤J¤¤...
tinlok115
¤j²³¥¿¦¡·|­û
Rank: 2Rank: 2


ºaÅA¾±³¹ ¥Ø«e¨S¦³¾±³¹

UID¡G 855156

©Ê§O¡G «O±K

ºëµØ¡G 0 ½g

¿n¤À¡G 102 ÂI

©«¤l¡G 1 ½g

  ¤j ¤¤ ¤p
µoªí©ó 2008-2-26 13:52  ¸ê®Æ  ­Ó¤HªÅ¶¡  µu®ø®§  ¥[¬°¦n¤Í 

PHP + session°ÝÃD ±z¬O²Ä 471­ÓÂsÄýªÌ

¤p§Ì°µºò­Ó´úÅçºô­¶, ¦³¥H¤Uo¬Jerror,½Ð¦U¦ì¸Ñµª¤UÀ³¸ÓÂI¸Ñ¨M,thx!!!

¤@login´N·|¤J¥ª­Óadd_quiz.php o¬Jºô­¶¤W¤è´N¦³¥H¤Umsg..¦ý¥ò¥i¥H°µ³¥
Notice: A session had already been started - ignoring session_start() in c:\Inetpub\wwwroot\intranet\chi_quiz\add_quiz.php on line 3

¦pªG¹Á¸Õupload file´N·|¥X¥H¤Uerror msg,¦A°µ­ø¨ì³¥...
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at c:\Inetpub\wwwroot\intranet\chi_quiz\batch_add_quiz.php.php:1) in c:\Inetpub\wwwroot\intranet\chi_quiz\connection.php on line 3

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at c:\Inetpub\wwwroot\intranet\chi_quiz\batch_add_quiz.php.php:1) in c:\Inetpub\wwwroot\intranet\chi_quiz\connection.php on line 3

connection.php
<?php
session_start();
//load form database
$link = mysql_connect("localhost", "quiz_login", "quiz");
mysql_select_db("chi_quiz");

if (mysql_error()) { print "Database ERROR: " . mysql_error(); }
mysql_query("SET CHARACTER SET utf8", $link);
mysql_query("SET NAMES 'utf8'", $link);

?>
-----------------------------------------------------------------------------------------------------------------
index.php
<?php
include 'connection.php';
$err = 0;
if ($_POST)
{
$login = $_POST['login'];
$pwd = $_POST['password'];
$sql = "select `login`, `className` , `login_times` from `student` where `login`='$login' and `password` ='$pwd'";
$result = mysql_query($sql);
if (mysql_num_rows($result)==1)
{
  $rowArray = mysql_fetch_row($result);
  $class =  $rowArray[1];
  $login_times =  $rowArray[2];
  $_SESSION["logNm"]= $login;
  $_SESSION["class"]= $class;   
  if ($login=="admin")
  {
   header('location: add_quiz.php');
.

.
.
?>

<html>
......
</html>
..........................................................................................................................................
add_quiz.php
<?php
require 'connection.php';
session_start();

if (!$_SESSION or $_SESSION["logNm"] != "admin")
{
header('location: index.php');
}

.
.
.
?>

<html>
......

</html>
-------------------------------------------------------------------------------------------------------------------------------
batch_add_quiz.php
<?php
include'connection.php';
require "../common/input/excel/reader.php";
// Retreive the file name, size and type
$q_id = $_POST['qid'];
$f_name = $_FILES['fname']['name'];
$f_size = $_FILES['fname']['size'];
$f_type = $_FILES['fname']['type'];
.

.
.
?>


[ ¥»©«³Ì«á¥Ñ tinlok115 ©ó 2008-2-26 14:21 ½s¿è ]

³»³¡
¨ª¤§µØ
¤j²³¥¿¦¡·|­û
Rank: 2Rank: 2


ºaÅA¾±³¹ ¥Ø«e¨S¦³¾±³¹

UID¡G 1144609

©Ê§O¡G ¨k

ºëµØ¡G 0 ½g

¿n¤À¡G 100 ÂI

©«¤l¡G 1 ½g

  ¤j ¤¤ ¤p
µoªí©ó 2008-2-28 11:04  ¸ê®Æ  ­Ó¤HªÅ¶¡  µu®ø®§  ¥[¬°¦n¤Í 
¦bindex.php¦³include 'connection.php'¤F ¨Ã¥B¸Ì­±¤]¤w¸g¶}©lsession¤F
·í¥Îadminµn¤J«áÂà¨ìadd_quiz.php«á¤S¦³session_start()

©Ò¥H­«½Æ¶}±Òsession

³»³¡

 



¥»¯¸³]³Æ¾¹§÷¥Ñ Many Way (HK) Limited ÃÙ§U´£¨Ñ
·í«e®É°Ï GMT+8, ²{¦b®É¶¡¬O 2008-10-16 03:57

Advertisting Agency

Audit and Analytics

Partner Companies

Powered by Discuz! 5.5.0¢x0.042679 (s), 7 queries, Copyright © 2008 HK-PUB.COM All Rights Reserved. ¥»¯¸Án©ú - ¼s§i¬d¸ß - ²M°£ Cookies - Ápô§Ú­Ì - ¤j²³½×¾Â - Archiver - WAP