.htaccess

Author Message

Jack Rackham

Wednesday 27 October 2004 10:01:10 am

I suddenly found out that my .htaccess file was not working, can someone help me?
I pasted this code into my ez publish .htaccess file but it is not working.

<FilesMatch ".">
order allow,deny
deny from all
</FilesMatch>

<FilesMatch "(index\.php|\.(gif|jpe?g|png|css|js|html)|var(.+)storage.pdf(.+)\.pdf)$">
order allow,deny
allow from all
</FilesMatch>

RewriteEngine On
RewriteRule !\.(gif|jpe?g|png|css|js|html)|var(.+)storage.pdf(.+)\.pdf$ index.php

DirectoryIndex index.php

Jack Rackham

Wednesday 27 October 2004 1:32:50 pm

OK I found out it was much better to use Virtual Host instead, but according to EZ guide "RewriteEngine On" shall work in virtual host. But it only works in apache 1.x not in apache 2.x.
http://www.ez.no/ez_publish/documentation/installation/virtual_host_setup

I have tried the following code but it will not work

<IfModule mod_rewrite.c>

RewriteEngine On

RewriteRule !(^/design|^/var/.*/storage|^/var/storage|^/var/.*/cache|^/var/cache|^/extension/.*/design|^/kernel/setup/packages|^/packages|^/share/icons).*\.(gif|css|jpg|png|jar|js|ico|pdf|swf)$ /index.php

</IfModule>

Jack Rackham

Thursday 28 October 2004 2:50:07 pm

I fixed the problem. I had just forgotten to turn on the "rewrite_module" in loadmodule.conf.

For the record this worked:

RewriteEngine On
RewriteRule !\.(gif|jpe?g|png|css|js|html)|var(.+)storage.pdf(.+)\.pdf$ index.php

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 03:23:57
Script start
Timing: Jan 19 2025 03:23:57
Module start 'layout'
Timing: Jan 19 2025 03:23:57
Module start 'content'
Timing: Jan 19 2025 03:23:58
Module end 'content'
Timing: Jan 19 2025 03:23:58
Script end

Main resources:

Total runtime1.2576 sec
Peak memory usage4,096.0000 KB
Database Queries55

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0068 590.1875152.6094
Module start 'layout' 0.00680.0032 742.796939.4141
Module start 'content' 0.01011.2457 782.2109474.1719
Module end 'content' 1.25580.0017 1,256.382812.1953
Script end 1.2575  1,268.5781 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00350.2815160.0002
Check MTime0.00130.1073160.0001
Mysql Total
Database connection0.00080.061210.0008
Mysqli_queries1.191994.7789550.0217
Looping result0.00080.0657530.0000
Template Total1.211396.320.6057
Template load0.00230.185720.0012
Template processing1.209096.135020.6045
Template load and register function0.00010.007910.0001
states
state_id_array0.00290.227010.0029
state_identifier_array0.00410.326320.0021
Override
Cache load0.00200.1607320.0001
Sytem overhead
Fetch class attribute can translate value0.00070.058610.0007
Fetch class attribute name0.00140.109240.0003
XML
Image XML parsing0.00050.038510.0005
class_abstraction
Instantiating content class attribute0.00000.001260.0000
General
dbfile0.00430.3407160.0003
String conversion0.00000.000840.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
7content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 21
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs