Figure 4-6 Next, you define the $movie_details variable. (Web hosting packages)

Figure 4-6 Next, you define the $movie_details variable. This should be fairly self-explanatory. Remember the $movie_table_headings variable you created previously? All you ve done is slot it into place within the $movie_details variable and, hey presto, it appears. Finally, you define the $page_end variable and bring it all together in the closing lines. Phew! That was a lot of code there! Now is a good time to take a break and reward yourself (mine s coffee with milk and two sugars, thanks). A Lasting Relationship What if you wanted to find all the reviews for a particular movie? As it stands, you d need to create a new SQL query in the movies_details.php page and execute it when the page loads, which would make a total of two SQL queries in one page. It would work, but it would not be very efficient. (We re all efficient coders, aren t we?) This also results in unnecessary code. 128 Chapter 4
Note: In case you are looking for affordable and reliable webhost to host and run your j2ee application check Vision j2ee hosting services

Leave a Reply