WordPress.org

Forums

[resolved] URL Parameter Help! (3 posts)

  1. freshifreshy
    Member
    Posted 3 years ago #

    I need to get the parameters 'offset' and 'cat' from a URL that looks like this:

    /?page_id=87/?offset=3&cat=2

    With a custom permalink structure, I could just use $_GET['offset'] to retrieve the value, but this doesn't work with the default permalink structure.

    I'd like to achieve this without the use of plugins.

    Any guidance would be appreciated!

  2. Glenn Ansley
    Member
    Posted 3 years ago #

    Your URL looks malformed to me. Shouldn't it be /?page_id=87&offset=3&cat=2

    I imagine your $_GET['offset'] will work after you fix that.

  3. freshifreshy
    Member
    Posted 3 years ago #

    Doh, you're right. Thanks for pointing that out. Works now!

Topic Closed

This topic has been closed to new replies.

About this Topic