Wrox Programmer Forums
|
BOOK: Beginning PHP 6, Apache, MySQL 6 Web Development ISBN: 9780470391143
This is the forum to discuss the Wrox book Beginning PHP 6, Apache, MySQL 6 Web Development by Timothy Boronczyk, Elizabeth Naramore, Jason Gerner, Yann Le Scouarnec, Jeremy Stolz; ISBN: 9780470391143
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP 6, Apache, MySQL 6 Web Development ISBN: 9780470391143 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 10th, 2009, 03:13 PM
Registered User
 
Join Date: Aug 2009
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chapter 4 movie_details.php

I have entered the code for the above file but whenever I try to run it I get the following message

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near " at line 6

I have tried downloading the code from the website but I get the same message when I try and run the downloaded file.

Can anyone help?
 
Old September 15th, 2009, 10:50 PM
Registered User
 
Join Date: Aug 2009
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation Identifying and pickOut the problems

Firstly you need to identify what is on your line 6?

Tips:
To be more efficient in solving the problem u need to Identify the exact Line with the error.

1st - Qoute the browser's Error Message
2nd - Qoute the Lines of codes involve in the Error Message (altho. sometimes you need to qoute the whole Chunk of codes)
3rd - If you are following the BOOK closely, please also state the Page No.

4th - Wait for reply from some helpful/resourceful reader.
5th - Dont forget to thank them if they solve your problems

If you dont qoute/pickout the problems what you Posted will be Jibberish and can't be help by others.

GoodLuck

Just my 2cents
-Slim, WebProgrammerWannabe
 
Old January 2nd, 2010, 05:16 PM
Authorized User
 
Join Date: Jan 2010
Posts: 19
Thanks: 0
Thanked 4 Times in 4 Posts
Default

Hi bobg,

Please re-read page 124.

Step 2 states to save the file as movie_details.php and upload it to the web server... It does not state to open movie_details.php in a web browser.

Step 3 states to open table3.php in a web browser which will then call the movie_details.php file when a link is clicked.

I ran into the same problem because I did not read step 3...
 
Old March 17th, 2011, 05:58 PM
bcb bcb is offline
Registered User
 
Join Date: Mar 2011
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default Solved: movie_details.php syntax error line 6

I ran into the same error as Bobg. I found the error went away when I edited the table3.php around line 99. I did not notice that on page 118 the heredoc is changed from ENDHTML to ENDINFO (not sure if that matters, but it was not highlighted as a change in the book.

I also had tried to use the Tooltips code on page 119, but when using this I received the
"You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near " at line 6" When I used the original code without the tooltip, everything worked. Hope this helps someone down the road.

$table .= <<<ENDINFO
<tr>
<td> <a href="movie_details.php?movie_id=$movie_id"> $movie_name </a> </td>

<td>$movie_year</td>
<td>$director</td>
<td>$leadactor</td>
<td>$movietype</td>
</tr>
ENDINFO;





Similar Threads
Thread Thread Starter Forum Replies Last Post
movie_details.php issues gargamel BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 12 October 24th, 2010 06:02 AM
Chapter 4 movie_details.php help ilovesloth BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 1 April 12th, 2009 04:32 PM
begin php & mysql - chapter 12, user_form.php jon_stubber Beginning PHP 1 March 9th, 2006 10:57 AM
Chapter 4 P124 - movie_details Pheeal Beginning PHP 0 January 27th, 2006 10:16 AM
need help with movie_details.php code kjames1973 BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 3 December 26th, 2004 04:28 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.