WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Inside a WordPress site I load a external xml file parse it and show some links. The link looks like this:
This works, but now i would like the url to look like this:
when I create a link to that url and click it it says it kind find the page. However if i just put the guid in and forget about the title it works:

can anyone point me in the right direction?

share|improve this question
is the url always prof/vac ? I assume prof and vac are pages and vac has a unique page template – Tom J Nowell Nov 16 '11 at 15:25
up vote 0 down vote accepted

You can use the details here in this answer to solve your problem :

Pretty URL with add_query_var

Something along the lines of

add_rewrite_endpoint('item', array(EP_PAGES)); 

resulting in a rewrite rule that would let you use /prof/vac/item/1234 which you would then check in the vac pages template for a query variable 'item' and pull its value ( in this case 1234 )

Of course one must then avoid having a page with the slug 'item' else bad things will happen.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.