In Wordpress, how can a page display the parameter that was sent to it

A WP page is being linked to from some posts and it appears that it can be improved by setting the posts to use a text parameter, like :

http://www.example.com/thepage?param=text1

I couldn't find how I can display this 'text1' parameter from within the page - if at all possible.

Your help is much appreciated.

Answers


Find the template being used for that page. You can grab the value in the header OR in the body. If you simply want to display this value use the following code.

If you want to use it as a variable for some other purpose, assign it to a variable.


if you just want to get the text1 parameter you can use

 if (isset($_GET['param'])) {
     // $_GET['param'] is equal to text1
     echo $_GET['param'];
 }

Need Your Help

Remote Control (from the webpage) for a Media Player on remote machine?

php control media-player flowplayer

I just want a interface like a controller which can control "Play/Pause/Stop/ ..etc" for some kind of player (Flash or anything else) playing on a remote server, across "HTTP" under same domain.

editing mode UITableView, cant prevent movement of content view to right

ios uitableview

In my chat application, i can't prevent movement of some content views to right, on screenshot blue bubble with text movement to right in edit mode, can anyone help me?

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.