0

Im using the master .htaccess http://joomla-master-htaccess.googlecode.com/svn-history/r40/trunk/joomla-master-htaccess.txt

im trying to set up a RewriteRule for my k2 module to add item, firebug Net panel points me to http://www.wyzed.net/component/k2/item/add?tmpl=component wich return a Not Found 404 error

item/add?tmpl=component

i have tried with this

RewriteRule ^components/com_k2.php$ - [L]

RewriteRule ^modules/mod_k2_content/tmpl/Default.php$ - [L]

RewriteRule ^modules/mod_k2_content.php$ - [L]

RewriteRule ^components/com_k2/controllers.php$ - [L]

still no success i was wondering if someone using joomla and k2 with master .htaccess add figure out how to add a exeption rule to k2 module

4

1 回答 1

0

我想我会写自己的答案......在htaccess中有一个名为(高级服务器保护)的部分

将 K2 扩展与 master .htaccess 一起使用删除这些行

## Disallow visual fingerprinting of Joomla! sites (module position dump)
## Initial idea by Brian Teeman and Ken Crowder, see:
## http://www.slideshare.net/brianteeman/hidden-joomla-secrets
## Improved by @nikosdion to work more efficiently and handle template
## and tmpl query parameters
RewriteCond %{QUERY_STRING} (^|&)tmpl=(component|system) [NC]
RewriteRule .* - [L]
RewriteCond %{QUERY_STRING} (^|&)t(p|emplate|mpl)= [NC]
RewriteRule .* - [F]

和本节

## Referrer filtering for common media files. Replace with your own domain name.

用这个替换最后一行

RewriteRule \.(jp(e?g|2)?|png|gif|bmp|js|swf|ico)$ - [F]

允许从 k2 加载 css..

享受。

于 2012-05-25T13:19:47.790 回答