Author Topic: How to solve 406 Not Acceptable  (Read 1688 times)

0 Members and 1 Guest are viewing this topic.

Offline PernicketyPete

  • Member
  • *
  • Posts: 11
    • Chilthorne Weather
How to solve 406 Not Acceptable
« on: February 11, 2017, 06:03:15 AM »
Hi All
I have been directed here by Jachym. I hope I'm in the right place.
I have run into some problems when trying to upload historic data to meteotemplate. I am getting a "406 Not Acceptable!
An appropriate representation of the requested resource could not be found on this server. This error was generated by Mod_Security." Screen. I have had a google around and found this.

It would seem l need to edit my .htaccess file. Please see link. - https://www.tipsandtricks-hq.com/apache-mod-secruity-update-how-to-fix-error-406-or-not-acceptable-issue-259
Which method should I use?

At the moment when viewed in notepad .htaccess file is just one line, this is it -

# Use PHP5.4 as default
AddHandler application/x-httpd-php54 .php
DirectoryIndex index.html index.shtml index.xhtml index.wml index.perl index.pl index.plx index.ppl index.cgi index.jsp index.js index.jp index.php4 index.php3 index.php index.phtml index.htm home.htm default.htm index.fcgi default.html
# -FrontPage-


<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthUserFile /home/chiltho1/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/chiltho1/public_html/_vti_pvt/service.grp
ErrorDocument 404 /404.shtml

AuthName chilthorneweather.co.uk
IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

If I was to edit this file with either of the two methods mentioned on the tipsandtricks website, where would I put those lines of code in relation to what's there already?
Sorry if this sounds a really dumb question but I'm always a bit nervous about editing stuff, especially when I have no idea what it's for or what it does. I don't want to break my site.


I have noticed that I also have a file called .htaccess.predirectoryindex this is it's contents.

# -FrontPage-


<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthUserFile /home/chiltho1/public_html/_vti_pvt/service.pwd
AuthGroupFile /home/chiltho1/public_html/_vti_pvt/service.grp
ErrorDocument 404 /404.shtml

AuthName chilthorneweather.co.uk
IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

Maybe this would be the one to edit.??

Maybe someone has another and or better way.

I hope someone can point me in the right direction on this one

Cheers Pete

Offline Jáchym

  • Meteotemplate Developer
  • Forecaster
  • *****
  • Posts: 8605
    • Meteotemplate
Re: How to solve 406 Not Acceptable
« Reply #1 on: February 11, 2017, 11:25:49 AM »
Hi Pete,
as I said in the email, unfortunately I only know very little about servers and use an external webhosting myself. Hopefully someone might have an idea how to solve this, it is some strange extension installed on your provider's server and when I looked it up on the internet it causes issues even with WordPress.

Offline PernicketyPete

  • Member
  • *
  • Posts: 11
    • Chilthorne Weather
Re: How to solve 406 Not Acceptable
« Reply #2 on: February 11, 2017, 03:59:19 PM »
Thanks Jachym
Hopefully someone on here will know The answer

Cheers Pete

Offline Cutty Sark Sailor

  • WxElement panel
  • Forecaster
  • *****
  • Posts: 3394
    • Frankfort Weather - TwinHollies WeatherCenter
Re: How to solve 406 Not Acceptable
« Reply #3 on: February 11, 2017, 08:51:30 PM »
First thing I'd do is fix my webpage code....http://www.chilthorneweather.co.uk/
81+ errors, including head information scattered through document, etc...
then I'd worry about the server rejection.
 


Offline Jáchym

  • Meteotemplate Developer
  • Forecaster
  • *****
  • Posts: 8605
    • Meteotemplate
Re: How to solve 406 Not Acceptable
« Reply #4 on: February 11, 2017, 09:20:36 PM »
That's not his meteotemplate site

Offline Cutty Sark Sailor

  • WxElement panel
  • Forecaster
  • *****
  • Posts: 3394
    • Frankfort Weather - TwinHollies WeatherCenter
Re: How to solve 406 Not Acceptable
« Reply #5 on: February 11, 2017, 09:53:01 PM »
That's not his meteotemplate site
That was the link under his profile... .