It used to be that when someone types in www.syihtq.org in their browser, it used to automatically go to syihtq.org. I believe this was done by GoDaddy automatically because there were no redirects or anything in my htaccess file.
Now, when someone types in www.syihtq.org now, they get a warning that the website is not safe.
I don't know if this is new behavior, or if I just never checked it before.
My hosting provider, godaddy, will not allow me to use certbot for my ssl, so I use a cron job to renew using acme.
I recently got this error message:
I can login to a root shell on my machine, but I don't have sudo rights:
I'm using a control panel to manage my site.
Can someone help me with the following:
Is the cron job error message a problem, and if so, what must I do to fix it? Someone here helped me set up the cron job - I'm not a techie and don't really understand the commands we issued.
Is there something I can add to my htaccess file that will redirect the unsafe www.syihtq.org to the safe syihtq.org?
The first is being redirected to HTTPS (1 > 3).
The second is also being redirected to HTTPS (2 > 4).
The third and fourth have no redirection and are being explicitly redirected to, so they both must work via HTTPS.
[in this current configuration - managed via your control panel]
The current certificate only includes the short name, so that one works as expected.
But the longer ("www") name is unmatched by the web server and a default site is being served; which of course doesn't match the name being securely requested and your browser will not like it.
There are two ways to fix this:
add both names to the cert.
ensure that all redirections use only the short HTTPS site name.
Thank you so much for your response. Since I don't feel confident enough in my ability to independently add the www for all my domains to the cron job, I would choose the second one. But again, I'm not sure how to do this. Here is the redirect command that someone here helped me with before. It is shown below for just the syihtq.org, but I have many different domains using the same commands, so the actual htaccess is 33 lines long with four lines for each domain.
So the question is, what do I add in order to get www.syihtq.org to forward to syihtq.org?
I tried adding a line:
RewriteCond %{HTTP_HOST} www.syihtq.org [NC]
But it didn't appear to work, so either I put it in the wrong place, or that is not the correct syntax.
Also - you mentioned that the redirect of 2-4 is done through the control panel, but I didn't do it so it must be set up as a default and I don't know where to go to change it. If there is no way to add a command to the htaccess in order to do the redirect of www.syihtq.org, the perhaps someone could direct me to the proper area of the control panel to make this change.
33 / 4 = 8.25
Not really sure how that works out in actuality.
You said four lines for each, then only show three lines.
Is there a missing line or line that doesn't show in your post (like a blank line) or a line that has no effect (like comments)?
Anywho, there may be a very simple way to "group" all the redirects into just one, or two, section(s).
But I would have to see them all to be sure [or at least the "template" / "pattern" they all follow].
Sorry - I didn't mean to be confusing. I meant to say three lines for each (not counting the RewriteEngine On line which is in the file twice, but I'm not knowledgeable enough to know whether I can delete the second one). Here is the entire htaccess file.
Well, I know that it doesn’t deal with the www versions of the domains. The question is - COULD it? Is there a command that I can add that would redirect anyone going to www.syihtq.org to https:/syihtq.org?
Yes, but anything we add would conflict with, or may be overridden by, what is already in place.
If you could find and remove the existing inadequate redirection, you could use something like this:
But perhaps I misunderstood. Doesn't whatever I do have to be in addition to the current code? Not everyone uses the www, and I want to be sure that people using http://asklepiosresearch.org get redirected to https://asklepiosresearch.org. I'd like to be sure before I change the current code. Any help or explanation would be greatly appreciated.
Also - would there be any advantage to my replacing the whole file with the code that you say "all that amounts to this"? If that would be better, I'll replace it. I'm just not sure that I understand what OR is. (Of course, I don't understand what NC is either, but it would be nice not to have so many duplicate lines.)
Addendum - Well, I THOUGHT it worked, but alas it broke something else.
After I put in the new code in my .htaccess file none of my menus on any of my websites would appear. I have no idea what the relationship is, but whatever it is the new code completely broke all the websites.
I had to put the old code back in. And people will just have to learn that they cannot go to https://www.domain for any of my websites.
Unless someone else can explain the menu-htaccess connection and why that would happen so that we can figure out what code will enable a redirect to www without causing my menus to disappear, I think I’m going to have to let this one go.
I only checked 4 of them, but all 4 had the same problem – no menus.
These sites are written in pure html, by me (amateur hour), and use divs to make the three columns. The left and right columns are fixed width, the middle column changes based upon the width of the portview screen. Mostly they were written in 2014, so it was before I knew about bootstrap or any other responsive framework. I have no idea why a redirect would make the fixed width columns disappear, but apparently it does.