apache2: cannot redirect https://www.subdomain.example.com to https://subdomain.example.com

Could you help me to solve the https: // www. redirect?

I am trying to redirect the following:




My apache2 configuration (/etc/apache2/sites-available/subdomainredirection.conf) is as follows:

    ServerName www.subdomain.example.com
    Redirect 301 / http://subdomain.example.com/

    ServerName subdomain.example.com
    Redirect 301 / https://subdomain.example.com/

    SSLEngine on
    SSLCertificateFile /etc/ssl/certs/...
    SSLCertificateKeyFile /etc/ssl/private/...

    ServerName subdomain.example.com
    ServerAlias www.subdomain.example.com
    ServerAdmin webmaster@localhost

    Redirect permanent / https://hub.example1.com/fol/1234/

    ErrorLog /var/log/apache2/subdomain.example.com-ssl-error.log
    CustomLog /var/log/apache2/subdomain.example.com.log combined

Redirection works well for:


I am looking for a solution to:


I bought a 2 year ssl wildcard certificate (* .example.com).
My thought was that https: // www. I need a certificate.

The domain and subdomain are in GoDaddy.

I have these records in example.com domain

A      @              aaa.bbb.ccc.ddd  600 (seconds)
A      subdomain      aaa.bbb.ccc.ddd  600 (seconds)
A      www.subdomain  aaa.bbb.ccc.ddd  600 (seconds)
CNAME  www            @                  1 (hour)

Is it possible to resolve the redirect https://www.subdomain.example.com?

Thanks in advance.

Redirect a list of URLs to another URL, using functions.php

What i want to do

I have a series of WordPress URLs that I need to redirect, along with a 301 permanent redirect header that is sent to the browser.

The URLs to redirect are:







Where to redirect to

I want to redirect them to the home page: https://mydomain.com.au/

I'm not sure if it's better to do a test for all six location= strings, or just to test the location= string that is not to redirect.

The one that is not to redirect is ?location=western-australia. E.g.,


Additional considerations

Please note that there are other /search-result/ URLs that have different variables in the query strings, such as ?weather=... or ?water=.... For example, https://www.mydomain.com.au/search-result/?location=victoria&weather=part-shade&water=&pasture=

As seen in that example, there may also be multiple variables in the query string, like ?location=tasmania&weather=&water=moderate&pasture=.

So I need to test the presence of the above locations= regardless of whether or not it has other variables afterwards. the location= The variable will always be the first in the query string.

I'm thinking it can be as simple as trying /search-result/ Y victoria; tasmania; northern-territory; etc. in the url

A different approach?

Would it make sense to do this using a .htaccess redirect, instead of having WordPress do it? I'm not sure of the advantages or disadvantages of each approach.

Apache: redirect directory to another root site

I want to redirect everything from a certain subdirectory to the root of another site, i.e. without the subdirectories:
See the following example:

company.com/jobs should be redirected to jobs.site.com. Then again, all the way behind /jobs should be omitted like this: company.com/jobs/foo should also be redirected to jobs.site.com

This last part is the most difficult as with redirect 301 /jobs jobs.site.com the way/foo not omitted like this company.com/jobs/foo redirects to jobs.site.com/foo which throws a 404 error since this page doesn't exist.

How can I get the route to be skipped in a redirect?

8 – How to redirect after node insertion (not form redirection)?

I am trying to figure out how to redirect after inserting a new node. All the answers I've been able to find discuss $ form_state-> setRedirectUrl (); but this is a form redirect; it is not a proper redirect after insert.

The difference is that when I submit the node form; I use hook_node_insert to create another entity based on the information of the node being inserted. After inserting the main node; I want to redirect to a path based on the entity ID of the new child entity.

In hook_node_insert (for the parent; that is, submitting the original form) I set a drupal_register_shutdown_function function that correctly saves my child entity and then I have the -> id () of the new (child) entity.

I have seen several examples using RedirectResponse, like this:

$redirect = new RedirectResponse(Url::fromUserInput('/admin/commerce/orders/' . $order->id() . '/payments')->toString());;

but none of these works.

One page payment: Magento 1.9 does not redirect customer to success page after successful order

I am facing a strange problem. I am working on magento 1.9.
Sometimes, after a successful order, the customer is not redirected to the success page, this happens not on all orders, maybe 1 out of 5.
after diagnosing the problem I discovered that in


there seems to be no getLastSuccessQuoteId () as shown in the images below

I was thinking it might happen due to redis, but I'm not sure. Has anyone faced a similar problem before or have an idea on how I can solve this problem? Thank you πŸ™‚
Screenshot 2020-03-31 at 22.05.47.png

strong textenter the image description here

wpml plugin: redirect some of the languages ​​on a multilingual site

I have a site that uses WPML to display three languages.

  • EN – www.dominio.com
  • FR – www.dominio.com/fr/
  • EN – www.dominio.com/es/

I want to configure redirects so that all EN and FR pages (home pages and internal pages) are redirected (page by page) to pages in a different domain. However, a user who visits the home page with their browser language set to ES will be redirected to www.domain.com/en/.

I can use the redirect plugin for EN and FR redirects, but in doing so all users (including those with a browser language set to ES) are automatically redirected to the new domain. In other words, ES redirect doesn't work as it is the second one in the redirect queue.

What are my options?

redirects: redirect from domain A to domain B, when I have a subdomain of domain A

No, top level domains (example.com) can be redirected independently with respect to their subdomains (www.example.com, notredirected.example.com)

The typical configuration of what you are describing is redirecting example.com Y www.example.com to domain B, but keep notredirected.example.com service.

Redirect all requested URLs to a new URL

I want to redirect all requested URLs in WordPress to a new URL, for example:

How can I do this in htaccess?

Try to access the mailbox redirect to https://www.google.com/intl/en/gmail/about/; i can't just log in again

A friend of my aunt says she's still connected to her Google account (or at least goes to google.com), but can't access her mailbox like she used to. Clicking on & # 39; Gmail & # 39; On google.com, go to your mailbox from your browsing history, go to mail.google.com and redirect it to https://www.google.com/intl/en/gmail/about/. From there, you cannot access your email, because this website appears not to be logged in; the only buttons available are & # 39; Login & # 39; or & # 39; Create an account & # 39 ;.

The problem is, you can't just log in again. She says her password stopped working a long time ago. He tried to access his mailbox from his tablet, but despite entering the correct password (he insists that the password was 100% correct) he still received messages about an incorrect password. So she found out that her password stopped working for some reason and said that she made sure never to sign out of her Google account because she knew she would have trouble logging in again. He insists that the password he has written on a piece of paper is correct and up to date; Meanwhile, your password has not changed. She says that 100% no one has changed their password. You have not attempted to use your access to your Google account to change your password and regain full control over your account. Older people's behavior can be amazing!

Now she cries because she cannot access her important emails. She calls me over and over, how can she bypass https://www.google.com/intl/en/gmail/about/ and get to her mailbox? I don't know what to tell him.

I tried to sign in to my Google account and went to https://www.google.com/intl/en/gmail/about/ – oddly, this site looked like I was not signed in, although I did, but in my case Going to mail.google.com led to my inbox and not this dreaded https://www.google.com/intl/en/gmail/about/ again. On the other hand, while I was disconnected from Gmail, going to gmail.com redirected me to the login page and not https://www.google.com/intl/en/gmail/about/, then what happens she says to me it seems strange to me.

I can see the following options:

  • Try logging in again, with the old password (maybe despite your insistence, didn't you type that password anyway that time?), But won't this lead you to permanently and completely lose access to your account if the password is really wrong?
  • Please use the Google account recovery option, but since, in your words, your password stopped working a long time ago, won't this option be unsuccessful and you won't completely lose access to your account again?
  • If you're still signed in (or & # 39; connected media & # 39 ;, if that's possible …), shouldn't you try using whatever access you already have to escalate to full control over your account? But how to do this ??

What should be done in such a situation? The immediate concern seems to be at least retrieving the emails you still have there.