query string - Getting querystring parameter value in wordpress -


I am creating a WordPress plugin, in anchors to load the content based on the link I clicked on the user Add_query_string () is used. Now I need to know the best way to get the parameter value in the current URI.

This is probably a very basic and stupid question, but I'm new to programming, so I'm sorry if I have something wrong

  if (current_user_can ( & Lt; li & gt; & lt; a href = "'Add_query_arg (' adminoption ', 1).' '' Manage_options ')) {echo (' 
& Gt; Option 1 & lt; / li & gt; & lt; li & gt; & lt; a href = "'. Add_query_arg (' adminoption ', 2).' '& Gt ; Option 2 & lt; / a & gt; & lt; / li & gt; & lt; / ul & gt; & lt; / div & gt; ';); // if adminoption == 1 load content A // if adminoption == 2 load content b}

I think that you are asking for the ceremony in your case you should use get_query_var ('adminoption'). Hope it helps

Comments

Popular posts from this blog

java - NullPointerException for a 2d Array -

python - Assemble mpeg file unable to play in mediaplayer -

c# - NameSpace Manager or XsltContent to parse aspx page -