Redirects the user to a specified absolute URI.

learn more… | top users | synonyms

1
vote
2answers
436 views

Unable to get wp_redirect() working after adding a CPT via the front end

I am attempting to learn PHP by creating a relatively simple application built on wordpress, it is a basic CRM and I've made decent progress but have been stuck on some of the finer points. I've been ...
0
votes
1answer
359 views

Front end posting

This source works with image upload. Without image upload, it works, but 'redirect' doesn't work. What should I do?? Any suggestions to what the problem might be? if( 'POST' == ...
0
votes
2answers
480 views

wp_redirect hangs, but returns true

I have no idea what I'm doing wrong, but I can't get the wp_redirect to actually redirect the page. I enabled the wp_debug to check for "header already sent" errors, but nothing. I installed the ...
0
votes
1answer
18 views

Check if redirected from a specific page template

I have a page template, which redirects to the homepage using this: wp_redirect( home_url() ); Now, on the homepage is it possible to check if it has been redirected from a specific page template ...
1
vote
2answers
120 views

How to redirect a specific user after log-in?

I want to redirect an user and his user ID is 6. So I added this code into my functions.php if ( is_user_logged_in() ) { $user_id = get_current_user_id(); if ($user_id == 6) { ...
0
votes
0answers
15 views

Rewrites: .htaccess or wp_rewrite for bulk 301 changes?

I'm migrating a site from an older CMS to WordPress. We'll be on the same domain but about 90-100 pages are going to have modified URLs - so, for them, I'm creating 301 Rewrite rules. My question is: ...
0
votes
1answer
352 views

Redirect after successful registration with fronted registration form

I am trying to redirect users after failed and successful registrations and logins. Everything works fine, except the redirection after a successful registration. Right now, I get redirected to ...
1
vote
2answers
496 views

redirect does not work in ajax function

I'm using ajax to post the form data. In the end I want to redirect to homepage. I'm trying following code, it does not work. It returns error 302. How can I redirect in the following function? ...
3
votes
3answers
445 views

Need help to repair a 301 redirect problem

I have been having problems with my website and as a result did a Crawl test in SEOmoz. The test found a 301 Permanently Moved Redirect of all the pages on the website and it appears that they are ...
1
vote
1answer
116 views

Wordpress HTTPS redirect loop

I've been struggling to get HTTPS functional on my site for over ten hours now. I've got severe headache trying to set it up myself. I want you to understand that I tried several different ways to ...
0
votes
2answers
29 views

How to set 301 redirection after moving WordPress blog?

I have moved my wordpress blog to new domain. Old Address : domainname.com/blog | New Address : newdomainname.com Please pay attention about old address and new address. Now I want to redirect all ...
0
votes
0answers
24 views

Capture the content of a second page to an output buffer

I have plugin with the following admin action which allows me to send the contents of a specific wordpress page to a registered user via email. The code was working perfectly, an email was sent and ...
0
votes
2answers
503 views

wp_sanitize_redirect strips out @ signs (even from parameters) — why?

In my wordpress site I have a hack that looks at the uri and does a redirect to a subdomain. The problem is wp_redirect calls wp_sanitize_redirect which will strip out @ signs, so when a user tries to ...
0
votes
0answers
64 views

Redirect to Theme my login profile

I would like to redirect admin's editing of user using path "user-edit.php?=....", and redirect to mydomain.com/your-profile/ : "Your profile" is the profile created by the theme my login plugin ...
0
votes
0answers
22 views

Redirect to specific page

I am using Wp Store Locator plugin.And I have Modified it according my need.But I am stuck in redirection. Basically this plugin works with short code.So at the time of listing my URL is like that : ...
0
votes
0answers
19 views

If Specified Page then Redirect Elsewhere in Plugin

There's a few parent pages that only exist for URL purposes, but the actual page themselves need to be redirected to the home page since they're blank. I'm trying to make a simple plugin that will ...
0
votes
1answer
64 views

Creating intro page in wordpress

I am trying to create a very simple "intro" page in wordpress which will display a 5 seconds video introduction and then will redirect to the homepage automatically. I saw that there are many plugins ...
1
vote
2answers
2k views

How to do 302 redirects “in” WordPress using Redirection plugin? [closed]

I am planning to use the Redirection plugin to do redirects. The plugin's description states that it also enables 302 redirects, but I can't see how. There's no option as such (see screenshot below). ...
3
votes
1answer
1k views

redirect out of wp-admin, without losing admin-ajax.php

I'm trying to keep all non-administrators out of the Wordpress admin panel by using a wp_redirect inside of an is_admin conditional. The problem is that a side effect of this if that non-admins can no ...
0
votes
1answer
33 views

A good hook to check authorization and redirect?

It seems strange to put a redirect in a template page, because so much of the page has already been built by the time you reach a custom page template. I'm wondering what is a good action hook to use ...
0
votes
0answers
37 views

Redirect missing pagination to base page

I have a strange problem with wp_redirect that I can't seem to solve myself. I'm trying to redirect previously existing pages back to the root of the page so: ...
0
votes
2answers
32 views

All links in WP blog redirect to main non-WP site

I worked on a Drupal site for a client, but he wanted to keep his blog on WP, so I manually created a 'blog' folder on the root of the Drupal site and moved all the WP content there. I uploaded the ...
0
votes
1answer
24 views

Redirect to Page URL for non-members

My membership plug in won't let me re-direct custom post type archive / taxonomy URLs to a non-member page if the user requesting access is not logged in or not a member. So, I am trying a hack to ...
0
votes
0answers
57 views

force login and redirect to custom login page

I am really desperate, looking for a solution for days now. I need to achieve: restricted access for logged in users only not logged in users need to be redirected to a custom login page I am on a ...
0
votes
3answers
653 views

Getting redirect to happen before header output

Anyone know of a way to trick WordPress into doing a header location redirect. I have to check whether users are logged in or not, and if not redirect them to our organizations authorization system ...
0
votes
1answer
48 views

Redirect loop when forwarding to mobile site

I have successfully redirected my page to m.example.com from example.com when i open in mobile environment with this code in functions.php add_action('template_redirect', ...
1
vote
1answer
638 views

Redirect if not logged in?

I've tried this to redirect people who aren't logged in to certain page. It ultimately shouldn't matter what front end page they visit, but should redirect to whatever page is chosen as the landing ...
2
votes
2answers
935 views

How to use nonce with front end submission form?

Thanks to a variety of posts on here I've managed to put together a front end submission form. After about 24 hours of tweaking I've finally got everything working including a redirect to a 'success' ...
0
votes
0answers
47 views

Redirecting sub-domain to main domain has incorrect URL on subsequent pages

I just redirected my sub-domain, www.simco-apts.com/testsite to takeover my main domain, www.simco-apts.com. While this works for the homepage, all other links/pages contained within the site add ...
2
votes
3answers
5k views

Where does wp_redirect need to be placed to make it work?

I've got a front end post editing page located at mysite/post_id/edit and am trying to redirect users that are not the author back to the post. Here's the code I'm working with: <?php ...
0
votes
1answer
51 views

Set a variable to using in redirected page

I need to set a global variable that will be used in the page set on wp_redirect global $open; $open = FALSE; function open_menu($user_login) { global $open; $open = TRUE; ...
0
votes
1answer
24 views

Which method to use when deleting posts from the front-end

I am trying to enlist all my posts on the front-end along with delete and edit links (using the shortcode API). I am having difficulty with the delete links. To me the most obvious way to handle ...
1
vote
3answers
4k views

Redirect user after login/registration globally

How it possible to redirect all users, even administrators after login to specific page? And also redirect users after successful registration? Any simplest way? For example I want to redirect users ...
0
votes
1answer
986 views

Why does enabling Permalinks make pages not found?

I'm new to Wordpress and am creating a site using v3.9.1 of WordPress. When I create a new page, I can see it in edit mode, but the URL it is supposedly creating is not found when permalinks is used, ...
0
votes
0answers
35 views

Create a constant download link that always points to latest attachment

I plan to have one attachment per post and the attachments will often be receiving updated versions with different file names. I have an issue where users copy and paste the file url and send it via ...
0
votes
1answer
99 views

Redirect if string found in URL

I'm trying to redirect non-logged in users to the login page when viewing any pages relating to a plugin. My code is working fine when I specify which pages they can't view, but I'm trying to pull in ...
0
votes
1answer
11 views

How to remove post redirects

I recently installed a plugin called "Q and A FAQ and Knowledge Base for WordPress" Turns out it was lacking in the features I needed so I trashed every faq I had created and then deactivated the ...
0
votes
0answers
65 views

Members only Passthrough

So I made a members only site with wordpress by redirecting everything to the homepage and adding a registration/login page to my homepage. This was added as a plugin: /* Change Login URL */ ...
0
votes
1answer
153 views

Troll the hackers by redirecting them

My website is getting somewhat popular, and with the it's increasing popularity there's an increase in the hackers. Last night I visited my security logs and found that everyday approximately 10 ...
1
vote
1answer
41 views

Multiple portfolios and single item in two of them (ideas?)

I’m creating a theme at the moment and has come to a point to decide what is the best solution to have implemented for a theme with multiple portfolios. If there is a project that is in the two of ...
0
votes
1answer
101 views

A blank page is shown after I add a Function

I am redesigning a template. So I am trying to show a holding page till the redesign process is done. I ever used following function for the purpose on many other projects and it's redirected to the ...
0
votes
2answers
576 views

wp_redirect not working from shortcode function

Whenever I use wp_redirect(plugins_url('account/login')); in a shortcode function I get the following error: Warning: Cannot modify header information - headers already sent by ... Is there any ...
0
votes
1answer
160 views

Redirect Attachment Page to Attachment

I'm trying to change my attachment page to just automatically redirect to the attachment. Here's what I've tried: Get attachment ID and redirect to that URL: $urlArr = ...
0
votes
1answer
53 views

HTML Redirect to WP pages

I have some predefined links that I need to redirect to real URLs within my WP install. I have NO CHOICE but to use these URLs provided to me, unfortunately. The format is: ...
0
votes
1answer
41 views

Some Pemalink problems, probably caused by wrong .htaccess configuration?

I have import on my local webserver a backup of a website made using WordPress but I am finding some difficulties with PermaLink configuration The main problem is that if I use the permalink setted ...
0
votes
2answers
80 views

Redirect returning users to a certain page?

Is there a way to redirect users returning to the site who are already logged in? Assuming something like: function returning_redirect() { //code here } add_action('auth_cookie_valid', ...
0
votes
1answer
75 views

Redirect to URL if x number of days passed

Let's say I have this URL: www.example.com/myCPT/post, here I want to check if 3 days has passed since the post was created to redirect to www.example.com/myCPT/post/stats. In this 3 days time frame ...
2
votes
2answers
2k views

How to Rename wp-login.php for Multisite?

I want to hide and rename wp-login.php in my URL for branding purposes on a Multisite set up. From this forum post I see that I can change mysite.com/wp-login.php to mysite.com/login by inserting a ...
0
votes
2answers
79 views

Controller functionality - User not logged in/ redirect to registration page (not wp_login)

I have a site here... If a user clicks on Submit an Event or Send an Article, they are re-directed to a 404 page because I have it set up to make the page private. What I want to do is if the user ...
1
vote
1answer
57 views

301 Redirect Code

I am currently trying to redirect a subdomain.blogger.com blog to a domain located on my hosted WordPress install. The code below is supposed to send a 301 redirect and then make that specific post ...