affordit Posted February 5, 2008 Share Posted February 5, 2008 Whats wrong with this link <a href="?prod=' . $_GET['prod'] . '&page=<?php echo( $nextPage ); ?>">Next</a> Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/ Share on other sites More sharing options...
haku Posted February 5, 2008 Share Posted February 5, 2008 You are starting your link with the variables, but don't have any page name in there. You need something before the question mark. Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458874 Share on other sites More sharing options...
affordit Posted February 5, 2008 Author Share Posted February 5, 2008 The page name is itself Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458879 Share on other sites More sharing options...
haku Posted February 5, 2008 Share Posted February 5, 2008 But the link doesn't know that unless you put it in there. Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458880 Share on other sites More sharing options...
revraz Posted February 5, 2008 Share Posted February 5, 2008 Looks like you are trying to use variables outside the PHP tags. Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458881 Share on other sites More sharing options...
haku Posted February 5, 2008 Share Posted February 5, 2008 My bad. The question mark should actually be fine as it is. You need to enclose your $_GET variable in php tags. Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458883 Share on other sites More sharing options...
affordit Posted February 5, 2008 Author Share Posted February 5, 2008 Thanks revraz I totally missed that Quote Link to comment https://forums.phpfreaks.com/topic/89570-solved-syntax-error/#findComment-458884 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.