24

Accept is like Here is my request and I would like (to Accept) this response format Content-Type is like Here is my request (or response) and this (Content-Type) is the format of the content I am sending in my request (or response)


17

Change your htaccess file code on your website root directory (i.e. Your public_html ".htaccess" file) <FilesMatch "\.(ttf|otf|eot|woff|woff2)$"> <IfModule mod_headers.c> Header set Access-Control-Allow-Origin "http://skin.cdn.com" </IfModule> </FilesMatch> Now your CDN will be allowed to load your resource calling ...


16

It might come from 60 * 60 * 24 * 7 * 4 * 12 = 29030400 where each month consists of exactly 4 weeks.


12

In client-server applications, the IP address of the client (i.e., the browser) is sent via the socket connection (the request) to the server (e.g., Apache). If the client is using a proxy server however, that may be the proxy's IP address instead of the client's IP. Remote_Addr is an ENV returned by the server and available to server-side scripts/...


12

Unfortunately, you can't. Google search now exclusively uses HTTPS and all search result clicks go through an intermediate URL that removes the keywords. The URL you posted above appears to be that intermediate URL, and that's all you get as the referrer. The reasoning behind this is that each user of Google often gets personalised results based on their ...


12

It's correct to set this directive like RequestHeader set "X-Forwarded-Proto" expr=%{REQUEST_SCHEME} RequestHeader set "X-Forwarded-SSL" expr=%{HTTPS} If it doesn't work, you may need to install and enable the module mod_headers.


9

If you use the "Fetch as Google" tool in Google Search Console on a page that returns a "418 I'm a Teapot" status then it simply reports an "Error" and indexing cannot be requested for this page. In the screenshot below, the circled "Error"s are the result of requesting a page that returns a 418 status. No further information is available at this stage. ...


8

It is a request-response conversation, so the client sends a request of "Content-Type" and expects to receive the response of "Accept" media type.


7

Yes. By the HTTP protocol, clause 7.2.1: “Any HTTP/1.1 message containing an entity-body SHOULD include a Content-Type header field defining the media type of that body. If and only if the media type is not given by a Content-Type field, the recipient MAY attempt to guess the media type via inspection of its content and/or the name extension(s) of the URI ...


7

I have decided to serve only gzipped version of my pages If you're only serving files that you've compressed using gzip, then using Vary: Accept-Encoding will be of no benefit since there won't be uncompressed copies of the files to serve to clients that don't send Accept-Encoding: gzip in the HTTP request. Most clients these days do send this, so you ...


6

The s-maxage header is intended for proxies, while max-age is intended for regular users. A typical end user (not using a proxy) would have the file cached for a year. The same should be the case for someone using a proxy as well, since the proxy will likely send the file unmodified, i.e. including the max-age header. But the proxy itself would only cache ...


6

"Is there a common way to override the server headers send to the browser from within the HTML document?" AFAIK no, you do what you can do already. The defined charset via Header trumps your definition in the META tag. If you have access to the server, e.g. Apache, it is configured by this statement (see the comment lines): # Read the documentation before ...


6

What you want is the immutable keyword in your Cache-Control line. Example for php: header('Cache-Control: public, max-age=80000, immutable'); Source: https://code.facebook.com/posts/557147474482256/this-browser-tweak-saved-60-of-requests-to-facebook/


6

Some search engines and bots send HEAD request to pages before sending the GET request for reasons like: Checking if the page size has changed Checking the last modified date etc. (Any other info the head would give them!) This would help large crawlers save a lot of bandwidth if they know a page has not been changed meanwhile and they don't have to crawl ...


6

This isn't so much an SEO issue, as an issue as to whether your site would work at all. If it doesn't work in the browser then it's certainly going to hurt your SEO. Your HTML pages still need to return the text/html mime-type in order to be interpreted as HTML by the browser. ie. You need to send a Content-Type: text/html HTTP response header somehow. ...


5

The reason is that your directive in the X-Robots-Tag is for indexation, not crawling. [EDIT] Explicit reference to this point is made here: https://developers.google.com/webmasters/control-crawl-index/docs/robots_meta_tag This document details how Google handles the page-level indexing settings allow you to control how Google makes content available ...


5

From my understanding and experience it seems to me perhaps you've misunderstood how CDN caching works: From the example you've given, the CDN would not ask your web-server when the file was last modified because you've already told it that the file has expired and will therefore need to be re-fetched anyway. Web browsers will only send an If-Modified-Since ...


5

Google considers redirecting content that is no longer available to be "soft 404". They would like to be able to treat the page the same as a 404 page. If you redirect the expired page to your home page, Google will identify it as a soft 404. It will appear in Google Webmaster Tools as an error. Google won't pass the link juice from inbound links to ...


5

Well aren't you friendly... "Hey Google, I'm having a DOS, but im making it your problem, thanks" First: There is no difference for you between serving an 301 or an 404 error page. Your server will have to do the same amount of work. The difference here is that you, with your 301->google solution, now ALSO make it Google's problem, effectively ...


4

http://www.example.com/ and http://www.example.com are the same URL. Whether or not the trailing slash is shown in the browser address bar is purely cosmetic - when the request is sent to the server the slash will be included. (http://www.example.com/foo and http://www.example.com/foo/ on the other hand are different URLs.) If the site you're working on is ...


4

how this workaround indeed works PHP runs later in the request, so most of the time you can simply override any headers that Apache has already set in your PHP code. That's pretty much it. (Aside: Sending 403s through your 404 handler in this way obviously makes it harder to trigger a real 403 from your Apache config/.htaccess, if you should need to.) ...


3

Using a no-cache meta tag is a bad idea. Page caching is valuable for both SEO and user experience. Caching will improve (lower) page load times. This means a user sees the content faster, which reduces abandonment rates - especially on mobile devices. Ideally users will use settings to clear their browser cache, however this cannot be assumed. A preferred ...


3

I had the same issue, and the Requests are definitely hitting the server for it to respond with the 304 status - I'm sending the 304 via some C# and for sure it hits the server.. I only had Cache-Control: private set. No max-age and no Expires It operated as expected; hit the server with the If-Modified-Since where I test the value compared to what I ...


3

No, it's not possible from within the HTML. The servers response header take precedence over the document's meta-tag. As it's specified in 5.2.2 Specifying the character encoding - HTML 4.01 Specification : To sum up, conforming user agents must observe the following priorities when determining a document's character encoding (from highest priority to ...


3

You should set something like this in your root .htaccess <FilesMatch "\.(htm|html|xhtml|xml|php)$"> AddDefaultCharset utf-8 </FilesMatch>


3

If a page has been deleted then it is correct to return a 410 (or 404). If, however, it has been temporarily removed and the intention is to restore it at some point then it could be acceptable to return a 503 (Service Temporarily Unavailable) and preferably with a Retry-After HTTP response header indicating a date when the resource will be next available. ...


3

It was not skipped right away. As you can see in this diff between version 1 and 2 of the RFC draft they dropped it. At the beginning it was in there.


3

In the requests towards the (non-SPDY) website I work for i've seen requests with up to 4-5 KiB of request headers. (we kicked the offending javascript that caused that) Assuming the SPDY compression does at least a compression to leave at most 25% of a header (note that I have NOT tested SPDY yet!!!) then the resulting request header goes down to a size ...


3

It is a common mistake that people worry about 404 errors found in Google Webmasters Tool for pages that do not exist. This is a natural functioning of a website and search engine and therefore nothing to fix. If the page is gone, then a 404 error is appropriate. What frustrates people in these cases is that they feel that Google is still trying to access ...


3

See How to force files to open in browser instead of download (pdf)? which has an answer from ColinM that tells you exactly what the headers should be: To indicate to the browser that the file should be viewed in the browser: Content-Type: application/pdf Content-Disposition: inline; filename="filename.pdf" To have the file downloaded rather than ...


Only top voted, non community-wiki answers of a minimum length are eligible