Forum Moderators: phranque

Message Too Old, No Replies

updated Excel sheet in docroot is not reflecting in URL

         

IamRasheed

7:13 am on Aug 7, 2014 (gmt 0)

10+ Year Member



HI,

We have few application which serve static informations to the users like excel sheet.

We used to place the .xls file in the docroot and it will be accesed using URL
for example, I'll place a file named test.xls and access it through http://example.com/test/test.xls

Problem here is if i modified the file content and accesed it through http://example.com/test/test.xls , it is showing the old content. New content is not displaying.

But the same if i did with .txt file , it showing the updated content for .txt file

Dont know why only xls files are not reflecting. Could some one help me how to solve this issue.

[edited by: phranque at 12:04 pm (utc) on Aug 7, 2014]
[edit reason] exemplified hostnames [/edit]

phranque

12:06 pm on Aug 7, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



if i modified the file content

how did you "modify the file content"?

not2easy

1:36 pm on Aug 7, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Do you have E-Tags or far-date Expires set for .xls files? Are your .xls files cacheable?

not2easy

1:41 pm on Aug 7, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



I thought I recognized this question, you have asked the same thing in three different threads now:
[webmasterworld.com...]
[webmasterworld.com...]

not2easy

6:47 pm on Aug 7, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



I posted this early today on my way out the door (only half a cup of coffee) and it bothered me to have phrased it that way until now when I can add to it - there is nothing wrong with asking for help, and I did not mean to imply that there is some limit to getting help, but if every time you run into the problem we start over at square one, it does not help. We already asked about caching because that seems like a reasonable cause. Did you ever try cleaning your own browser cache when checking and by all means, please check to see what your server is delivering as cached content. Follow some of the suggestions you have already received and let us know what you see. Maybe this time we can help you figure it out.

IamRasheed

4:13 am on Aug 8, 2014 (gmt 0)

10+ Year Member



Hi phranque,

I have a copy im ny local. I modified the excel sheet and uploaded to the docroot using winscp.

Hi not2easy,

"Do you have E-Tags or far-date Expires set for .xls files? Are your .xls files cacheable?"

I am not accessing the file using any program or html file. so I didnt set any tag. Please correct me if i am wrong about understanding the E-tag what you informed.And also i am sorry i dont know how to check .xls files or cacheable or not. could you please tell me.

And sorry for different threads. Actually in my last thread i was telling about the whole cache and i feel its diviating from the original issue as the original issue is excel file is not reflecting.
So i opened a new thread so people can uderstand the problem easily and help me out. I apologize for the different threads.

I tried few things from that apache site. But i couldnt found the solution still.
As you said i cleared the browser cache and it didnt fix it.
I tired using mod_cache and used CacheDisable option inside the Docroot directive,the problem didn't solved then i used this outside the Docroot directive and got the same problem.

INSIDE THE DOCROOT DIRECTIVE
--------------------------------------
DocumentRoot "/nas/oss/apache/docroots/oss0/htdocs"
<Directory "/nas/oss/apache/docroots/oss0/htdocs">
Options Includes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Allow from all
<IfModule mod_cache.c>
CacheDisable http://IP.IP.IP.IP/
</IfModule>
</Directory>
LoadModule cache_module modules/mod_cache.so
--------------------------------------

OUTSIDE THE DOCROOT DIRECTIVE
--------------------------------------
<IfModule mod_cache.c>
CacheDisable http://IP.IP.IP.IP/
</IfModule>
-------------------------------------

I used Live HTTP Headers extension of moizila firefox to study the header value. I got some thing like below. But i couldnt see any thing related to cache.


GET /Cachetest.xls HTTP/1.1
Host: <IP>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Firefox/31.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate
Connection: keep-alive

HTTP/1.1 200 OK
Date: Wed, 06 Aug 2014 05:29:09 GMT
Server: Apache
Last-Modified: Wed, 06 Aug 2014 03:40:26 GMT
Accept-Ranges: bytes
Content-Length: 17408
Content-Type: application/vnd.ms-excel
X-RBT-Optimized-By: sen-htb6050-wpa1 (RiOS 8.5.0) PT
Connection: Keep-Alive
Age: 482
----------------------------------------------------------

[edited by: phranque at 12:01 pm (utc) on Aug 8, 2014]
[edit reason] unlinked URLs [/edit]

not2easy

5:03 am on Aug 8, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



To disable caching you can use something like this - in htaccess:

#disable cache for script files
<FilesMatch "\.(pl|php|cgi|xls)$">
(Only files you do not want cached)
Header unset Cache-Control
</FilesMatch>


Previously you showed a header with an ETAG (Etag: "dae2-4400-359c9b40") which is an exipration setting, but the headers today do not show that, so it may have been unset.

I would check into the Riverbed Steelhead question that phranque asked before, because that
X-RBT-Optimized-By: sen-htb6050-wpa1 (RiOS 8.5.0) PT
indicates a Prefetch setting according to the Link that was posted to the HP site in this thread: [webmasterworld.com...]

IamRasheed

6:22 am on Aug 8, 2014 (gmt 0)

10+ Year Member




#disable cache for script files
<FilesMatch "\.(pl|php|cgi|xls)$"> (Only files you do not want cached)
Header unset Cache-Control
</FilesMatch>

For this, i need to load mod_hearder module in httpd.conf am i correct or mod_cache iself is enough?


you mean, this file may cached because of the riverbed steelhead?
If its something in network layer level then i have to ask my organization's network team.

Thank you for giving me suggestions

not2easy

3:10 pm on Aug 8, 2014 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Very sorry, but the unset cache format given here is for .htaccess files, not httpd.conf, I do not use httpd.conf and could not tell you a format for that.