Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 8 of 8
  1. #1
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    7
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Problem with Coding - PHP/HTML/CSS - Not showing page

    Hello,
    My friend recently taught me how to code links in php.. Because well.. Its one of the safest ways to code your links. Or so im told.

    Quite a long story short... I'v got this template off a site.. Its coded in html/css.. Yet I want the links in PHP.. So iv changed the format to php, added where the links are ment to be.. added the tags <?php and ?>

    But I keep getting the error:
    Code:
    Parse error: syntax error, unexpected '<' in /home/keanu/domains/aro-server.co.uk/public_html/radio/index.php on line 18
    Here is the entire code for that page;

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html>
    <head>
    <title>ARO-Radio</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <link href="style.css" rel="stylesheet" type="text/css" />
    </head>
    <body>
    <div id="container">
    <div id="header">
    <div id="logo">
    		
    </div>
    <div id="topright">
    <div id="nav">
    <ul>
    <?php
    <a href="iframe.php?load=news" target="iframe">Home</a>
    <a href="iframe.php?load=Feature_Bands" target="iframe">Featured Bands</a>
    <a href="iframe.php?load=DJ_Panel" target="iframe">DJ PANEL</a>
    <a href="iframe.php?load=Forum" target="iframe">Forum</a>
    <a href="iframe.php?load=About" target="iframe">About Us</a>
    <a href="iframe.php?load=Contact" target="iframe">Contact Us</a>
    ?>
    </ul>
    <div style="clear:both"></div>
    </div>
    <div id="contenttr"></div>
    </div>
    </div>
    <div id="bottom">
    <div id="csoon">
    <div class="heading2"></div>
    </div>
    <div id="videobox"></div>
    <div id="player">
    <img src="images/circle-topl.jpg" alt="Stop" class="player1" />
    <img src="images/circle-topr.jpg" alt="Play" class="player1" />
    <img src="images/circle-bottoml.jpg" alt="Pause" class="player1" />
    <img src="images/circle-bottomr.jpg" alt="F.Forward" class="player1" />
    </div>
    <div id="footer">
    <ul>
    <?php
    <a href="iframe.php?load=news" target="iframe">Home</a>
    <a href="iframe.php?load=Feature_Bands" target="iframe">Featured Bands</a>
    <a href="iframe.php?load=DJ_Panel" target="iframe">DJ PANEL</a>
    <a href="iframe.php?load=Forum" target="iframe">Forum</a>
    <a href="iframe.php?load=About" target="iframe">About Us</a>
    <a href="iframe.php?load=Contact" target="iframe">Contact Us</a>
    ?>
    </ul><br /><br />
    <p class="calign">&copy; Copyright ARO-Radio 2007-2008.</p>
    </div>
    </div>	
    </div>
    </body>
    </html>
    Sorry if this is posted in the wrong section.. Due to it being a problem with PHP... I thought... I should stick it in the PHP section..

    -Keanu

  • #2
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    try this:
    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html>
    <head>
    <title>ARO-Radio</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <link href="style.css" rel="stylesheet" type="text/css" />
    </head>
    <body>
    <div id="container">
    <div id="header">
    <div id="logo">
    		
    </div>
    <div id="topright">
    <div id="nav">
    <ul>
    <a href="iframe.php?load=news" target="iframe">Home</a>
    <a href="iframe.php?load=Feature_Bands" target="iframe">Featured Bands</a>
    <a href="iframe.php?load=DJ_Panel" target="iframe">DJ PANEL</a>
    <a href="iframe.php?load=Forum" target="iframe">Forum</a>
    <a href="iframe.php?load=About" target="iframe">About Us</a>
    <a href="iframe.php?load=Contact" target="iframe">Contact Us</a>
    </ul>
    <div style="clear:both"></div>
    </div>
    <div id="contenttr"></div>
    </div>
    </div>
    <div id="bottom">
    <div id="csoon">
    <div class="heading2"></div>
    </div>
    <div id="videobox"></div>
    <div id="player">
    <img src="images/circle-topl.jpg" alt="Stop" class="player1" />
    <img src="images/circle-topr.jpg" alt="Play" class="player1" />
    <img src="images/circle-bottoml.jpg" alt="Pause" class="player1" />
    <img src="images/circle-bottomr.jpg" alt="F.Forward" class="player1" />
    </div>
    <div id="footer">
    <ul>
    <a href="iframe.php?load=news" target="iframe">Home</a>
    <a href="iframe.php?load=Feature_Bands" target="iframe">Featured Bands</a>
    <a href="iframe.php?load=DJ_Panel" target="iframe">DJ PANEL</a>
    <a href="iframe.php?load=Forum" target="iframe">Forum</a>
    <a href="iframe.php?load=About" target="iframe">About Us</a>
    <a href="iframe.php?load=Contact" target="iframe">Contact Us</a>
    </ul><br /><br />
    <p class="calign">&copy; Copyright ARO-Radio 2007-2008.</p>
    </div>
    </div>	
    </div>
    </body>
    </html>
    think the issue was in your addition of the <?php ?> tags

  • #3
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    7
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Hey,
    Thank you for your help!

    Looks like its working now.. but its stacking downwards? when it used to stack across?... Any way to fix that?

    Thanks in advance!
    -Keanu

  • #4
    Senior Coder Nightfire's Avatar
    Join Date
    Jun 2002
    Posts
    4,265
    Thanks
    6
    Thanked 48 Times in 48 Posts
    For your css you'd have
    Code:
    #nav li{
        display:inline;
    }
    Code:
    <div id="nav">
    <ul>
    <li><a href="iframe.php?load=news" target="iframe">Home</a></li>
    <li><a href="iframe.php?load=Feature_Bands" target="iframe">Featured Bands</a></li>
    <li><a href="iframe.php?load=DJ_Panel" target="iframe">DJ PANEL</a></li>
    <li><a href="iframe.php?load=Forum" target="iframe">Forum</a></li>
    <li><a href="iframe.php?load=About" target="iframe">About Us</a></li>
    <li><a href="iframe.php?load=Contact" target="iframe">Contact Us</a></li>
    </ul>

  • #5
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    7
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Hey,

    Thanks for the help!
    Im having one more tiny problem...
    Code:
    http://www.radio.aro-server.co.uk/index1.php
    .. You see "Featured Bands" Is there any way to make that onto one line? And the ones beside it.. Where you roll over them.. And they go normal? Is there any way to make them stay like the one saying "DJ PANEL"

    Once agian, thanks in advance!
    -Keanu
    Last edited by Keanu; 03-20-2007 at 07:11 PM.

  • #6
    Senior Coder
    Join Date
    Jan 2007
    Posts
    1,648
    Thanks
    1
    Thanked 58 Times in 54 Posts
    Because well.. Its one of the safest ways to code your links. Or so im told.
    It is?

  • #7
    New to the CF scene
    Join Date
    Mar 2007
    Posts
    7
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by aedrin View Post
    It is?
    Yeah.. Or so im told.. Because they can't actually see the file or where the file is stored.. So if your really safe-freak.. You could have something like "newfolder"x30 then the file..

    They'd never get it...

    -Keanu

  • #8
    Senior Coder
    Join Date
    Jan 2007
    Posts
    1,648
    Thanks
    1
    Thanked 58 Times in 54 Posts
    I suppose in regards to that it is "safer". Even though you're sending it to the user anyway, so I'm not sure what you're preventing.

    Remember that when you're including something that contains user input (anything from _GET/_POST), that you do some serious filtering to ensure people can't insert things they shouldn't.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •