Guest Posted October 10, 2006 Posted October 10, 2006 I have created an interactive ipod for my site which visitors can use to navigate to a particular section (ie ipod cases). Have created a .php page for it but when i try moving it to where the content is i get the following message "Parse error: parse error, unexpected '<' in /home/fhlinux183/p/pcsolutions-navigation.co.uk/user/htdocs/shop/includes/languages/english/ipod.php on line xx" I have moved it back so the page works now but i need to move it under the text in the main content area. My web page address is here Can anyone help me? I think i am missing someting or need to comment something out. Anyhelp will be greatly appreciated! :) Thanks in advance Phil Brooke
ComicWisdom Posted October 10, 2006 Posted October 10, 2006 If you have it programmed in html, which is what it looks like, you need a "?>" before it and a "<?php" after it. Just between us, remember there are only 10 kinds of people in the world; those who understand binary and those who don't!! Remember, learning is a "do-it-yourself" experience; although, not necessarily a "do-it-BY-yourself" experience. The quickest way to learn is to forget to BACKUP!
Guest Posted October 10, 2006 Posted October 10, 2006 If you have it programmed in html, which is what it looks like, you need a "?>" before it and a "<?php" after it. Thank you very much, that stopped the errors. However I cant seem to get the ipod to the content area of the screen, any ideas. Cheers Phil Brooke
squeekit Posted October 11, 2006 Posted October 11, 2006 i'm tempted to help but... - i hate dreamweaver - your page has TONS of problems here - 2 things.... let's start simple: - 1 - your generated html is all over the place and ignores the basics of html structure example: the following: [ _EDIT_ ] //--> </script> <body onLoad="MM_preloadImages('images/i1a.jpg','images/i2a.jpg','images/i3a.jpg','images/i4a.jpg','images/i5a.jpg')"><br /> <br /> <br /> <table width="34%" height="415" border="0" cellpadding="1" cellspacing="1"> <tr> <td valign="top" background="images/ipodbg.jpg"><br /> [ _EDIT_ ] appears above: [ _EDIT_ ] </table> <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN"> <html dir="LTR" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>PCSN, Hull | Delivering The Latest Technology</title> <base href="http://www.pcsolutions-navigation.co.uk/shop/"> <link rel="stylesheet" type="text/css" href="stylesheet.css"> </head> <body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0"> <!-- header //--> <style type="text/css"> <!-- [ _EDIT_ ] why do you have 2 "body" tags - why does some info that should be in the html "head" appear outside the html "head" -- etc. etc. as i said i hate dreamweaver - the effort that goes into learning dreamweaver could more effectively be spent learning proper html - when editing with plain text you have total control and doing such is realatively easy... - 2 - small note - as well notice the line in the first code i quoted <td valign="top" background="images/ipodbg.jpg"><br /> this causes the backgound image to repeat - such would be much better handled with 'style' (css) like so: background: url(images/ipodbg.jpg) no-repeat; because i see the background image repeating a bit and i can tell that is not what you want... i love helping folks as you can see in my other post but, well, the most help i could give you is to urge you to learn more about proper html and css --- sorry - but if you do then you'll find a great freedom in making pages display and behave the way you want them to - otherwise you will continue to encounter problems... here are some great resources to get you started: HTML Tutorial CSS Tutorial they both start out real simple and before you know it you learned a bunch of advanced stuff ;) both from one of the best sites on the web for quick learning, W3Schools. please understand this is what i think would be the most help - other than rewriting you whole page/code -- you got to get that php to at least generate good html...
squeekit Posted October 11, 2006 Posted October 11, 2006 yes... looks much much better now... html source and resulting display. you've still got some major html source issues that should be addressed - but... as far as popping links into your "ipod" you can change: <td class="main"><br> <table width="250" height="410" border="0" align="center" cellspacing="0" cellpadding="0"> <td valign="center" background="images/ipodbg.jpg"></td> </tr> </table></td> to... <td class="main"><br> <table width="250" height="413" border="0" align="center" cellspacing="0" cellpadding="0" background="images/ipodbg.jpg"> <tr> <td rowspan="2" width="48"> </td> <td width="*%" height="50"> </td> <td rowspan="2" width="46"> </td> </tr> <tr> <td class="ipodlinks" valign="top" height="108"> <a href="whatever1">link1</a><br> <a href="whatever2">link2</a><br> <a href="whatever3">link3</a> </td> </tr> <tr> <td colspan="3">?</td> </tr> </table></td> then define the class "ipodlinks" to get those links to display as desired. example: td.ipodlinks a { font-weight: bold; text-decoration: none; } as i said your html source is now vastly improved but still: W3C Markup Validator (for your page) not every problem listed there needs to be addressed - but i would at least remedy the issues concerning improper html tag placement...
squeekit Posted October 11, 2006 Posted October 11, 2006 actually (without looking too much into it), that link: "W3C Markup Validator (for your page)" might be a faulty read given its attempt to read your php generated code (i don't know). but you gotta at least remedy the issues concerning improper html tag placement (and missing tags - etc.)...
squeekit Posted October 13, 2006 Posted October 13, 2006 ah - i see you're using the example i provided - looks decent enough - however, realize the example is merely intended for the resulting php generated html source and the links should be php'ed in using the link function of osc's html_output.php: tep_href_link the reason for such is that if a member is logged in and they click a link that does not get processed by the tep_href_link function then that member might be logged out or open pages as if they are logged out... so for each link your php code should look something like this... <a href="<?php echo tep_href_link(FILENAME_LINKED_TO); ?>">LINKNAME</a> something like that - you'll have to customize such for your shop and individual links
Recommended Posts
Archived
This topic is now archived and is closed to further replies.