Articles of wp redirect

How to display post in custom file not in archive file?

I create file content-expertises.php and display my category list. Now, When I click one my category name, it is redirect in category.php file not my custom created file like category-expertise.php. My current path is: http://hostname/expertises/project-reviews/ When I click my category name it is redirect in: http://hostname/categories/category-name/ But, not redirect in my custom created (file is […]

Is it possible to wp_redirect() to a new tab?

Is it at all possible to set up wp_redirect() so that it redirects to a new browser tab? If so, how can it be done?

Redirect User to login page

Well I am newbie to WP and the question may sound duplicate but even after trying for few days I can not make this work. I have integrated a custom login and registration form in my WP site which is different form usual WP login and register forms. I need to perform the following actions […]

template_redirect to accompany with a shortcode

In one of my plugin’s shortcode I’m handing user login / registration on the fly with a post submission. So the whole thing is happening within the shortcode like: <?php function this_shortcode() { ob_start(); //if isset(login)… process login, get $user_id //else if isset(registration)… process registration, get $user_id //else if already registered, get $current_user->ID as $user_id […]

Manually Create PHP Page For A Redirect

I am new to wordpress and working on something for a friend, I have FTP access, and am trying to upload a php file, that checks the platform and redirects the user either to the iTunes store if they are on an iOS device or force downloads a file if the user is on any […]

how to use wp_redirect inside a function

I have the following action and function. Ultimately i’m trying to get access to value $processArtwork in my template. One option is pass the value via the querystring. However the following results in “Warning: Cannot modify header information – headers already sent by (output started at /home/xxxxxx/ in /home/xxxxx/ on line 1228” add_action(‘init’, ‘process_artwork’); function […]

Redirect User From Registration Page To CPT (profile page) with custom url

I am looking for a little advice regarding wp_redirect after successful registration, the plan is a new user registers and is then re-directed on success to a custom post type page ‘Agent’ wp stackexchange question asked here two years ago. The agent page is a profile page containing info entered entered at registration and will […]

Delete post: 2 wp_redirect if pages are different

My website allows users to publish and manage posts from frontend. I’ve created a kind of account section where they have all their posts published which they can edit and delete. They can even delete posts through the post page (single.php). So 2 cases: My account page (listing all posts): quick actions -> delete post. […]

Redirect to Referring URL after Login

What I’m after is to simply redirect a user to the referring URL after they have logged in. I’ve been trying to figure this out for a few days now and I’ve read everything I possibly can, but either the posts I find are 4-5 years old or whatever posted code I try doesn’t seem […]

Force Rewrite Query Var On Hierarchical (Nested) Page

I want to use a hierarchical (nested) page with a query var to pull dynamic content. I had things working when the page wasn’t a child of another page, such as: However, when I made my page a child of another page, my query_var no longer works, e.g. My code /* Register Query […]