Forum Moderators: phranque
The tag is added for HTML, CSS, image, and JS files, but does not get added for folder URLs (like www.example.com/folder/ for example).
I had a quick look at [webmasterworld.com...] and a few other threads, but can't see a simple way to add the tag for those HTML pages that are really index files, but which are called using a folder-based URL.
I had never previously checked this setup before. I see that setting as being a flaw which I now want to put right.
It looks like .css, .jpg, .gif, .js URLs/files do return the eTag, but .php URLs/files on this site do not. The one true .html URL present on the site does, as does the site root at "/" which is also a .html file. So, it is a .php problem, not a folder problem. My mistake.
In any case, once the site does go live all of the URLs will be .html URLs, whether or not any PHP scripts reside inside the files. The site is currently being developed on a "test" subdomain, and the whole lot is disallowed in robots.txt too.
You might want to look around here and on the Web for ways to cache the php page output as non-php files on the server, rewrite the .php URLs to those server-cached non-php files, and the server will then happily stick an eTag on them.
And yes, URLs are not files. :)
Jim
Although the files have PHP scripts in them, all the PHP stuff does is to include headers, footers, navigation, and so on, and dynamically build the breadcrumb trails to the content. Oh, and it passes the document title, meta description, and date of last edit, on to other bits of the code where the information is actually used.
The site is essentially "static". Content pages are edited and uploaded, and the navigation "include" files are edited and uploaded with typically one or two changes every month.
There is little need for a CMS, or database at present.
The live site will use AddType to let the .html files/URLs be PHP scripted content. That should essentially fix the eTag issue too.
header in PHP to set the Etag then case counts. 2. Is this of any help?
[bugs.php.net...]
(see comments about running the PHP engine as CGI not an Apache module)
*** Is this of any help? ***
It might be... but not at 2.40 a.m. ;-)
Give me a day or two to take a look.