Some simple help please
Posted: Mon Mar 07, 2005 7:40 am
Hi, im pretty new tophp coding and so forth. Im developing a page for my site, using the "case" feature. so ?action=home shows my homepage.
I have it working good (not sure if the coding is good, but it works) in FireFox ... But IE, just refuses to display the file. Anyone know why? and anyone able to impriove my code a little? As my code is pulled from a message boards code, and peiced together..
heres the code..
I have highlighted the php bits, maybe someone can improve the code? and let me know why IE isnt liking it?
feyd | Please use
I have it working good (not sure if the coding is good, but it works) in FireFox ... But IE, just refuses to display the file. Anyone know why? and anyone able to impriove my code a little? As my code is pulled from a message boards code, and peiced together..
I have highlighted the php bits, maybe someone can improve the code? and let me know why IE isnt liking it?
Code: Select all
<?php
// check if page and if not then empty
$content = isset($action) ? $action : '';
// Make homepage
switch ($action) {
// Define homepage display
// HomePage.php?action=home
case 'home':
$pagetitle = " HomePage ";
?>
<html>
<head>
<title>.:: Welcome to Teenfront.co.uk ::. <?php echo $pagetitle ?>
</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="description" content="The UK's best teen chat site. Features free teen chat rooms and community, teen horoscopes, teen links, problem advice and music and film reviews.">
<meta name="keywords" content="teen chat, room, uk teenagers, teens, students, webchat, message boards, uk, teen shopping, chatroom, teen, shops, chat, kids, young adults, magazines, online, teen, links, youth, kids, music, film, reviews, sites for teenager, sites for teens, meet, talk, message boards, javachat, irc, community, problems, advice, teenmail">
<META NAME="OWNER" CONTENT="admin@teenfront.net">
<META HTTP-EQUIV="EXPIRES" CONTENT="">
<META HTTP-EQUIV="CHARSET" CONTENT="ISO-8859-1">
<META HTTP-EQUIV="CONTENT-LANGUAGE" CONTENT="English">
<META HTTP-EQUIV="VW96.OBJECT TYPE" CONTENT="Document">
<META NAME="RATING" CONTENT="General">
<META NAME="ROBOTS" CONTENT="homepage,follow">
<META NAME="REVISIT-AFTER" CONTENT="1 days">
<link rel="stylesheet" href="skin1.css">
</head>
<body LEFTMARGIN=0 TOPMARGIN=0 RIGHTMARGIN=0 BOTTOMMARGIN=0 MARGINWIDTH=0 MARGINHEIGHT=0>
<? include("includes/header.php"); ?><tr>
<td width="778" height="100%" bgcolor="#FFFFFF" valign="top" colspan="2">
<table border=0 width="778" cellpadding=5 cellspacing=0>
<tr>
<td>
<!-- main area -->
<table border=0 width="100%" cellpadding=0 cellspacing=0 align="center">
<tr>
<td width=6 rowspan="2"> </td>
<td width=150 valign=top rowspan="2">
<TABLE WIDTH=150 BORDER=0 CELLPADDING=0 CELLSPACING=0>
<TR>
<td width=150 valign=top rowspan="2">
<TABLE WIDTH=150 BORDER=0 CELLPADDING=0 CELLSPACING=0 id="table55">
<TR>
<TD>
<IMG SRC="images/menu_01.jpg" WIDTH=150 HEIGHT=5 ALT="teenfront"></TD>
</TR>
<TR>
<TD background="images/menu_bg.jpg">
<TABLE WIDTH="150" BORDER=0 CELLPADDING=0 CELLSPACING=0 id="table56">
<tr>
<TD>
<IMG SRC="images/menu_02.jpg" WIDTH=41 HEIGHT=27 ALT="Website Templates"></TD>
<TD background="images/menu_03.jpg" width="109" class="VertMenuTitle">
<p align="center"><font class=VertMenuTitle>
Navi Bar</font></TD>
</tr>
<TR>
<TD COLSPAN=2 class="VertMenuBox"><center>
<? include("includes/menu.php"); ?></center>
</TD></TR>
</TABLE>
<TABLE WIDTH="150" BORDER=0 CELLPADDING=0 CELLSPACING=0 id="table62">
<TR><TD>
<IMG SRC="images/menu_02.jpg" WIDTH=41 HEIGHT=27 ALT="Website Templates"></TD>
<TD background="images/menu_03.jpg" width="109" class="VertMenuTitle">
<p align="center"><font color="#FFFFFF"><span lang="en-gb">Your info</span></font></TD>
</TR>
<TR>
<TD COLSPAN=2 class="VertMenuBox"><center>
<table border=0 class="VertMenuBox" cellpadding=7 width="150" id="table63">
<tr><td><TABLE border=0 cellPadding=0 cellSpacing=0 width=100% id="table64">
<FORM action="/store/include/login.php" method=post name=authform>
<tr>
<td class=VertMenuItems>
<br>
</td></tr>
</form>
</table>
</td></tr>
</table></center>
</TD></TR>
</TABLE>
<TABLE WIDTH="150" BORDER=0 CELLPADDING=0 CELLSPACING=0 id="table65">
<TR><TD>
<IMG SRC="images/menu_02.jpg" WIDTH=41 HEIGHT=27 ALT="Website Templates"></TD>
<TD background="images/menu_03.jpg" width="109" class="VertMenuTitle">
<p align="center"><span lang="en-gb">Shout</span></TD>
</TR>
<TR>
<TD COLSPAN=2 class="VertMenuBox"><center>
<table border=0 class="VertMenuBox" cellpadding=7 width="150" id="table66">
<tr><td><TABLE border=0 cellPadding=0 cellSpacing=0 width="91%" id="table67">
<FORM action="/store/include/login.php" method=post name=authform0>
<tr>
<td class=VertMenuItems>
<p align="center"> </td></tr>
</form>
</table>
</td></tr>
</table></center>
</TD></TR>
</TABLE>
<!-- Start Network Box -->
<TABLE WIDTH=150 BORDER=0 CELLPADDING=0 CELLSPACING=0 id="table60">
<TR>
<TD>
<IMG SRC="images/menu_02.jpg" WIDTH=41 HEIGHT=27 ALT=""></TD>
<TD background="images/menu_03.jpg" width="109" class="VertMenuTitle">
<p align="center"><span lang="en-gb"><font color="#FFFFFF">Free Ringtone</font></span></TD>
</TR>
<TR>
<TD COLSPAN=2 background="images/menu_bg.jpg" class="VertMenuBox"><br>
<center>
<table border=0 class="VertMenuBox" id="table61">
<tr><td>
<script language="javascript">
var uri = 'http://impgb.tradedoubler.com/imp/img/649889/750786?' + new String (Math.random()).substring (2, 11);
document.write('<a href="http://clkuk.tradedoubler.com/click?p=19134&a=750786&g=649889" target="_blank"><img src="'+uri+'" border=0></a>');
</script> </center>
</td></tr>
</table>
</center>
</TD>
</TR>
</TABLE>
<!-- End Network Box -->
</TD>
</TR>
<TR>
<TD><IMG SRC="images/menu_05.jpg" width="150" ALT="Website Templates"></TD>
</TR>
</TABLE>
</td>
<TD>
</TD>
</TR>
<TR>
<td width=150 valign=top>
</td>
<TD background="images/menu_bg.jpg">
<!-- Start Network Box -->
<!-- End Network Box -->
</TD>
</TR>
<TR>
<TD> </TD>
</TR>
<TR>
<TD> <br><center><script language="javascript">
var uri = 'http://impgb.tradedoubler.com/imp/img/18412/750786?' + new String (Math.random()).substring (2, 11);
document.write('<a href="http://clkuk.tradedoubler.com/click?p=3526&a=750786&g=18412" target="_blank"><img src="'+uri+'" border=0></a>');
</script></center></TD>
</TR>
</TABLE>
</td>
<td width=20 rowspan="2"> </td>
<td valign=top>
</td>
<td width=6 rowspan="2" valign="top">
</td>
</tr>
<tr>
<td valign=top>
<table style="border-collapse: collapse;" id="table35" border="0" bordercolor="#111111" cellpadding="5" cellspacing="0" width="100%">
<tr>
<td width="100%" colspan="2">
<table style="border-collapse: collapse;" id="table37" border="2" bordercolor="#2a66c9" cellpadding="0" cellspacing="1" width="100%">
<tr>
<td bordercolor="#FFFFFF" bgcolor="#2A66C9" width="75%"><center>
<span lang="en-gb"><b>
<font face="Verdana" size="2" color="#FFFFFF">Welcome
To Teenfront</font></b></span></div>
</center></td>
</tr>
<tr>
<td bordercolor="#FFFFFF" bgcolor="#C7D5F5" width="100%">
<p class="welcome" align="center"><span lang="en-gb">
<font color="#000000"><b>
Teenfront.co.uk</b> are the UK's Premier teen community,
offering excellent Teen based chat rooms, Massive web based
forums , Great film reviews and trailers, Music reviews and
videos Star signs and loads loads more! So invite your
friends to join up and join in the <b>teenfront experience</b>
!</font><br></span><div align="center">
<table border="2" width="90%" id="table54" bordercolor="#2A66C9">
<tr>
<td bgcolor="#000080">
<p align="center" class="welcome">
<font color="#FFFFFF">
<span lang="en-gb"><b>This weeks featured
section is : </b><a href="chat.php">
<font color="#FFFFFF">The Chat room</font></a>
<font face="Verdana">»</font></span></font></td>
</tr>
</table>
<br></div>
</div>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="50%">
<table style="border-collapse: collapse;" id="table52" border="2" bordercolor="#2a66c9" cellpadding="0" cellspacing="1" width="100%">
<tr>
<td bordercolor="#ADD9F5" bgcolor="#2A66C9" width="34%"><center>
<span lang="en-gb"><b>
<font face="Verdana" size="2" color="#FFFFFF">New Win Zone</font></b></span></div>
</center></td>
</tr>
<tr>
<td bordercolor="#ADD9F5" bgcolor="#C7D5F5" width="100%">
<span lang="en-gb"><div align="center"><p class="welcome">
<b>Win "Just for you" Album!<br></b><br >
<img border="0" src="images/justforyou.PNG" width="160" height="46"></div>
<div align="center">
<p class="welcome">
We have a cool new site section! The Win Zone, check it
out for all the latest teenfront.co.uk comps!<a href="http://www.teenfront.co.uk/forum/win.php">
Checkout our great new win zone!</a></span></div></p>
</td>
</tr>
</table>
</td>
<td width="50%">
<table style="border-collapse: collapse;" id="table68" border="2" bordercolor="#2a66c9" cellpadding="0" cellspacing="1" width="100%">
<tr>
<td bordercolor="#FFFFFF" bgcolor="#2a66c9" width="75%"><center>
<span lang="en-gb"><font size="2" color="#FFFFFF"><b>MyRadio</b></font></span></div>
</center></td>
</tr>
<tr>
<td bordercolor="#FFFFFF" bgcolor="#C7D5F5" width="75%">
<p class="welcome" align="center">
<br>
<img border="1" src="http://www.sonnerie.net/js/img_top_box/icone_enceinte1.gif" ><p class="welcome" align="center">
<span lang="en-gb"><b>Teenfront.co.uk </b>Launches there very own
radio stream! Partnering with Galaxy105, listen to great
music 24/7 ! Login and check out your "MyRadio" Link
at the top of the page! Listen live to great music 24/7 <br></span></td>
</tr>
</table>
</td>
</tr>
</table>
<!-- End Creative Public Box -->
<div align="center">
<table border="0" width="100%" id="table42" style="border-collapse: collapse">
<tr>
<td> <table style="border-collapse: collapse;" id="table47" border="0" bordercolor="#111111" cellpadding="5" cellspacing="0" width="100%">
<tr>
<td width="50%">
<table style="border-collapse: collapse;" id="table48" border="2" bordercolor="#2a66c9" cellpadding="0" cellspacing="1" width="100%">
<tr>
<td bordercolor="#ADD9F5" bgcolor="#2a66c9" width="34%"><center>
<span lang="en-gb"><b>
<font face="Verdana" size="2" color="#FFFFFF">Free SMS Text
Messaging</font></b></span></div>
</center></td>
</tr>
<tr>
<td bordercolor="#ADD9F5" bgcolor="#C7D5F5" width="34%">
<p class="welcome" align="center">
<br><a href="http://teenfront.fonetastic.com/sms/v1/"><img alt="mobile" border="1" src="moby.gif"></a><p class="welcome" align="center">
<span lang="en-gb"><b>Teenfront.co.uk</b> now offer great FREE
UK SMS Text Messaging, that means that you can send free text
messages to <b>any </b>mobile, <b>any</b> time, <b>for free</b>!<br>
<font face="Verdana">
<a href="http://teenfront.fonetastic.com/sms/v1/">» Go</a></font></span></td>
</tr>
</table>
</td>
<td width="50%">
<table style="border-collapse: collapse;" id="table49" border="2" bordercolor="#2a66c9" cellpadding="0" cellspacing="1" width="100%">
<tr>
<td bordercolor="#FFFFFF" bgcolor="#2a66c9" width="75%"><center>
<span lang="en-gb"><font size="2" color="#FFFFFF"><b>Free
Teen Webmail</b></font></span></div>
</center></td>
</tr>
<tr>
<td bordercolor="#FFFFFF" bgcolor="#C7D5F5" width="75%">
<p class="welcome" align="center">
<br><a href="http://www.teenmail.co.uk"><img alt="Teenmail.co.uk" border="1" src="card.gif"></a><p class="welcome" align="center">
<span lang="en-gb">Teenmail.co.uk - part of The Teenfront
Group , Bring you the ultimate in teen email! Get your very
own free, web-based @teenmail.co.uk email address !<br>
<font face="Verdana"><a href="http://www.teenmail.co.uk/">»
Go<br></a></font></span></td>
</tr>
</table>
</td>
</tr>
</table>
<center><script language="javascript">
var uri = 'http://impgb.tradedoubler.com/imp/js/451149/750786?' + new String (Math.random()).substring (2, 11);
document.write('<sc'+'ript language="JavaScript" src="'+uri+'" charset="ISO-8859-1"></sc'+'ript>');
</script></center></td>
</tr>
</table>
</div>
</td>
</tr>
</table>
</TD>
</TR>
<TR>
<TD>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="778" colspan="2">
<img src="images/bottombar.jpg" border=0 alt="teenfront"></td>
</tr>
<tr>
<td width="780" colspan="2" bgcolor="#2A66C9">
<p class="copyright">
<font size="1"><a class="white" href="homepage.php">Home</a>
| <span lang="en-gb"><a href="privacy.php"><font color="#FFFFFF">Privacy</font></a></span>
| <span lang="en-gb"><a href="advertising.php"><font color="#FFFFFF">Advertising</font></a></span>
| <span lang="en-gb"><a href="contactus.php"><font color="#FFFFFF">Contact us</font></a></span> <span lang="en-gb">
<font face="Verdana">| Copyright© The Teenfront Group 2005</font></span>
</font>
</td>
</tr>
</table>
</div></TD></TR>
</TABLE></body>
</html>
<?php
break;
}
?>feyd | Please use
Code: Select all
andCode: Select all
tags where approriate when posting code. Read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url][/color]