My .htaccess has changed, what do i do to avoid it again...?
-
Hello
Today i notice that our site did not auto changed from without www to with, when i checked the .htaccess file i notice # in-front of each line and i know we did not insert it in there, after i removed it it worked fine.
The only changes that we did recently was to a mobile version to the site but the call to autodirect is in a JS and not in the .htaccess,
could it be the server..? is there any way that anything else might cause this...?
The site is HTML and WP could it be because of that...?
Thank's
Simo
-
Before you changed the file back did you see the last time it was modified? might give you a clue what happened. As Alan said check other files have not been changed (malware/hacked) again checking the modified dates gives you a clue ( files you know have not been touched having a recent modified date, all the files having the same modified date... etc)
-
Malware often changes the htaccess file, you should check to see if there is anything else in there.
WordPress sites are prone to being hacked. i develop in .net and have never ever had a site hacked, yet i see this is WP and joomla all the time.
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
Change category of a post
Hi, Finally I decide to renovate my site structure, but I have a question, if I have an old post and I change its category there is some SEO problem? The post permalink is "www.sitename.com/namepost". Last question, it's better to have one category for post or more than one category for post? Thank You
Technical SEO | | Marco3961 -
Domain Change
What is the average organic traffic loss one can expect after switching to a new domain? We went from .com to .org and are seeing 50% decline in organic traffic and 25% in Google news traffic. 301s were implemented from site.com/some-page to site.org/some-page and change site was completed in WMT. This traffic drop seems excessive...
Technical SEO | | SoulSurfer80 -
Redirection in .htaccess
Hi All, The problem is with the .htaccess file I have written 301 redirection code for Apache server but once I upload .htaccess file from ftp the website is throwing 500 error. Please help as I'm new to the redirection files.
Technical SEO | | Bharath_ATZ0 -
Https - should I do change of address on WMT
We have added a SSL cert to our site - Should I submit change of address on WMT and submit a new sitemap from the http?
Technical SEO | | webguru20140 -
Competitor Recently Changed his Title to Match Mine
Hey Mozsters, I'm competing with one website for a niche, he's currently beating me and recently changed his Title to match mine exactly. Are there any negative repercussions from this? Should I change mine so users aren't confused? Why would someone do this?
Technical SEO | | Unturned0 -
.htaccess redirect question
Hi guys and girls Please forgive me for being an apache noob, but I've been trawling for a while now and i can't seem to find a definitive guide for my current scenario. I've walked into a but of a cluster$%*! of a job, to rescue a horribly set up site. One of many, many problems is that they have 132 302redirects set up. Some of these are identical pages but http-https, others are the same but https-http and some are redirects to different content pages with http-http. A uniform redirecting of http to https is not an option so I'm looking to find out the best practice for reconfiguring these 302s to 301s within .htaccess? Thanks in advance 🙂
Technical SEO | | craig.gto0 -
No Access to change duplicate product title and meta tags!?
I have a client who's website contains a php file to dynamically call a product xml file from an external source. I asked the web dev company if there was any way to access or change the titles and meta descriptions to be unique for each product and they said no, not with their system. With about 63 product pages is this going to hurt me trying to get him ranked locally? What is the best to handle a situation like this?
Technical SEO | | satoridesign0 -
301 redirect .htaccess
Hi guys I am working on some 301 redirects on an apache webserver and I'd like a bit of assistance in trying to get a specific type result: I want all addresses from domaina.com to be redirected to domainb.com in the same structure so domaina.com/folder/file will go to domainb.com/folder/file expect for 2 folders.
Technical SEO | | seobackbone
ie: DomainA.com --> DomainB.com
except domainA.com/folder1
and domainB.com/folder2 Can someone let me know how I can pull this off?0