Thank you very much, this has solved the problem. This was because i had asset files in theme webroot folder.
Thanks again! -- Dott. Stefano Zoffoli *Web Development & Internet Technologies * *Librasoft Snc *http://www.librasoftsnc.it Via della Luna, 13 47034 Forlimpopoli (FC) Tel. +39 0543 424612 Fax +39 0543 424612 2011/12/13 AD7six <[email protected]> > > > On Dec 13, 10:16 am, Stefano Zoffoli <[email protected]> > wrote: > > I found the problem: > > > > CakeResponse class sets headers that defines content-type and expire date > > time that overwrite .htaccess instructions, even for assets. > > Well I stand corrected regarding relevance. It was quite a big > omission to not say you were referring to served assets. > > > > > Example: > > public function cache($since, $time = '+1 day') { > > if (!is_integer($time)) { > > $time = strtotime($time);} > > > > $this->header(array( > > 'Date' => gmdate("D, j M Y G:i:s ", time()) . 'GMT', > > 'Last-Modified' => gmdate("D, j M Y G:i:s ", $since) . 'GMT', > > 'Expires' => gmdate("D, j M Y H:i:s", $time) . " GMT", > > 'Cache-Control' => 'public, max-age=' . ($time - time()), > > 'Pragma' => 'cache' > > )); > > > > } > > > > Is there a Cake way to set different expire dates based to resource type > or > > to disable this headers so i can use .htaccess file? > > You're asking the wrong question (mostly) and trying to solve the > wrong problem - put the files in the webroot and let the webserver > serve static files. Serving files with php is slow and inefficient - > if you need to serve files using the media view, set the right > options. > > AD > > -- > Our newest site for the community: CakePHP Video Tutorials > http://tv.cakephp.org > Check out the new CakePHP Questions site http://ask.cakephp.org and help > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > [email protected] For more options, visit this group > at http://groups.google.com/group/cake-php > -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php
