Uutiset:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu
Advertisement:

Problema pretty urls

Aloittaja pianista, tammikuu 09, 2009, 02:39:03 IP

« edellinen - seuraava »

pianista

Lo instale y funciona de maravilla, lo único alguien sabe como hacer para pasar las direcciones a .html?
Me imagino que tendré que modificar el ReWrite y eso...no?
Saludos y gracias

Miguelithox

Debes modificar el archivo .htaccess (Con el bloc de notas) y al final colocale .html

pianista

#   Pretty URLs mod
#   http://code.google.com/p/prettyurls/
#   .htaccess file generated automatically on: January 9, 2009, 19:30

RewriteEngine on

#   Rules for: actions
RewriteRule ^(activate|admin|announce|arcade|managegames|arcadecategory|arcadesettings|ban)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(boardrecount|buddy|calendar|cleanperms|collapse|convertentities|convertutf8|coppa)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(deletemsg|detailedversion|display|dlattach|dumpdb|editpoll|editpoll2|featuresettings)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(featuresettings2|findmember|help|helpadmin|im|jsoption|jsmodify|lock)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(lockVoting|login|login2|logout|maintain|manageattachments|manageboards|managecalendar)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(managesearch|markasread|membergroups|mergetopics|mlist|modifycat|modifykarma|modlog)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(movetopic|movetopic2|news|notify|notifyboard|optimizetables|packageget|packages)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(permissions|pgdownload|pm|post|post2|postsettings|printpage|profile)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(profile2|quotefast|quickmod|quickmod2|recent|regcenter|register|register2)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(reminder|removetopic2|removeoldtopics2|removepoll|repairboards|reporttm|reports|requestmembers)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(rpg|search|search2|sendtopic|serversettings|serversettings2|smileys|smstats)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(spellcheck|splittopics|stats|sticky|theme|trackip|about:mozilla|about:unknown)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(unread|unreadreplies|viewErrorLog|viewmembers|viewprofile|verificationcode|vote|viewquery)/?$ ./index.php?pretty;action=$1 [L,QSA]
RewriteRule ^(who|\.xml|chess|chessXml|chessChat|chess_admin|chess_admin_maint)/?$ ./index.php?pretty;action=$1 [L,QSA]

#   Rules for: boards
RewriteRule ^([-_!~*'()$a-zA-Z0-9]+)/?$ ./index.php?pretty;board=$1.0 [L,QSA]
RewriteRule ^([-_!~*'()$a-zA-Z0-9]+)/([0-9]*)/?$ ./index.php?pretty;board=$1.$2 [L,QSA]

#   Rules for: topics
RewriteRule ^([-_!~*'()$a-zA-Z0-9]+)/([-_!~*'()$a-zA-Z0-9]+)/?$ ./index.php?pretty;board=$1;topic=$2.0 [L,QSA]
RewriteRule ^([-_!~*'()$a-zA-Z0-9]+)/([-_!~*'()$a-zA-Z0-9]+)/([0-9]*|msg[0-9]*|new)/?$ ./index.php?pretty;board=$1;topic=$2.$3 [L,QSA]

Al final de donde??
Muchisimas gracias;)

pianista

Vale he modificado el .htaccess y me funciona poniendo .html al final de la url, el problema es que el htacces funciona, pero todos los enlaces del foro estan sin.html, que fichero tengo que modificar para que me aparezcan con .html?
Saludos

Miguelithox

a todas al final le debes agregar un .html (del .htacces) antes de los paréntesis []

Advertisement: