That's u mean this meta..

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
I have used it..
I am newbie in php scripting on asp I do Buffer on top of page to
redirecting like this below.
Response.Buffer = True 'Buffers the content so our Response.Redirect
will work
..
is it available on php scripting..??


-----Original Message-----
From: Michael Hazelden [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, August 15, 2002 5:28 PM
To: 'Reymond '
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] create header and redirecting

AFAIK - you can't echo or print before sending a header.

If you want to do this - maybe use meta tags rather than the location
redirect.

Michael.

-----Original Message-----
From: Reymond [mailto:[EMAIL PROTECTED]]
Sent: 15 August 2002 11:40
To: 'Michael Hazelden'
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] create header and redirecting


$formy = "select id, login, level, is_active from User where login =
'$login' AND password=md5('$passwordacting')";
$data = mysql_query($formy,$cnx);
$result_data = mysql_fetch_array($data);
echo $result_data['id']; <-- this line 16 , I wanna try to print to
browser.., and work good..
echo $row['hasil'];


if ($row["result"]=="0") 
{
..................


-----Original Message-----
From: Michael Hazelden [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, August 15, 2002 5:14 PM
To: 'Reymond '
Subject: RE: [PHP] create header and redirecting

Reymond,

What is Line 16?

Michael.

-----Original Message-----
From: Reymond [mailto:[EMAIL PROTECTED]]
Sent: 15 August 2002 11:00
To: [EMAIL PROTECTED]
Subject: [PHP] create header and redirecting


I have tree pages, we call it first.php, second.php, third.php 
On My first.php page, I have form (LOGIN FORM)  and I'd action it to
second page. Like this Below
.... <form method="post" action="second.php">......

In my second page I'd tried to use header, for redirecting to third.php
after check the session, in my Session table in my Database, (and I've
got the session on my database.
---------------------------- second.php --------
..........
if ($row["result"]=="0") 
{
header("location: http://www.blabla/blablba/second.php?message=<font
color=red>Incorrect Password</font>");
}
elseif ($row["result"]!= 0) 
{
        $id = $result_data['id'];
        mysql_query("Delete from Session where user = '$id'", $cnx);
        $session_id = randSession();
        mysql_query("Insert into Session values('$id','$session_id')");
        if ($result_data["level"]==1)
        {
        header("location:
third.php?id=$id&session_id=$session_id");<--LINE 33
        }
        else
        {
        header("location: third.php?id=$id&session_id=$session_id");
        }
        
}
..........
-------------------------------------------------------

doesn't got redirecting to the third.php but I got error message  on my
second.php..., like this below.

Warning: Cannot add header information - headers already sent by (output
started at /home/unri/ketahanan-pangan/second.php:16) in
/home/unri/ketahanan-pangan/second.php on line 32

1. so how to use buffer for redirecting.... ????
2. is it right if I give the action(I mean Action Form) in my first.php
page to the second.php page..???,  

note : I have check my Session table On My database (MYSQL), and I got
it...

Help... 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


_____________________________________________________________________
This message has been checked for all known viruses by the 
MessageLabs Virus Control Centre.

This message has been checked for all known viruses by the MessageLabs
Virus Control Centre.

        
*********************************************************************

Notice:  This email is confidential and may contain copyright material
of Ocado Limited (the "Company"). Opinions and views expressed in this
message may not necessarily reflect the opinions and views of the
Company.
If you are not the intended recipient, please notify us immediately and
delete all copies of this message. Please note that it is your
responsibility to scan this message for viruses.

Company reg. no. 3875000.  Swallowdale Lane, Hemel Hempstead HP2 7PY

*********************************************************************


_____________________________________________________________________
This message has been checked for all known viruses by the 
MessageLabs Virus Control Centre.

This message has been checked for all known viruses by the MessageLabs
Virus Control Centre.

        
*********************************************************************

Notice:  This email is confidential and may contain copyright material
of Ocado Limited (the "Company"). Opinions and views expressed in this
message may not necessarily reflect the opinions and views of the
Company.
If you are not the intended recipient, please notify us immediately and
delete all copies of this message. Please note that it is your
responsibility to scan this message for viruses.

Company reg. no. 3875000.  Swallowdale Lane, Hemel Hempstead HP2 7PY

*********************************************************************


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to