Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+2 votes
in Q2A Core by
edited by

It seems that there is something issue with .htaccess file, before it has some issue on other user profile section, like: all answer, all question etc. now it gives an error:


I contacted with bluehost, they had tried to correct, this error. But still not working.

Before, going to bluehost team, just I want to understand that should I replace .htaccess file with fresh one? or any other solution available for this issue?
Thanks in advance.

Please note that this cause occurred after SSL certificate removed yesterday automacally (I don't know why this removed, this was 4 times, which is another issue).

I also tried different URL Structure, but couldn't help.

Q2A version: 1.8.2
I had perform according to this answer, but that's not working for me: https://www.question2answer.org/qa/32548/unable-database-including-management-godaddy-acceptable
For Mod_Security error, you need to contact to Host provider.

1 Answer

+4 votes
selected by
Best answer

This doesn't seem to be related to Q2A but rather to the server. Try using this .htaccess file:

Options -Indexes
DirectoryIndex index.php

<IfModule mod_security.c>
    SecFilterEngine Off
    SecFilterScanPOST Off

<IfModule mod_rewrite.c>
    RewriteEngine On
    #RewriteBase /

    RewriteCond %{REQUEST_URI} ^(.*)//(.*)$
    RewriteRule . %1/%2 [R=301,L]

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^.*$ index.php?qa-rewrite=$0&%{QUERY_STRING} [L]

Also make sure to check both: https:// and http:// versions of your site. Maybe only the http version is working but you still have your https version set in admin/general Preferred site URL.

Great! I've just added 's' on http on Preferred site URL: http://gateoverflow.net/  to https://gateoverflow.net/ in admin section (according to your last paragraph). Now it's working even without changing .htaccess code on server.
Apologize for late reply.