Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9186881
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T19:38:19+00:00 2026-06-17T19:38:19+00:00

I am trying my hand at WordPress plugin development. From all of the getting

  • 0

I am trying my hand at WordPress plugin development. From all of the getting started examples and tutorials I have seen, it seems as though plugins can do little more than, say, add a “Bookmark This” at the end of a post, add an icon next to external links, or other relatively minor enhancements to existing features.

I would like to develop an extension (might that be the better word?) where a user can go to my-wordpress-site.com/the-extension and access the features of the web application. However, since all extensions must placed within wp-includes/plugins/the-extension, does that mean that is the only way the plugins can be accessed?

How could I design the extension and containing pages to be accessed with a URL like this: my-wordpress-site.com/the-extension?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T19:38:20+00:00Added an answer on June 17, 2026 at 7:38 pm

    Here’s an example:

    // register your rewrite rule
    add_action('init', function(){
      add_rewrite_rule('the-extension$', 'index.php?my_plugin_action=do_stuff', 'top');
    });
    
    // register your query variable
    add_filter('query_vars', function($vars){
      $vars[] = 'my_plugin_action';
      return $vars;
    });
    
    // process request
    add_action('parse_request', function($wp){
    
      // check if this is your request; do nothing if not
      if(!isset($wp->query_vars['my_plugin_action']))
        return;
    
      // otherwise do your stuff
      printf('Hello Pony. You requested "%s"', $wp->query_vars['my_plugin_action']);
      exit;
    });
    

    This will only work after you go to your dashboard > settings > permalinks and click the save button to flush rewrite rules, because WP apparently keeps some kind of cache of all rewrite rules.

    Then accessing yourwordpresssite.com/the-extension should display the hello message

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Problem - I am trying my hand at plugIn development and all is going
I have hand coded my blog, no wordpress or anything, and I am trying
I am trying my hand at writing test cases. From what I have read,
I'm trying my hand at behavior driven development and I'm finding myself second guessing
I've been trying my hand at OO PHP, and currently have three files. I
recently I have been trying my hand at coding a game in C#. I'm
I'm new to IPhone development and I'm currently trying my hand at Core Data.
I recently diverged from business application programming to trying my hand (just as a
I am trying to get wordpress to pull an ID from a variable to
I'm trying my hand at the iPhone course from Stanford on iTunes U and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.