|Connecting one page by foreign key [message #97391]
||Wed, 14 April 2010 20:38
Registered: April 2010
I'm trying to create a movie database site and want to have a list of movie genres that has a link that takes you to a site of movies within that genre. I'm having trouble getting the genre id from the genre page and passing it to the function in my movietable.class.php file. Here is the code I currently have in that file:|
class MovieTable extends Doctrine_Table
public function getMovieByGenre()
$q = $this->createQuery('m')
->where('m.genre_id = 1', );
The one was just a place holder to test to see if the function worked but now I need the code to get the genre id from the link from the genre page.
If anyones got any advice or knows something that would help fix my problem that would be great.