Instead of using fixed php file you can use the custom wordpress templates
create a custom template file and give it a name such as custom template name is step2.php and Step2
/*
Template Name: Step2
*/
The contents of the custom template file is similar to the content of the file on your step2.php
Or you can use ajax to request but still could not hide the file path step2.php
Related Posts:
- Why does wordpress still strip my query var?
- WP Login forms action URLs displayed as pretty URLs in browser (ex with Restore Password)
- Tricky URL rewrite with custom values in url
- Add a query string to ALL links on site
- Add rewrite rule for rewrite endpoint
- add_rewrite_rule not working for language specific characters
- How to add custom variable in url without redirect?
- How to building pretty URLs to reflect category hierarchy?
- Rewrite custom post type URL parameters
- Help with Rewrite Rule for Custom Post Type with Query String
- Change pagination url format
- Per Page Permalink Structure for Page Post Type
- Rewrite /category/cars into /topics/cars
- custom wordpress rewrite
- Dynamic URL with rewrite rule not working
- How do I rewrite URL that has custom parameter
- Pagination appearing twice in URL after rewrite
- URL Rewrite for CPT single posts
- Rewrite URL based on form input
- Rename page URL
- WordPress post-type create url rewriting
- How to create custom URL routes?
- How do you create a “virtual” page in WordPress
- remove “index.php” from permalinks
- Use a template file for a specific url without creating a page
- Does WordPress keep track of a post’s URL history and provide automatic redirects?
- Change the “page” slug in pagination
- Understanding add_rewrite_rule
- Override default url for author pages?
- web.config conflict on IIS
- Using custom/dynamic “slug” for a page
- Rewrite rules not working in WordPress
- Dynamic Endpoints
- How to add custom rewrite rule to .htaccess?
- How do I remove a rewrite rule?
- Multiple endpoints to same page
- Problem with add_rewrite_rule and pagination (paged and page query_vars)
- generate_rewrite_rules (action) vs add_rewrite_rule (function): which one is preferred?
- add_rewrite_rule: $matches var not replaced by captured value
- Custom slug in front of search URL
- Display posts with author in the url with custom post types
- Clash of the rewrites
- How-to add rewrite rules to point the uploads folder to a subdomain
- Rewrite Rules for Multiple (more than 2) Taxonomies
- How to Rewrite WordPress URL for a Plugin
- How to prevent redirection to max 2147483647 for larger values of the page query variable?
- add_rewrite_rule not loading correct page nor getting variables
- Preserving $_GET parameter while using custom Rewrite Rule
- How to change default page slug?
- Disable wordpress pagination URL rewrite for specific page
- How to use Post Custom Metadata in Post Titles and Post Permalinks
- URL Rewrite + Page + Custom Post Type = Unusual Redirect
- Rewrite url for custom post type
- add_query_vars and add_rewrite_rules
- rewrite_rule() not preserving the query string
- Need help with rewrite_rules_array
- SEO Friendly URLs for my plugin categories
- Will references to ugly links automatically redirect to their pretty url permalink?
- How do I add a add_rewrite_rule without it redirecting?
- How to create a specific frontend URL (not a Page) from a theme or plugin?
- Taxonomy rewrite question
- Mod_rewrite delete parameter in 301 Redirect
- add_rewrite_rule not working for page var
- how to add prefix to post url structor only
- Appending numbers to url do not break the link
- When to call `add_rewrite_rule` for safety
- Hijacking the URL for filtering
- WordPress URL rewrite regex
- Custom rewrite rules are sending everything to index.php
- Getting add_rewrite_rule and add_rewrite_tag to work
- Blog installed in subdirectory but need to create pages in root. How to use permalinks?
- WordPress Network on IIS7/SQL Server – Rewrite Issues
- Custom comments
- Rewrite rules goes away
- custom htaccess rewrite rule for page
- Rewrite Rule for Custom Page with Query Vars in URL
- flexible rewrite ‘ramble’ URLs with WordPress
- WordPress keeps writing rewrite rules to .htaccess
- Adding the amp url prefix to the beginning
- WordPress Rewrite
- add_rewrite_rule again
- Dynamic URL, not a physical page within the database
- Rewrite Rule for Post “Subpage”, with pagination
- Passing & Reading URL Parameters with URL re-writing
- Need to make a php file inside theme accessible via url
- Custom rewrite rules for feeds of custom queries (query_var query strings in URL)?
- How to change page URLs to “www.site.com/page” instead of “example.com/blog/page” but keep post URLs as “example.com/blog/post”?
- Add_query_arg + two times the same argument?
- WP Rewrite the last two parts of the URL
- WordPress 404 unless there is a space in url
- Change default URL of image attachment
- Prevent WordPress from automatically correcting URLs
- Rewrite loading custom template file but is_home() returns true, and there’s no 404
- Taking a value from PHP_URL_PATH won’t work after WordPress 5.5 update
- Rewrite rule for admin-ajax.php
- Display content according to current URL
- Server (WordPress) redirects files that are not supposed to (using htaccess)
- redirect 301 old url to new url
- Add rewrite rule to call front-page.php?
- add_rewrite_rule not registering on Multisite