I'm trying to create a "profile page" of sorts for users that I want to use the URL structure:


The system does NOT user the default WordPress users.

I've not attempted this yet as I've got no idea where to start! I'd prefer it if this page wasn't a Wordpress "Page" and I'd like for it to be created via my plugin's profile.php file (That contains the profile class). The username is stored in the site's SESSION so it doesn't need any variables. I just need to link a URL to a template without using WordPress pages, really :P

I'm not sure what information to provide so if there's something I've missed please let me know :)

1 Answer 1


This really isn't the best use for wordpress. You are better off creating a custom post type called "profile" (see https://codex.wordpress.org/Function_Reference/register_post_type or use a plugin like PODS) and then the URL rewrites are all done for you. You can enable / disable the archive page so that domain.com/profile lists all profiles or not at all.

Then add post meta (see https://codex.wordpress.org/Function_Reference/add_post_meta) to your custom post type for extra fields you may want. I would recommend using ACF (Advanced Custom Fields) for this. ACF is a great tool for rapidly creating advanced meta fields for specific scenarios.

In any case, don't waste your time custom cowboy-coding your own object when WordPress can do it already with alot less code. It's less work for you in the long-run.

  • Thanks for the reply, I'll stick to doing it the WordPress way :)
    – Mallander
    Sep 23, 2015 at 15:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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