Forum FAQForum FAQSearchSearch MemberlistMemberlist Forum ignore listForum ignore list RegisterRegister ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in
neću da mi "foo/" rewritea u "foo.php" !

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Server-side
View previous topic :: View next topic  
Author Message
Sulien



Joined: 04 Jan 2004
Posts: 2905
Location: Zagreb

PostPosted: 01.04.2005 17:24    Post subject: neću da mi "foo/" rewritea u "foo.php" ! Add user to your forum ignore list Reply with quote

Dakle kao što bi se dalo skužiti iz subjecta, prošle sam noći učio mod_rewrite da si olakšam posao na svom CMS-u LeaveMeBe

Uglavnom skužio sam sve, mod_rewrite je kickass and so on, ali kad sam počeo malo lupati po raznim imenima, slashevima, regexpima i to primijetio sam jednu sitnicu koja me smeta:

radio sam login form koji bi index includao u sebe preko GET-a, dakle URL /login/ sam rewriteao u /index.php?mode=login

To je po svim pravilima trebalo raditi ali nije radilo jer bi on uporno pokretao /login.php što ja zapravo nisam htio. Isprobavao sam malo i skužio da se oba "/bilošto" i "/bilošto/" automatski 'rewriteaju' u /bilošto.php makar ja taj rule nisam napisao. Mislio sam ispočetka da je to neki feat od mod_rewrite pa sam isključio cijeli modul, a 'feat' je nastavio raditi Confused moram reći da to nikad nisam prije primijetio Think

BTW -- Apache/1.3.33 (Win) + PHP 5.0.3
kako se to zove i gdje to isključiti, jer me smeta! do you feel lucky, punk? :givap

thnx Cheers!

EDIT: zaboravio sam napomenuti da "/foo" ili "/foo/" pozivaju "/foo.php" samo ako taj postoji... ako ne postoji onda rewrite rule dođe na svoje (ili 404 ako nema rule-ova)

Last edited by Sulien on 01.04.2005 19:24; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
xpi



Joined: 21 Jan 2004
Posts: 33

PostPosted: 01.04.2005 19:10    Post subject: Add user to your forum ignore list Reply with quote

Možda ti to ispravlja pravopisne pogreške... Laughing Da li jedno "CheckSpelling off" u .htaccess-u pomaže?
Back to top
View user's profile Send private message
Sulien



Joined: 04 Jan 2004
Posts: 2905
Location: Zagreb

PostPosted: 01.04.2005 19:30    Post subject: Add user to your forum ignore list Reply with quote

xpi Razz

ono što je zaista interesantno je da ako postoji rewrite rule "/login/" (sa recimo redirectom na nešto drugo) i file "/login.php", onda će se kao što sam opisao pozvati login.php... Pa zar rewrite rule-ovi nemaju prednost pred actually dohvatom fileova?? Ta mi prednost tog 'feature-a' uopće nije jasna
Back to top
View user's profile Send private message Send e-mail Visit poster's website
xpi



Joined: 21 Jan 2004
Posts: 33

PostPosted: 02.04.2005 12:04    Post subject: Add user to your forum ignore list Reply with quote

Nisam se šalio (puno), možda je stvarno riječ o Apacheovom spell-checkingu. Smile A rewrite mehanizam možda ne dolazi do izražaja jer si nešto zeznuo... Razz

Aj mi pošalji svoj httpd.conf mailom, da vidimo što će biti kod mene...
Back to top
View user's profile Send private message
Sulien



Joined: 04 Jan 2004
Posts: 2905
Location: Zagreb

PostPosted: 02.04.2005 13:37    Post subject: Add user to your forum ignore list Reply with quote

eto, pomogao si Smile

nije spell checking (provjerio sam, modul nije dignut), ali dok sam o njemu čitao naišao sam na mod_negotiation

guys at Apache wrote:
MultiViews

A MultiViews search is enabled by the MultiViews Option. If the server receives a request for /some/dir/foo and /some/dir/foo does not exist, then the server reads the directory looking for all files named foo.*, and effectively fakes up a type map which names all those files, assigning them the same media types and content-encodings it would have if the client had asked for one of them by name. It then chooses the best match to the client's requirements, and returns that document.

Eto, kao direktan odgovor na moja pitanja... čak i "foo" koriste Smile

Samo treba isključiti tu opciju onda Cool
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Server-side All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group