将httpd.ini转换为.htaccess

时间:2011-07-22 14:00:21

标签: mod-rewrite apache

有没有办法将httpd.ini转换为.htaccess,如果没有,我怎样才能让以下文本对.htaccess文件有效?:

[ISAPI_Rewrite]

# Defend your computer from some worm attacks
#RewriteRule .*(?:global.asa|default\.ida|root\.exe|\.\.).* . [F,I,O]

RewriteRule ^/home/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/keukens/?(([^/]*)/?)+? /index.php [L]

RewriteRule ^/keuken/fronten/$ /index.php?page=fronten  [L]
RewriteRule ^/keuken/fronten$ /index.php?page=fronten  [L]
RewriteRule ^/keuken/keukenbladen/$ /index.php?section=service&page=keukenbladen  [L]
RewriteRule ^/keuken/keukenbladen$ /index.php?section=service&page=keukenbladen  [L]
RewriteRule ^/keuken/grepen/$ /index.php?section=service&page=grepen  [L]
RewriteRule ^/keuken/grepen$ /index.php?section=service&page=grepen  [L]
RewriteRule ^/keuken/apparatuur/$ /index.php?section=service&page=apparatuur  [L]
RewriteRule ^/keuken/apparatuur$ /index.php?section=service&page=apparatuur  [L]
RewriteRule ^/keuken/opstellingen/$ /index.php?section=service&page=opstellingen  [L]
RewriteRule ^/keuken/opstellingen$ /index.php?section=service&page=opstellingen  [L]

RewriteRule ^/home/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/keukens/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/sanitair/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/tegels/?(([^/]*)/?)+? /index.php [L]

RewriteRule ^/aanbiedingen/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/service/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/trends/?(([^/]*)/?)+? /index.php [L]
RewriteRule ^/vacatures/$ ../service/vacatures [L]


RewriteRule ^/over_piet_klerkx/$ /index.php?section=algemeen&page=over [L]
RewriteRule ^/over_piet_klerkx$ /index.php?section=algemeen&page=over [L]

RewriteRule ^/filialen/$ /index.php?section=algemeen&page=filialen [L]
RewriteRule ^/filialen$ /index.php?section=algemeen&page=filialen [L]

RewriteRule ^/contact/$ /index.php?section=service&page=contact [L]
RewriteRule ^/contact$ /index.php?section=service&page=contact [L]

RewriteRule ^/orderstatus/$ /index.php?section=algemeen&page=orderstatus  [L]
RewriteRule ^/orderstatus$ /index.php?section=algemeen&page=orderstatus  [L]

RewriteRule ^/acties/?(([^/]*)/?)+? /index.php  [L]
RewriteRule ^/actiepreview/?(([^/]*)/?)+? /index.php  [L]


RewriteRule ^/keuken/aanrecht.php /keukens [I,RP]
RewriteRule ^/keuken/aanrechtblad.php /keukens [I,RP]
RewriteRule ^/keuken/aanrechtbladen.php /keukens [I,RP]
RewriteRule ^/keuken/aanrechtbladen-graniet.php /keukens [I,RP]
RewriteRule ^/keuken/aanrecht-graniet.php /keukens [I,RP]
RewriteRule ^/keuken/amerikaanse-koelkast.php /keukens [I,RP]
RewriteRule ^/keuken/badkamers-keukens.php /index.php [I,RP]
RewriteRule ^/keuken/design-keukens.php /keukens [I,RP]
RewriteRule ^/keuken/eiken-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/elektrisch-fornuis.php /keukens [I,RP]
RewriteRule ^/keuken/exclusieve-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/fornuizen.php /keukens [I,RP]
RewriteRule ^/keuken/gas-fornuizen.php /keukens [I,RP]
RewriteRule ^/keuken/goedkope-showroom-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/granieten-aanrecht.php /keukens [I,RP]
RewriteRule ^/keuken/greeploze-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/hoekkeuken.php /keukens [I,RP]
RewriteRule ^/keuken/hoek-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/inbouwapparatuur.php /keukens [I,RP]
RewriteRule ^/keuken/inbouwapparatuur-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-apparatuur-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-combi-magnetrons.php /keukens [I,RP]
RewriteRule ^/keuken/inbouwkeuken.php /keukens [I,RP]
RewriteRule ^/keuken/inbouwkeukens.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-koelkast.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-magnetron.php /keukens [I,RP]
RewriteRule ^/keuken/inbouwoven.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-oven.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-oven-magnetron.php /keukens [I,RP]
RewriteRule ^/keuken/inbouw-vaatwasser.php /keukens [I,RP]
RewriteRule ^/keuken/index.php /keukens [I,RP]
RewriteRule ^/keuken/italiaanse-keukens.php /keukens [I,RP]
RewriteRule ^/keuken/keramische-kookplaat.php /keukens [I,RP]
RewriteRule ^/keuken/keuken.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-aanbiedingen.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-amersfoort.php /keukens [I,RP]
RewriteRule ^/keuken/keukenapparatuur.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-apparatuur.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-apparatuur-kopen.php /keukens [I,RP]
RewriteRule ^/keuken/keukenblad.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-blad.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-blad.php /keukens [I,RP]
RewriteRule ^/keuken/keukenblok.php /keukens [I,RP]
RewriteRule ^/keuken/keukencentra.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keukencentrum.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keuken-centrum.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keukeninbouw.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-inbouwapparatuur.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-inrichten.php /keukens [I,RP]
RewriteRule ^/keuken/keukeninrichting.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-inrichting.php /keukens [I,RP]
RewriteRule ^/keuken/keukenkast.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-kast.php /keukens [I,RP]
RewriteRule ^/keuken/keukenkasten.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-kasten.php /keukens [I,RP]
RewriteRule ^/keuken/keukenmontage.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-montage.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-nl.php /keukens [I,RP]
RewriteRule ^/keuken/keukenontwerp.php /service/ontwerptool [I,RP]
RewriteRule ^/keuken/keuken-ontwerp.php /service/ontwerptool [I,RP]
RewriteRule ^/keuken/keuken-ontwerpen.php /service/ontwerptool [I,RP]
RewriteRule ^/keuken/keukens.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-samenstellen.php /service/ontwerptool [I,RP]
RewriteRule ^/keuken/keukens-amersfoort.php /service/vestigingen/piet_klerkx_amersfoort_keukens_en_badkamers/120 [I,RP]
RewriteRule ^/keuken/keukens-belgie.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keukens-en-badkamers.php /index.php [I,RP]
RewriteRule ^/keuken/keuken-showroom.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keuken-showrooms.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keukens-nl.php /keukens [I,RP]
RewriteRule ^/keuken/keukenspeciaalzaak.php /keukens [I,RP]
RewriteRule ^/keuken/keukenspeciaalzaken.php /keukens [I,RP]
RewriteRule ^/keuken/keukens-showroom.php /keukens [I,RP]
RewriteRule ^/keuken/keukens-waalwijk.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keuken-tekenen.php /service/ontwerptool [I,RP]
RewriteRule ^/keuken/keukenverkoop.php /keukens [I,RP]
RewriteRule ^/keuken/keuken-waalwijk.php /service/vestigingen/piet_klerkx_waalwijk_keukens/76 [I,RP]
RewriteRule ^/keuken/keukenzaak.php /keukens [I,RP]
RewriteRule ^/keuken/keukenzaken.php /keukens [I,RP]
RewriteRule ^/keuken/klassieke-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/klassieke-keukens.php /keukens [I,RP]
RewriteRule ^/keuken/klein-keukenblok.php /keukens [I,RP]
RewriteRule ^/keuken/koelkast.php /keukens [I,RP]
RewriteRule ^/keuken/koelkast-kopen.php /keukens [I,RP]
RewriteRule ^/keuken/kookeiland.php /keukens [I,RP]
RewriteRule ^/keuken/moderne-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/moderne-keukens.php /keukens [I,RP]
RewriteRule ^/keuken/modern-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/mooie-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/nieuwe-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/piet-klerkx.php /keukens [I,RP]
RewriteRule ^/keuken/poggenpohl.php /keukens [I,RP]
RewriteRule ^/keuken/showroomkeuken.php /keukens [I,RP]
RewriteRule ^/keuken/showroom-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/showroomkeukens.php /keukens [I,RP]
RewriteRule ^/keuken/showroom-keukens.php /keukens [I,RP]
RewriteRule ^/keuken/siematic-hoekkeuken.php /keukens [I,RP]
RewriteRule ^/keuken/siematic-keuken.php /keukens [I,RP]
RewriteRule ^/keuken/vaatwasser.php /keukens [I,RP]
RewriteRule ^/keuken/vaatwassers.php /keukens [I,RP]
RewriteRule ^/keuken/verkoop-keuken.php /keukens [I,RP]

RewriteRule ^/badkamer/aluminium-wasbak.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/baden-sanitair.php /sanitair/ligbade [I,RP]
RewriteRule ^/badkamer/badkamer.php /sanitair/badkamers/ [I,RP]
RewriteRule ^/badkamer/badkamer-aanbieding.php /aanbiedingen [I,RP]
RewriteRule ^/badkamer/badkamer-amersfoort.php /service/vestigingen/piet_klerkx_amersfoort_keukens_en_badkamers/120 [I,RP]
RewriteRule ^/badkamer/badkamer-design.php /sanitair/badkamers/ [I,RP]
RewriteRule ^/badkamer/badkamer-idee.php /sanitair/badkamers/ [I,RP]
RewriteRule ^/badkamer/badkamer-ideeen.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-inrichten.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-inrichting.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamermeubel.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badkamer-meubel.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badkamermeubelen.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badkamermeubels.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badkamer-meubels.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badkamer-nl.php /sanitair/badkamers/ [I,RP]
RewriteRule ^/badkamer/badkamer-noord-brabant.php /service/vestigingen/piet_klerkx_waalwijk_badkamers_en_tegels/226 [I,RP]
RewriteRule ^/badkamer/badkamerontwerp.php /service/ontwerptool [I,RP]
RewriteRule ^/badkamer/badkamer-ontwerp.php /service/ontwerptool [I,RP]
RewriteRule ^/badkamer/badkamer-ontwerpen.php /service/ontwerptool [I,RP]
RewriteRule ^/badkamer/badkamer-radiator.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamers.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-sanitair.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-showroom.php /service/vestigingen [I,RP]
RewriteRule ^/badkamer/badkamer-showrooms.php /service/vestigingen [I,RP]
RewriteRule ^/badkamer/badkamers-nl.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamerspecialist.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-specialist.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamertegel.php /tegels/vloertegels [I,RP]
RewriteRule ^/badkamer/badkamer-tegel.php /tegels [I,RP]
RewriteRule ^/badkamer/badkamertegels.php /tegels [I,RP]
RewriteRule ^/badkamer/badkamer-tegels.php /tegels [I,RP]
RewriteRule ^/badkamer/badkamer-ventilatoren.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-verbouwen.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkamer-vloertegel.php /tegels/vloertegels [I,RP]
RewriteRule ^/badkamer/badkamer-waalwijk.php /service/vestigingen/piet_klerkx_waalwijk_badkamers_en_tegels/226 [I,RP]
RewriteRule ^/badkamer/badkamer-zoeken.php /sanitair [I,RP]
RewriteRule ^/badkamer/badkuip.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/badkuipen.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/badmeubel.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badmeubelen.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badmeubels.php /sanitair/badmeubelen/ [I,RP]
RewriteRule ^/badkamer/badwand.php /sanitair [I,RP]
RewriteRule ^/badkamer/bubbelbaden.php /sanitair/whirlpools/ [I,RP]
RewriteRule ^/badkamer/design-badkamer.php /sanitair [I,RP]
RewriteRule ^/badkamer/design-badkamers.php /sanitair [I,RP]
RewriteRule ^/badkamer/design-radiator.php /sanitair [I,RP]
RewriteRule ^/badkamer/design-radiatoren.php /sanitair [I,RP]
RewriteRule ^/badkamer/design-sanitair.php /sanitair [I,RP]
RewriteRule ^/badkamer/douchebak.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douchecabine.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-cabine.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-cabine-kopen.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douchecabines.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-deur.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-kranen.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/douchemengkraan.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/douchepaneel.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douchepanelen.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-stoomcabine.php /sanitair/stoomcabines/ [I,RP]
RewriteRule ^/badkamer/doucheunit.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-unit.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-verkoop.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douchewand.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douche-wand.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/douchewanden.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/dubbel-wastafel.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/goedkoop-sanitair.php /sanitair [I,RP]
RewriteRule ^/badkamer/hangtoilet.php /sanitair/toiletten/ [I,RP]
RewriteRule ^/badkamer/hoekbad.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/hoekbaden.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/inbouwbad.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/inbouw-douchebak.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/inbouwtoilet.php /sanitair/toiletten/ [I,RP]
RewriteRule ^/badkamer/inbouw-toilet.php /sanitair/toiletten/ [I,RP]
RewriteRule ^/badkamer/index.php /sanitair [I,RP]
RewriteRule ^/badkamer/inloopdouche.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/kranen-in-de-badkamer.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/ligbad.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/ligbaden.php /sanitair/ligbaden/ [I,RP]
RewriteRule ^/badkamer/luxe-badkamer.php /sanitair [I,RP]
RewriteRule ^/badkamer/moderne-badkamer.php /sanitair [I,RP]
RewriteRule ^/badkamer/nieuwe-badkamer.php /sanitair [I,RP]
RewriteRule ^/badkamer/sanitair.php /sanitair [I,RP]
RewriteRule ^/badkamer/sanitair-badkamer.php /sanitair [I,RP]
RewriteRule ^/badkamer/sanitair-douchecabine.php /sanitair/douchewanden/ [I,RP]
RewriteRule ^/badkamer/sanitaire-units.php /sanitair [I,RP]
RewriteRule ^/badkamer/sanitair-groothandel.php /service/vestigingen [I,RP]
RewriteRule ^/badkamer/stoomcabine.php /sanitair/stoomcabines/ [I,RP]
RewriteRule ^/badkamer/stoomcabines.php /sanitair/stoomcabines/ [I,RP]
RewriteRule ^/badkamer/thermostaatkraan.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/toilet.php /sanitair/toiletten/ [I,RP]
RewriteRule ^/badkamer/vloertegels.php /tegels/vloertegels [I,RP]
RewriteRule ^/badkamer/wasbak.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/wasbakken.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/wastafel.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/wastafels.php /sanitair/kranen/ [I,RP]
RewriteRule ^/badkamer/whirlpool-bad.php /sanitair/whirlpools/ [I,RP]
RewriteRule ^/badkamer/whirlpool-inbouw.php /sanitair/whirlpools/ [I,RP]
RewriteRule ^/badkamer/whirlpoolsystemen.php /sanitair/whirlpools/ [I,RP]

1 个答案:

答案 0 :(得分:1)

ISAPI_Rewrite v2 转换为.htaccess规则应该没有什么大问题。

规则非常相似

  1. 很可能需要删除所有规则模式的前导斜杠(如果这些规则将放在.htaccess而不是服务器配置中):

    RewriteRule ^/keuken/aanrecht.php => RewriteRule ^keuken/aanrecht.php

  2. 你肯定会替换标志(几乎全部) - 简单的查找和替换将完成这项工作:

    • [I] => [NC]
    • [RP] => [R=301,L]

  3. BTW ,您可以优化一些规则。例如,这些2可以用.htaccess中的单行代替:

    RewriteRule ^/keuken/fronten/$ /index.php?page=fronten  [L]
    RewriteRule ^/keuken/fronten$ /index.php?page=fronten  [L]
    =>
    RewriteRule ^keuken/fronten/?$ /index.php?page=fronten [L]