man utd lolreina, can u help me with another error
![]()

man utd lolreina, can u help me with another error
![]()
Ok, Pm me your msn if you like
Im not saying that, Im saying this:so blob, your saying like this for example your NOT allowed;
<head><title>Blah</title></head><html><font face="verdana" size="1"> bla bla </font></html>
<?
echo("hello world");
?>
Like that so wud it be?
<?
echo("hello world");
?>
<head><title>Blah</title></head><html><font face="verdana" size="1"> bla bla </font></html>
for example, echo being the cookies bit :p
YEH SHUP K THATS NOT TEH QUESTIon and i broke my shift key "/
If you have anything that needs a header, like starting sessions cookies or just using header(""); you need to make sure its at the top of the page.
E.g.
That would produce a header error, so you have to use:PHP Code:<html>
<head>
<title>Hello</title>
</head>
<body>
<?php header("Location: index.php"); ?>
</body>
</html>
So its at the top of the pagePHP Code:<?php header("Location: index.php"); ?>
<html>
<head>
<title>Hello</title>
</head>
<body>
</body>
</html>
But if its at the top of the page, you can still have php above it, like:
Get what I mean?PHP Code:<?php
$string = "insert";
$stupid = "idiots";
$in = "here";
header("Location: index.php");
?>
<html>
<head>
<title>Hello</title>
</head>
<body>
</body>
</html>
You can only send headers before you've sent any output to the browser.
i used to be NintendoNews. visit my blog or add me on twitter.
need help with vista? i am a microsoft certified technology specialist in configuring windows vista and connected home integrator.. pm me for help!
"I am the way, the truth, and the life. No one comes to the Father except through me"
John 14:6 (NIV)
AHH Thanks for that - it clears it up.
is that the same for session_start() and ob_start or whatever they are?
Yep - cookies and sessions must be intiated before any output is sent to the browser, otherwise you better have a raincoat on, because there will be errors.
Want to hide these adverts? Register an account for free!