Ready to get started?Download WordPress


[resolved] Permalinks and getting the ID. Which file (3 posts)

  1. Chrome Orange
    Posted 4 years ago #


    Where does wordpress conver the URL http://www.domain.com/%postname%/
    into http://www.domain.com/?p=ID


    Where does wordpress take %postname% and query the database to find the right post/page??

    I'm trying to modify how it does this so I can have a custom permalink that includes additional info


  2. Bill Erickson
    Posted 4 years ago #

    You can set the default permalink options in Settings > Permalinks.

    For something more advanced you'll have to use WP Rewrite Rules ( http://codex.wordpress.org/Function_Reference/WP_Rewrite ). They're a bit difficult to work with, but that page should get you started. I also highly recommend searching http://wordpress.stackexchange.com for posts on rewrite rules - that's where I look when I'm trying to mess with them.

  3. Chrome Orange
    Posted 4 years ago #

    Absolutely fan-bloody-tastic!

    WP Rewrite Rules was what I needed (along with a bit of htaccess tweeking. That codex article was perfect.

    Thank you

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.