WordPress.org

Ready to get started?Download WordPress

Forums

Creating custom URL through plugin (1 post)

  1. Matt Jacob
    Member
    Posted 5 years ago #

    Is there any way to create a custom URL via a plugin? I imagine I could have my plugin create a new page and then populate that page with content, but there's got to be a better way. Essentially, I want a page full of PHP that outputs some XML, so I need to be able to set headers for the page, and I obviously don't want the output wrapped in a template.

    Is there any way to commandeer a slug for this purpose? Otherwise, I guess I could create a physical file within my plugin's directory structure, but that's not nearly as clean as my proposed solution.

Topic Closed

This topic has been closed to new replies.

About this Topic