Jump to content

Header Problem


warhead2020

Recommended Posts

Hi, i got this problem.

 

"Warning: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\axis\AddListMain.php:1) in C:\xampp\htdocs\axis\AddListMain.php on line 16"

 

I have read all recommended solutions but i still can't find the problem. Here i will paste the code and hopefully someone can spot what is the real problem.

Thanks in advance.

 

 

The php page.

<?php
if(isset($_COOKIE['user_id']))
{
$userId = $_COOKIE['user_id'];
}
else
{
$userId = $_SESSION['user_id'];
}
if($userId=="")
{
header("Location: userError.php");
}
?>
<!doctype html public '-//W3C//DTD HTML 4.01//EN' 'http://www.w3.org/TR/html4/strict.dtd'>
<html>
<head><title>site</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO 8859-1" />
<link rel="stylesheet" href="assets/reset.css" type="text/css"/>
<link rel="stylesheet" href="assets/style.css" type="text/css"/>
<!--[if IE]><link rel="stylesheet" href="assets/styleIE.css" type="text/css"/> <![endif]-->

</head>

<body>
<div class="wrap">

<div class="header">
	<embed src="header.swf" quality="high" bgcolor="#ffffff" width="960" height="150" name="header" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer" />
</div>

<div class="head">
	<h1>Welcome to Axis Property portal, your most comprehensive real estate database made online! </h1>
	<form method="post" action="#">
		<input id="username" type="text" value="Quick Search"/>
		<input id="submit" type="submit" value="search &raquo" /> 
	</form>
</div>	


<div class="content">

	<div class="lbar">


			<div class="rounded">	
			<img src="assets/kiri-top.jpg" class="round-top"/>

				<h2>LOGIN <img src="assets/bullet1.gif"/></h2> 

				<p>                     
					<table>
					  <form action="login.php" method="post">
					    <tr><td><label for="user">Username</label></td><td><input name="user" id="user" size="22" /></td></tr>
					    <tr><td><label for="pass">Password</label></td><td><input name="pass" type="password" id="pass" size="22" /></td></tr>
					    <tr><td></td><td><input id="cookie" style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px" type="checkbox" value="do" name="cookie" /><label for="cookie"><small>Remember me</small></label></td></tr>
					    <tr>
					      <td></td><td><input type="submit" value="Login" name="submit" /></td></tr>
						   <td></td><td><br/><a title="Forgot password" href="http://t-led.com.my/main/v3/forgotpass.php">Forgot password?</a></small> or <a title="Forgot password" href="regVisitor.php">Register Now!<a></td></tr>

    </tr>
					  </form>
					</table>

                    </p>
			</div>

			<div class="noRound">
				<ul>
					<li><a href="#">Home</a></li>
					<li><a href="#">Search Listing (Advance)</a></li>
					<li><a href="#">List a property</a></li>
					<li><a href="#">Advertise with us</a></li>
					<li><a href="#">Reseller program</a></li>
					<li><a href="#">FAQ</a></li>
					<li><a href="#">News</a></li>
				</ul>
			</div>

			<br/>

			<div class="rounded">
			<img src="assets/kiri-top.jpg" class="round-top"/>

				<h2>NEW PROPERTY <img src="assets/bullet1.gif"/> <a href="" class="rightnew">more &raquo </a></h2>

					<div class="prop">
						<a href="dispProp.php?propId=86"><img class="thumb" src="assets/no_photo.jpg"></a>
						<ul>
							<li class="umah">APARTMENT</li>
					        <li class="swoosh">INVESTMENT</li>
							<li class="id">YONGPENG</li>
							<li class="rm">(S) 1 / (R) 1000000</li>
							<li><a href="dispProp.php?propId=86"><img src="assets/more.gif" class="more"/></li>
						</ul>
					</div>

					<div class="prop">
						<a href="dispProp.php?propId=85"><img class="thumb" src="assets/no_photo.jpg    "></a>
						<ul>
							<li class="umah">APARTMENT      </li>
					        <li class="swoosh">INVESTMENT   </li>
							<li class="id">TELUK INTAN Perak Ridzuan     </li>
							<li class="rm">(S) 77 / (R) 0	</li>
							</li><a href="dispProp.php?propId=85"><img src="assets/more.gif" class="more"/></a></li>
						</ul>
					</div>

				<h2>TOP 5 <img src="assets/bullet1.gif"/></h2>

				<ul class="top5">
					<li><a href="#">Vista Damai (Kajang) | RM 1 Mil </a></li>
					<li><a href="#">Silicon (Mont Kiara) | RM 100 K </a></li>
					<li><a href="#">Public Bath (Klang) | RM 1 </a></li>
					<li><a href="#">KLCC (Kajang) | RM 10 Bil </a></li>
					<li><a href="#">Centrepoint (Kajang) | RM 1 Mil </a></li>
				</ul>

			</div>
		</div>


	<div class="main">
	<!-- <img src="assets/tengah-top1.jpg" class="round-top"/>	-- nih kener ubah ke dalam setiap div under div main untuk jadikan derang cornered kat bhgn atas -- -->
			<!-- content is here -->

				<div class="featured">
				<img src="assets/tengah-top1.jpg" class="round-top"/> <!--- paste kat sinih unutk meng corneredkan div2 yg ader dlm div .main-->
					<h2><img src="assets/welcome.png"> WELCOME TO AXIS REAL PROPERTY! <img src="assets/bullet1.gif"/></h2>

					<p>
					AXIS REALTY was registered and incorporated with the Board of Valuers, Appraisers and Estate Agents in March 1988 under the Registration Number of E (3) 0050. We are one of the members of Malaysia Institute of Estate Agents (MIEA) OM289 since May 1989.
					</p>
				<img src="assets/tengah-bottom1.jpg" class="round-bottom"/> <!--ditambah untuk mengcorner kan bhgn bawah setiap div-->	
				</div>

				<div class="featured">
				<img src="assets/tengah-top1.jpg" class="round-top"/> <!--- paste kat sinih unutk meng corneredkan div2 yg ader dlm div .main-->
					<h2><img src="assets/rumah.png"> FEATURED PROPERTIES <img src="assets/bullet1.gif"/> <a href="" class="right">more &raquo </a></h2>
					<div class="mainFeat"><a href=""><img src="assets/featured.png" alt="kinrara mas project" class="featleft" /> <span class="hightl">KINRARA EMAS | RM 2 Mil &raquo </span> </a></div> 

					<div class="feat1">
						<div class="featThumbnails">
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>KLANG <br/> <span class="red">RM 1 Mil</span></a></a></div>
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>Dato Keramat <br/> <span class="red"> 1 Mil</span></a></div>
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>JOHOR <br/> <span class="red"> 100K</span></a></div>
						</div>
						<div class="featThumbnails">
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>SARAWAK <br/> <span class="red"> 380K</span></a></div>
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>PERAK DARUL RIDZUAN<br/> <span class="red"> 1 Mil</span></a></div>
							<div class="featu"><a href="dispProp.php?propId=86" class="featura"><img class="featThumb" src="assets/no_photo.jpg"><br/>KLANG <br/> <span class="red"> 1 Mil </span></a></div>
						</div>
					</div>
				<img src="assets/tengah-bottom1.jpg" class="round-bottom"/> <!--ditambah untuk mengcorner kan bhgn bawah setiap div-->		
				</div>
			<br/>
				<div class="news">
				<img src="assets/tengah-top1.jpg" class="round-top"/> <!--- paste kat sinih unutk meng corneredkan div2 yg ader dlm div .main-->
					<h2> <img src="assets/news.png"> LATEST NEWS  <img src="assets/bullet1.gif"/> <a href="" class="right">more &raquo </a></h2>
					<img src="assets/newskecik.jpg" alt="kinrara mas project" class="right" />
                    <!--<img src="assets/newskecik.jpg" class="mainThumb"/>-->
						<ul>
							<li><a href="showNews.php?id=7">07 MAY 2009 | make</a></li>
                            <li><a href="showNews.php?id=8">07 MAY 2009 | make2</a></li>
                            <li><a href="showNews.php?id=9">07 MAY 2009 | asa</a></li>
                            <li><a href="showNews.php?id=3">22 APR 2009 | qqq</a></li>
                            <li><a href="showNews.php?id=4">22 APR 2009 | asdad</a></li>
                        </ul>
				<img src="assets/tengah-bottom1.jpg" class="round-bottom"/> <!--ditambah untuk mengcorner kan bhgn bawah setiap div-->		
				</div>

                <div class="tips">
				<img src="assets/tengah-top1.jpg" class="round-top"/> <!--- paste kat sinih unutk meng corneredkan div2 yg ader dlm div .main-->
					<h2> <img src="assets/tips.png"> TIPS  <img src="assets/bullet1.gif"/> <a href="" class="right">more &raquo </a></h2>
						<img src="assets/tipskecik.gif" alt="kinrara mas project" class="right" height="120px" />
						<ul>
							 <li><a href="showTips.php?id=2">08 MAY 2009 | tips 1</a></li>
                             <li><a href="showTips.php?id=1">22 APR 2009 | aa</a></li>
							 <li><a href="showTips.php?id=2">08 MAY 2009 | tips 1</a></li>
                             <li><a href="showTips.php?id=1">22 APR 2009 | aa</a></li>
							 <li><a href="showTips.php?id=2">08 MAY 2009 | tips 1</a></li>
                        </ul>
				<img src="assets/tengah-bottom1.jpg" class="round-bottom"/> <!--ditambah untuk mengcorner kan bhgn bawah setiap div-->		
				</div>

				 <div class="advsearch">
				 <img src="assets/tengah-top1.jpg" class="round-top"/> <!--- paste kat sinih unutk meng corneredkan div2 yg ader dlm div .main-->
					<h2> <img src="assets/advsearch.png"> Advance Search  <img src="assets/bullet1.gif"/> <a href="" class="right">more &raquo </a></h2>
						<img src="assets/tipskecik.gif" alt="kinrara mas project" class="right" height="120px" />

						<p> Click and choose the options at the bottom to use advanced search function. Any combination is possible to filter and get better search result which suited your demand. <a href="mailto:admin@axis.com">Feedback </a> </p>

						<form>Options: <br/> 
						<select>
							<option>Available For:</option>
							<option>2</option>
							<option>3</option>
							<option>4</option>
						</select>

						<select>
							<option>Type:</option>
							<option>Investment</option>
							<option>House</option>
							<option>Rent</option>
						</select>

						<select>
							<option>Price:</option>
							<option>2</option>
							<option>3</option>
							<option>4</option>
						</select>

						<select>
							<option>Zone:</option>
							<option>North</option>
							<option>West Coast</option>
							<option>Middle</option>
						</select>
						<br/>
						<!--<input name="Submit" type="Submit" value="Search Now &raquo" class="right"/>-->
						<a href="#" name="Submit" value="Submit"> <img src="assets/searchButt.gif"/></a>

						</form>
					<img src="assets/tengah-bottom1.jpg" class="round-bottom"/> <!--ditambah untuk mengcorner kan bhgn bawah setiap div-->			
				</div>

			<!-- <img src="assets/tengah-bottom1.jpg" class="round-bottom"/> uncomment balik klu nk back to the design yg asal -->
			</div>


		<div class="rbar">
		<img src="assets/kanan-top.jpg" class="round-top"/>	
			<div class="ads">
				<h2> Ads </h2>
				<p>
				<img src="assets/1.jpg"/>
				<img src="assets/2.jpg"/>
				<img src="assets/3.jpg"/>
				<img src="assets/4.jpg"/>
				<img src="assets/5.jpg"/>
				<img src="assets/6.jpg"/>
				</p>
			</div>
		<img src="assets/kanan-bawah.jpg" class="round-bottom"/>	
		</div>

</div>	

<div class="footer">

	<p>Navigation : <a href="">Buy</a> | <a href="#">Rent</a> | <a href="">Sale</a> | <a href="">Resources</a> | <a href="">Contact Us</a> | <a href="">Term Of Use</a></p>
	<p>Copyright © 2000 <a href="">Axis-Realtors.com</a> All Rights Reserved</p>

</div>

</div>	
</div>
</body>
</html>

 

 

 

the css file

body{font-family: Century Gothic, Georgia, Times New Roman, Times, serif; font-size: 11px; color: #333333; background: #fff url(bg5.jpg);}
a, a:visited{color: #ff7800; text-decoration: none;}
a:hover {text-decoration: underline;}
.wrap{background: url(wrapBG.png) repeat-y;width: 990px; margin: 0 auto;}
.header{float: left; background: url(wrapBG.png) repeat-y;width: 990px; padding: 0px 15px;}

.head {background: url(wrapheadBG.png) repeat-y;width: 990px; padding: 0px 15px; float: left;}
.head h1{display: block; float: left; padding: 6px 0 8px 10px;}
.head form{float: right; margin-right: 39px;}
.head form{margin-top: 2px;}
input {font-size: 11px; color: #80765e;}

.content{floaT: left; background: url(wrapBG.png) repeat-y;width: 990px; padding: 0px 15px;}

.lbar{float: left; background: #fff; margin: 12px 0 0 0;}
.lbar div{margin: 0 10px; width: 200px;}
.round-top {margin: 0 0 7px -10px; float: left}
.round-bottom {margin-left: -10px; float: left;}
.lbar .rounded h2{background: url(menuBG.jpg) repeat-x bottom; padding: 5px 10px; margin-bottom: 10px;}
.lbar .rounded {background: #fff url(kiri-bott2.jpg) no-repeat bottom left; padding: 0 10px 10px 10px; margin-top: -2px;}

.noRound{width: 200px; margin: 10px 10px 20px 10px; padding: 10px;}
.noRound ul li {list-style: url(menuBullet1.jpg) inside; padding: 0 0 8px 0px; border-bottom: #564435 1px dotted; }
.noRound a, .noRound a:visited{color: #8f8c8c;}
.noRound a:hover {color: #ff7800; text-decoration: none;}

div.prop {font-size: 11px;  border-bottom: #B5B5B5 1px dotted; float: left; margin: -5px 10px 10px 0 ; padding: 5px 5px 10px 5px; width: 189px}
.prop img.thumb{float: left; width: 100px; margin: 0 5px 0 0; border-bottom: #ffc200 3px solid;}
.prop ul{padding-top: 0px; padding-left: -5px;}
li.umah{list-style: url(ikon-rumahFF.jpg) inside; color:#0066FF; font-weight:bold;}
li.swoosh{list-style: url(ikon-swooshFF.jpg) inside; color:#0066FF; font-weight:bold;}
li.id{list-style: url(ikon-idFF.jpg) inside; color:#0066FF; font-weight:bold;}
li.street{list-style: url(ikon-streetFF.gif) inside; color:#0066FF; font-weight:bold;}
li.rm{list-style: url(ikon-rmFF.jpg) inside; color:#0066FF; font-weight:bold;}
a img.more{float: right; width: 73px; height: 11px; margin-top: 7px; border: 0px; background: #fff;}

ul.top5 li{list-style: url(bulletStar.gif) inside; padding: 5px 0;}

/* .main{width: 520px; padding: 0 10px; background: #fff url(tengah-body1.jpg) repeat-y; float: left; margin: 10px 0 0 0;} */
/* .featured{float: left; width: 520px; margin-bottom: 20px;} */
/* .featured h2{background: url(menuBG.jpg) repeat-x bottom; font-size: 14px; padding-bottom: 3px; margin-top: -7px;} */


.main{width: 520px; padding: 0;  float: left; margin: 10px 10px 0 10px;}
.featured{float: left; width: 540px; margin-bottom: 15px; margin-left: -10px; padding:0 10px; background: #fff url(tengah-body1.jpg) repeat-y bottom left;}
.featured h2{background: url(menuBG.jpg) repeat-x bottom; font-size: 14px; padding-bottom: 3px; margin-top: -7px; width: 520px;}

.featleft{float: left; margin: 10px 0 0 10px; border:2px solid #FF0000;} 
.featured p{padding: 15px;}
ul.feat{margin-left:200px;}
.featured li {list-style: url(bulletStar.gif) inside; padding: 3px 0;}
div.featu {width: 80px; border-bottom: #ffa200 1px dotted; float: left; margin: 5px; text-align: center; padding-bottom: 3px;}
.featu a, .featu a:visited{ color: #534465 ; font-size: 10px;}
.featu a:hover{text-decoration: none; color: #ffa200;}
.mainFeat{width: 190px; float: left; text-align: center;}

.featThumb {width: 80px;}
.feat1{float: left; margin-top: 10px; margin-left: 20px; width: 300px;}
.featThumbnails{margin-top: 0; margin-left: 10px; float: left;}
.red {color: #00a8ff;}
.green {color: #009900;}


a.right{float: right; font-size: 11px; margin-top: -14px; margin-right: 3px; padding: 0;}
a.rightnew{float: right; font-size: 11px; margin-top: -11px; margin-right: -3px; padding: 0;}

/* .news, .tips, .details, .advsearch{width: 520px; float: left; margin: 10px 0 0 0;}  */
/* .news h2, .tips h2, .details h2, .advsearch h2{background: url(menuBG.jpg) repeat-x bottom; font-size: 14px; padding-bottom: 3px; margin-top: -7px;}  */

.news, .tips, .details, .advsearch{float: left; width: 540px; margin-bottom: 15px; margin-left: -10px; padding:0 10px; background: #fff url(tengah-body1.jpg) repeat-y bottom left;}
.news h2, .tips h2, .details h2, .advsearch h2{background: url(menuBG.jpg) repeat-x bottom; font-size: 14px; padding-bottom: 3px; margin-top: -7px; width: 520px;}


.news ul , .tips ul, .advsearch form{margin: 10px 0 0 20px;}
.news li, .tips li{list-style: url(menuBullet1.jpg) inside; padding: 0 0;}
.right{float: right; margin-right: 20px;}

Link to comment
Share on other sites

Warning: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\axis\AddListMain.php:1) in C:\xampp\htdocs\axis\AddListMain.php on line 16

Output was started at line 1 of the script.

If no output is visible, then it's probable that you've save the PHP script with a BOM marker, for eaxmple saved it as UTF-8

Link to comment
Share on other sites

That can't be the code the AddListMain.php...the line numbers in the errors don't match up to the code

 

Yes..im using different code/php. But basically...in AddListMain.php, there r a lot php code so i just want to focus on that php part. I notice, even simple html page cant run the php code.

Link to comment
Share on other sites

Warning: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\axis\AddListMain.php:1) in C:\xampp\htdocs\axis\AddListMain.php on line 16

Output was started at line 1 of the script.

If no output is visible, then it's probable that you've save the PHP script with a BOM marker, for eaxmple saved it as UTF-8

 

I read sumthing about dreamweaver save page as BOM marker and need to save it without it. So,how to save it as UTF-8?.  Thanx in advance.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.