WordPress.org

Ready to get started?Download WordPress

Forums

Passing rest of url on as parameter (1 post)

  1. hgrianevans
    Member
    Posted 1 year ago #

    I'm just starting to wrap my head around passing custom parameters in page templates to WP but as my middle name should be "SucksAtRegex", how would I tell WP to pass everything after examplepage to WP as one variable.

    E.g. examplepage/123/12/2 would end up passing '/123/12/2' as the mypath variable. I can then explode that in PHP and deal with it accordingly. I already use this method outside of WP, but I'm looking to move to WP as my CMS.

Topic Closed

This topic has been closed to new replies.

About this Topic