You might try to use jQuery to change the url behind the Close link.
Another idea would be to use wp_get_referer()
to intercept the page loading when you go from customize.php
to themes.php
by hooking into the load-themes.php
action:
add_action( 'load-themes.php', 'my_customize_redirect' );
function my_customize_redirect() {
if ( strstr( wp_get_referer(), '/wp-admin/customize.php' ) )
{
$url = get_admin_url(); // EDIT this to your needs
wp_safe_redirect( $url );
exit();
}
}
Related Posts:
- How to redirect non-logged in users to a specific page?
- Why is WordPress redirecting from http to https on a local environment?
- Non-WordPress page in subdirectory under WordPress page
- Clarification on auth_redirect()
- Implementing global redirection (automatic redirect for all pages who had their slug changed)
- Redirect to custom url when registration fails?
- Restrict Access to wp-login.php
- How to redirect url requests to https? [closed]
- Best way to handle redirects
- Redirect to custom URL after registering from a page with registration form
- Problem to redirect custom page using htaccess
- WordPress within a subdirectory of another WordPress environment doesn’t work
- wp-login.php — redirect logged in users to custom URL
- 301 Redirect Custom URL hierarchy to WordPress Posts
- Plugin Redirect After Activation
- $_SESSION variables lost during OAuth callback
- Redirect user after logout
- Wp Login redirect strips parameters from url
- Mixed Content with SSL, wordpress behind a reverse proxy
- 302 redirect to signup with nginx reverse proxy
- Strange redirection issues on wordpress from ssl with padlock to ssl without padlock
- Redirect HTTP to HTTPS
- Redirect away from login page
- Deny access to a path (give 403 or 404 response)
- Redirect if $_Server[‘REQUEST_URI’] is /wp-login.php?checkemail=registered
- Redirect from home page to post list page?
- set up 301 redirect within wp-content/uploads/ directory of a WP site to a new image URL
- How to redirect user after login to a specific page?
- Redirect when accessing /login when logged in
- How can I redirect a URL to an anchor link while maintaining the URL?
- How to remove duplicate and unnecessary part in a url using htaccess and regex?
- How To Fix A Redirect Chain
- Masked a external URL and redirection plugin
- Redirect “http://old.net/category/postname” to “https://new.com/postname”?
- Login Redirect – Multiple Scenarios
- Redirect outside WP after login
- Redirecting from wp-content?
- Redirect non existing page to frontpage
- How do I do a redirect to WordPress permalink with post id via htaccess?
- WP page 404 error only on mobile
- Redirect user on first visit based on geographical location
- Create a permalink to a pdf?
- My site doesn’t redirect from HTTP to HTTPS
- How to prevent redirect 301
- Redirect one domain to another
- How to redirect wp_login_form to new page after user loged in?
- Redirect User to login page
- How to redirect multiple subfolders back to root domain?
- How do I Redirect Tags from Old Joomla Site to New WordPress Site?
- Redirect After Login Error
- Whenever I try to publish a post in wordpress, I always get redirected to the installation page…why?
- Is it possible to detect if a POST action is for a “Save Post” before the save_post action?
- Disable and Hide WP-JSON
- URL redirection
- Old missing file in wp-content/uploads/ returns a 500 error, how to catch and redirect?
- Redirect when not logged and parametr in link
- Browsers Forcing Multisite to https
- Is it possible to change redirect template through a shortcode?
- How do redirect user back to previous page when on certain pages?
- Relink Drupal Permalinks “…node/XXXX” to wordpress Permalinks (e.g./audio/)
- Keep the old referrer after failed login
- How to 301 redirect WP posts id “/c/94940894” to permalink with post name?
- WP 301 redirect does not work
- Redirect Image URL to it’s parent post
- Redirect user if they are logged in
- 301 Redirect Link to Media
- WordPress Redirect post to outside website based on useragent
- WordPress site not forcing from http to https instead getting redirected too many times
- Redirect not work
- There is 1 redirect
- How to create mass 301 redirects with PHP in Nginx server without using a WP plugin
- HOW do you Redirect buddypress login to EDIT tab not PROFILE tab on profile page? [closed]
- WordPress redirects to backend when i’am not logged in
- Redirect to custom admin menu after plugin activation
- Redirect HTTP request to HTTPS request
- All new posts serving 301 redirect
- home page redirect loop after update to 4.8
- Moving site from HTTP to HTTPS
- Redirect from plugin created page
- 301 Redirects when change URL in WordPress database
- How can I redirect to another page with screen already at the bottom of the page?
- How is this URL being redirected?
- What’s the best way to redirect to a new wordpress website?
- Tag archive page not working
- 301 Redirect only for posts
- Custom redirects with using SQL
- Why is WordPress redirecting to homepage after GET form submit?
- Redirect after user changes password
- Getting error when trying to redirect WP site to mobile site
- wp_login_form: Redirect to dynamic url according to username
- Plugin redirects URL structure using 301 redirect. Time to disable the plugin?
- Hide page for user logged and redirect for profile? [duplicate]
- Redirect URL while building site
- Redirect a WP to another with all URL
- Redirect ignore last URL segment
- Creating custom link that redirects to a another link
- Other pages fine but wp-admin showing ERR_TOO_MANY_REDIRECTS Error
- How to disable login and registration pages?
- Redirect if a user has not written a post
- Redirect certain 404 pages to parent page