Fiji Web Design
Welcome, Guest
Please Login or Register.    Lost Password?
Re:Variable in URL (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: Re:Variable in URL
#1072
thibzh (User)
Fresh Boarder
Posts: 1
graphgraph
User Offline Click here to see the profile of this user
Variable in URL 2 Years, 3 Months ago Karma: 0  
Hi,

Is it possible to use the get function to take a variable in the URL.

For example, with this link <a href="index.php?option=com_test&catid=100">Paris</a>
is it possible to use the get function into the module like this to take the catid variable?

<?php echo 'test - '.$_GET['catid']; ?>

Thank you,

Thibzh
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#1073
admin (Admin)
Admin
Posts: 475
graph
User Online Now Click here to see the profile of this user
Re:Variable in URL 2 Years, 3 Months ago Karma: 10  
Yes, you can. You can also use the Joomla API which would be the recommended way:

$catid = JRequest::getInt('catid');
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
Go to top Post Reply
Powered by FireBoardget the latest posts directly to your desktop

Joomla Downloads

DownloadsDownload our free Joomla! Components, Modules and Plugins.