Ir para conteúdo

Arquivado

Este tópico foi arquivado e está fechado para novas respostas.

djeco

URLs amigáveis como no wordpress

Recommended Posts

Li alguns tópicos sobre URL amigáveis, e todos que encontrei falavam para alterar o arquivo do apache e depois criar uma index com IFs para verificar o que estava na URL e então incluir o arquivo certo.

 

Mas como faço isso de forma dinâmica como no wordpress?

 

obrigado

Compartilhar este post


Link para o post
Compartilhar em outros sites

bom pelo poco q sei você tem q ter um arquivo *.HTACESS

 

seu servidor tem q esta com o modulo rewrite ativado

 

no arquivo q vai o seu cabeçalho você tem q faze ruma funçãozinha pra verificar as urls em seu site[

 

e você vai ter q entender um pouco de expressões regulares

 

arquivo .htaccess

# $Author: zx $ 
# $Date: 2003/08/17 14:03:21 $

# deny most common except .php
<FilesMatch "\.(inc|tpl|h|ihtml|sql|ini|conf|class|bin|spd|theme|module)$">
deny from all
</FilesMatch>

<Limit GET PUT POST>
  Order Allow,Deny
  Allow from all
</Limit>

php_flag register_globals on

RewriteEngine on

#The next lines check for Email Spammers Robots and redirect them to a fake page
RewriteCond %{HTTP_USER_AGENT} ^Alexibot				[OR]
RewriteCond %{HTTP_USER_AGENT} ^asterias				[OR]
RewriteCond %{HTTP_USER_AGENT} ^BackDoorBot			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Black.Hole			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^BlackWidow			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^BlowFish				[OR]
RewriteCond %{HTTP_USER_AGENT} ^BotALot				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^BuiltBotTough		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Bullseye				[OR]
RewriteCond %{HTTP_USER_AGENT} ^BunnySlippers		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Cegbfeieh			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^CheeseBot			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^CherryPicker			[OR]
RewriteCond %{HTTP_USER_AGENT} ^ChinaClaw			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^CopyRightCheck		  [OR]
RewriteCond %{HTTP_USER_AGENT} ^cosmos				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Crescent				[OR]
RewriteCond %{HTTP_USER_AGENT} ^Custo				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^DISCo				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^DittoSpyder			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Download\ Demon		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^eCatch				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^EirGrabber			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^EmailCollector		  [OR]
RewriteCond %{HTTP_USER_AGENT} ^EmailSiphon			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^EmailWolf			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^EroCrawler			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Express\ WebPictures	[OR]
RewriteCond %{HTTP_USER_AGENT} ^ExtractorPro			[OR]
RewriteCond %{HTTP_USER_AGENT} ^EyeNetIE				[OR]
RewriteCond %{HTTP_USER_AGENT} ^FlashGet				[OR]
RewriteCond %{HTTP_USER_AGENT} ^Foobot				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^FrontPage			   [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^GetRight				[OR]
RewriteCond %{HTTP_USER_AGENT} ^GetWeb!				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Go-Ahead-Got-It		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Googlebot-Image		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Go!Zilla				[OR]
RewriteCond %{HTTP_USER_AGENT} ^GrabNet				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Grafula				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Harvest				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^hloader				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^HMView				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^httplib				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^HTTrack				 [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^humanlinks			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^ia_archiver			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Image\ Stripper		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Image\ Sucker		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Indy\ Library		   [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^InfoNaviRobot		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^InterGET				[OR]
RewriteCond %{HTTP_USER_AGENT} ^Internet\ Ninja		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^JennyBot				[OR]
RewriteCond %{HTTP_USER_AGENT} ^JetCar				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^JOC\ Web\ Spider		[OR]
RewriteCond %{HTTP_USER_AGENT} ^Kenjin.Spider		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Keyword.Density		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^larbin				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^LeechFTP				[OR]
RewriteCond %{HTTP_USER_AGENT} ^LexiBot				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^libWeb/clsHTTP		  [OR]
RewriteCond %{HTTP_USER_AGENT} ^LinkextractorPro		[OR]
RewriteCond %{HTTP_USER_AGENT} ^LinkScan/8.1a.Unix	  [OR]
RewriteCond %{HTTP_USER_AGENT} ^LinkWalker			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^lwp-trivial			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mass\ Downloader		[OR]
RewriteCond %{HTTP_USER_AGENT} ^Mata.Hari			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Microsoft.URL		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^MIDown\ tool			[OR]
RewriteCond %{HTTP_USER_AGENT} ^MIIxpc				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mister.PiX			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mister\ PiX			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^moget				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/2			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/3.Mozilla/2.01  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla.*NEWT		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Navroad				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^NearSite				[OR]
RewriteCond %{HTTP_USER_AGENT} ^NetAnts				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^NetMechanic			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^NetSpider			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Net\ Vampire			[OR]
RewriteCond %{HTTP_USER_AGENT} ^NetZIP				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^NICErsPRO			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^NPBot				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Octopus				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Offline.Explorer		[OR]
RewriteCond %{HTTP_USER_AGENT} ^Offline\ Explorer	   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Offline\ Navigator	  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Openfind				[OR]
RewriteCond %{HTTP_USER_AGENT} ^PageGrabber			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Papa\ Foto			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^pavuk				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^pcBrowser			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^ProPowerBot/2.14		[OR]
RewriteCond %{HTTP_USER_AGENT} ^ProWebWalker			[OR]
RewriteCond %{HTTP_USER_AGENT} ^ProWebWalker			[OR]
RewriteCond %{HTTP_USER_AGENT} ^QueryN.Metasearch	   [OR]
RewriteCond %{HTTP_USER_AGENT} ^ReGet				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^RepoMonkey			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^RMA					 [OR]
RewriteCond %{HTTP_USER_AGENT} ^SiteSnagger			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^SlySearch			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^SmartDownload		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^SpankBot				[OR]
RewriteCond %{HTTP_USER_AGENT} ^spanner				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^SuperBot				[OR]
RewriteCond %{HTTP_USER_AGENT} ^SuperHTTP			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Surfbot				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^suzuran				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Szukacz/1.4			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^tAkeOut				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Teleport				[OR]
RewriteCond %{HTTP_USER_AGENT} ^Teleport\ Pro		   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Telesoft				[OR]
RewriteCond %{HTTP_USER_AGENT} ^The.Intraformant		[OR]
RewriteCond %{HTTP_USER_AGENT} ^TheNomad				[OR]
RewriteCond %{HTTP_USER_AGENT} ^TightTwatBot			[OR]
RewriteCond %{HTTP_USER_AGENT} ^Titan				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^toCrawl/UrlDispatcher   [OR]
RewriteCond %{HTTP_USER_AGENT} ^toCrawl/UrlDispatcher   [OR]
RewriteCond %{HTTP_USER_AGENT} ^True_Robot			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^turingos				[OR]
RewriteCond %{HTTP_USER_AGENT} ^TurnitinBot/1.5		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^URLy.Warning			[OR]
RewriteCond %{HTTP_USER_AGENT} ^VCI					 [OR]
RewriteCond %{HTTP_USER_AGENT} ^VoidEYE				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebAuto				 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebBandit			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebCopier			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebEMailExtrac.*		[OR]
RewriteCond %{HTTP_USER_AGENT} ^WebEnhancer			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebFetch				[OR]
RewriteCond %{HTTP_USER_AGENT} ^WebGo\ IS			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Web.Image.Collector	 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Web\ Image\ Collector   [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebLeacher			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebmasterWorldForumBot  [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebReaper			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebSauger			   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Website\ eXtractor	  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Website.Quester		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Website\ Quester		[OR]
RewriteCond %{HTTP_USER_AGENT} ^Webster.Pro			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebStripper			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^Web\ Sucker			 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebWhacker			  [OR]
RewriteCond %{HTTP_USER_AGENT} ^WebZip				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Wget					[OR]
RewriteCond %{HTTP_USER_AGENT} ^Widow				   [OR]
RewriteCond %{HTTP_USER_AGENT} ^[Ww]eb[Bb]andit		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WWW-Collector-E		 [OR]
RewriteCond %{HTTP_USER_AGENT} ^WWWOFFLE				[OR]
RewriteCond %{HTTP_USER_AGENT} ^Xaldon\ WebSpider	   [OR]
RewriteCond %{HTTP_USER_AGENT} ^Xenu's				  [OR]
RewriteCond %{HTTP_USER_AGENT} ^Zeus
RewriteCond %{HTTP_USER_AGENT} ^admin
RewriteRule ^.*$ emailsforyou.php  [L]


#RewriteCond %{HTTP_USER_AGENT}  ^-?$
#RewriteRule ^.*$ /www/nukecops/noID.php [L]




#index
RewriteRule ^index.html index.php

#Articles
RewriteRule ^faleconosco.html ?modulos;Contato;index;
RewriteRule ^noticias.html ?modulos;Noticias;index
RewriteRule ^clientes.html ?modulos;paginas;index;clientes
RewriteRule ^sobre.html ?modulos;paginas;index;empresa

cabecalho.php

function replace_for_mod_rewrite(&$s) {
$urlin = array(
"'(?<!/)index.php'",
"'(?<!/)sec.php\?p=News&file=article&sid=([0-9]*)&mode=([a-z]*)&order=([0-9]*)&thold=([0-9]*)'",
"'(?<!/)sec.php\?p=News&file=article&sid=([0-9]*)'",
"'(?<!/)sec.php\?p=News&file=article&sid=([0-9]*)'",
"'(?<!/)sec.php\?p=News&new_topic=([0-9]*)'",
"'(?<!/)sec.php\?p=Stories_Archive&sa=show_month&year=([0-9]*)&month=([0-9]*)&month_l=([a-zA-Z]*)'",
"'(?<!/)sec.php\?p=Stories_Archive'",
"'(?<!/)sec.php\?p=Downloads&d_op=viewdownload(comments|details|editorial)&lid=([0-9]*)&ttitle=([/:\-\'{}()._&a-zA-Z0-9+= ]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=modifydownloadrequest&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=brokendownload&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=NewDownloads&newdownloadshowdays=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=NewDownloadsDate&selectdate=([a-zA-Z0-9+]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=getit&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=ratedownload&lid=([0-9]*)&ttitle=([/:\-\'{}()._&a-zA-Z0-9+= ]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=ratedownload&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=ratedownload&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=(TopRated|MostPopular)&ratenum=([0-9]*)&ratetype=(num|percent)'",
"'(?<!/)sec.php\?p=Downloads&d_op=(AddDownload|NewDownloads|MostPopular|TopRated)'",
"'(?<!/)sec.php\?p=Downloads&d_op=viewdownload&cid=([0-9]*)&orderby=([a-zA-Z0-9+]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=viewdownload&cid=([0-9]*)&min=([0-9]*)&orderby=([a-zA-Z0-9+]*)&show=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=search&query=([/:\-\'{}()._&a-zA-Z0-9+=]*)&min=([0-9]*)&orderby=([a-zA-Z0-9+]*)&show=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=search&query=([/:\-\'{}()._&a-zA-Z0-9+= ]*)&orderby=([a-zA-Z0-9+]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=search&query=([/:\-\'{}()._&a-zA-Z0-9+=]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=outsidedownloadsetup&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=viewdownload&cid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads&d_op=viewdownload&cid=([0-9]*)'",
"'(?<!/)sec.php\?p=Downloads'",
"'(?<!/)sec.php\?p=Journal&file=search&bywhat=aid&exact=1&forwhat=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Journal&file=(search|delete|commentkill)&(bywhat|jid|onwhat)=([a-zA-Z0-9]*)&(forwhat|ref)=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Journal&file=([a-zA-Z0-9+]*)&(jid|onwhat|disp|op|disp)=([a-zA-Z0-9+]*)'",
"'(?<!/)sec.php\?p=Journal&(file|op)=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Journal'",
"'(?<!/)sec.php\?p=Reviews&rop=write_review'",
"'(?<!/)sec.php\?p=Reviews&rop=preview_review'",
"'(?<!/)sec.php\?p=Reviews&rop=showcontent&id=([0-9]*)&page=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=showcontent&id=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=showcontent&id=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=postcomment&id=([0-9]*)&title=([/:\-\'{}()\._&a-zA-Z0-9+=\?\%]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=del_review&id_del=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=mod_review&id=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=del_comment&cid=([0-9]*)&id=([0-9]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=([a-zA-Z0-9]*)&field=([a-z]*)&order=([a-zA-Z]*)'",
"'(?<!/)sec.php\?p=Reviews&rop=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Reviews'",
"'(?<!/)sec.php\?p=Submit_News'",
"'(?<!/)sec.php\?p=Search'",
"'(?<!/)sec.php\?p=Topics'",
"'(?<!/)sec.php\?p=Top&zx=([a-zA-Z0-9+]*)'",
"'(?<!/)sec.php\?p=Top'",
"'(?<!/)sec.php\?p=Portifolio&file=show&uid=([0-9]*)'",
"'(?<!/)sec.php\?p=Portifolio&pa=showpage'",
"'(?<!/)sec.php\?p=Surveys&op=results&pollID=([a-zA-Z0-9]*)&mode=([0-9]*)&order=([0-9]*)&thold=([0-9]*)'",
"'(?<!/)sec.php\?p=Surveys&file=comments'",
"'(?<!/)sec.php\?p=Surveys&op=results&pollID=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Surveys&pollID=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Surveys'",
"'(?<!/)sec.php\?p=Recommend_Us&op=SiteSent&fname=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Recommend_Us'",
"'(?<!/)sec.php\?p=Domínios'",
"'(?<!/)sec.php\?p=Sites'",
"'(?<!/)sec.php\?p=Linux'",
"'(?<!/)sec.php\?p=Redes'",
"'(?<!/)sec.php\?p=Manutenção'",
"'(?<!/)sec.php\?p=Hosting&file=kontakt'",
"'(?<!/)sec.php\?p=Hosting&file=tellimus'",
"'(?<!/)sec.php\?p=Hosting&file=index'",
"'(?<!/)sec.php\?p=Hosting&op=domeen'",
"'(?<!/)sec.php\?p=Hosting&op=kontakt'",
"'(?<!/)sec.php\?p=Hosting&op=klienditugi'",
"'(?<!/)sec.php\?p=Hosting&op=liitumine'",
"'(?<!/)sec.php\?p=Hosting&op=leping'",
"'(?<!/)sec.php\?p=Hosting&op=hinnakiri'",
"'(?<!/)sec.php\?p=Hosting&op=paketid'",
"'(?<!/)sec.php\?p=Hosting'",
"'(?<!/)sec.php\?p=WebMail'",
"'(?<!/)sec.php\?p=A_Empresa'",
"'(?<!/)sec.php\?p=FAQ&myfaq=yes&id_cat=([0-9]*)&categories=([a-zA-Z0-9\.\+\&\-\/\;%]*)'",
"'(?<!/)sec.php\?p=FAQ'",
"'(?<!/)sec.php\?p=Construtor&file=saibamais'",
"'(?<!/)sec.php\?p=Construtor&file=guarda'",
"'(?<!/)sec.php\?p=Construtor'",
"'(?<!/)sec.php\?p=Feedback&file=enviado'",
"'(?<!/)sec.php\?p=Feedback&file=send'",
"'(?<!/)sec.php\?p=Feedback'",
"'(?<!/)sec.php\?p=Content&pa=showpage&pid=([0-9]*)&page=([0-9]*)'",
"'(?<!/)sec.php\?p=Content&pa=list_pages_categories&cid=([0-9]*)'",
"'(?<!/)sec.php\?p=Content&pa=showpage&pid=([0-9]*)'",
"'(?<!/)sec.php\?p=Content&pa=showpage&pid=([0-9]*)'",
"'(?<!/)sec.php\?p=Content'",
"'(?<!/)sec.php\?p=Boletim&file=aviso'",
"'(?<!/)sec.php\?p=Boletim&file=send'",
"'(?<!/)sec.php\?p=Boletim'",
"'(?<!/)sec.php\?p=coppermine&cat=([0-9]*)&page=([0-9]*)'",
"'(?<!/)sec.php\?p=coppermine&file=thumbnails&album=([0-9]*)&page=([0-9]*)'",
"'(?<!/)sec.php\?p=coppermine&file=displayimage&pos=-([0-9]*)'",
"'(?<!/)sec.php\?p=coppermine&file=displayimage&album=([0-9]*)&pos=([0-9]*)'",
"'(?<!/)sec.php\?p=coppermine&file=thumbnails&album=([0-9]*)'",
"'(?<!/)sec.php\?p=coppermine'",
"'(?<!/)sec.php\?p=Forums&file=viewforum&f=([0-9]+)&topicdays=([0-9]+)&start=([0-9]+)'",
"'(?<!/)sec.php\?p=Forums&file=viewforum&f=([0-9]*)&(mark|start)=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=viewforum&f=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=viewtopic&t=([0-9]+)&start=([0-9]+)&postdays=([0-9]+)&postorder=asc&highlight='",
"'(?<!/)sec.php\?p=Forums&file=viewtopic&t=([0-9]+)&postdays=([0-9]+)&postorder=asc&start=([0-9]+)'",
"'(?<!/)sec.php\?p=Forums&file=viewtopic&t=([0-9]*)&(start|view|highlight)=([/:\-\'(){}.&=_a-zA-Z0-9 ]*)'",
"'(?<!/)sec.php\?p=Forums&file=viewtopic&t=([0-9]*)&([a-zA-Z0-9]*)=topic&start=0'",
"'(?<!/)sec.php\?p=Forums&file=viewtopic&(p|t)=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=profile&mode=register&agreed=true&coppa=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=profile&mode=register&agreed=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=modcp&mode=([a-zA-Z0-9_]*)&p=([0-9_&]*)&t=([a-zA-Z0-9_&=\.\;]*)'",
"'(?<!/)sec.php\?p=Forums&file=modcp&t=([0-9]*)&mode=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&t=([0-9]*)&popup=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)&(p|t|f|u|popup)=([0-9]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&mode=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=search&([a-zA-Z0-9_]*)=([a-zA-Z0-9_]*)&([a-zA-Z0-9_]*)=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)&([a-zA-Z0-9_]*)=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums&file=index'",
"'(?<!/)sec.php\?p=Forums&file=([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Forums'",
"'(?<!/)sec.php\?p=Sections&op=viewarticle&artid=([0-9]*)&page=([0-9]*)'",
"'(?<!/)sec.php\?p=Sections&op=(printpage|viewarticle)&artid=([0-9]*)'",
"'(?<!/)sec.php\?p=Sections&op=listarticles&secid=([0-9]*)'",
"'(?<!/)sec.php\?p=Sections'",
"'(?<!/)sec.php\?p=Statistics&op=DailyStats&year=([0-9]*)&month=([0-9]*)&date=([0-9]*)'",
"'(?<!/)sec.php\?p=Statistics&op=MonthlyStats&year=([0-9]*)&month=([0-9]*)'",
"'(?<!/)sec.php\?p=Statistics&op=YearlyStats&year=([0-9]*)'",
"'(?<!/)sec.php\?p=Statistics&op=Stats'",
"'(?<!/)sec.php\?p=Statistics'",
"'(?<!/)sec.php\?p=Your_Account&op=userinfo&bypass=1&username=([a-zA-Z0-9_-]*)'",
"'(?<!/)sec.php\?p=Your_Account&file=admin&op=CookieConfig'",
"'(?<!/)sec.php\?p=Your_Account&file=admin&op=UsersConfig'",
"'(?<!/)sec.php\?p=Your_Account&file=admin&op=listpending'",
"'(?<!/)sec.php\?p=Your_Account&file=admin'",
"'(?<!/)sec.php\?p=Your_Account&file=admin&op=listnormal&query=([a-zA-Z0-9_-]*)'",
"'(?<!/)sec.php\?p=Your_Account&op=userinfo&username=([a-zA-Z0-9_-]*)'",
"'(?<!/)sec.php\?p=Your_Account&file=([a-zA-Z0-9_]*)&op=deleteUser&chng_uid=([0-9]*)'",
"'(?<!/)sec.php\?p=Your_Account&file=([a-zA-Z0-9_]*)&op=suspendUser&chng_uid=([0-9]*)'",
"'(?<!/)sec.php\?p=Your_Account&file=([a-zA-Z0-9_]*)&op=modifyUser&chng_uid=([0-9]*)'",
"'(?<!/)sec.php\?p=Your_Account&op=avatarsave&category=([a-zA-Z0-9_]*)&avatar=([a-zA-Z0-9_]*).([a-zA-Z0-9_]*)'",
"'(?<!/)sec.php\?p=Your_Account&op=avatarlist'",
"'(?<!/)sec.php\?p=Your_Account&op=ShowCookies'",
"'(?<!/)sec.php\?p=Your_Account&op=ShowCookiesRedirect'",
"'(?<!/)sec.php\?p=Your_Account&op=pass_lost'",
"'(?<!/)sec.php\?p=Your_Account&op=new_user'",
"'(?<!/)sec.php\?p=Your_Account&op=logout'",
"'(?<!/)sec.php\?p=Your_Account&op=chgtheme'",
"'(?<!/)sec.php\?p=Your_Account&op=editcomm'",
"'(?<!/)sec.php\?p=Your_Account&op=edithome'",
"'(?<!/)sec.php\?p=Your_Account&op=edituser'",
"'(?<!/)sec.php\?p=Your_Account'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlinkcomments&lid=([0-9]+)&ttitle=([/:\-\'(){}.+&=_a-zA-Z0-9 ]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlinkdetails&lid=([0-9]+)&ttitle=([/:\-\'(){}.&=_a-zA-Z0-9 ]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlinkeditorial&lid=([0-9]+)&ttitle=([/:\-\'(){}.&=_a-zA-Z0-9 ]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=modifylinkrequest&lid=([0-9]+)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=brokenlink&lid=([0-9]+)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=outsidelinksetup&lid=([0-9]+)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=(MostPopular|TopRated)&ratenum=([0-9]+)&ratetype=(num|percent)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=NewLinks&newlinkshowdays=([0-9]+)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=NewLinksDate&selectdate=([0-9]+)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=(AddLink|MostPopular|NewLinks|RandomLink|TopRated)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=ratelink&lid=([0-9]*)&ttitle=([/:\-\'(){}.&=_a-zA-Z0-9 ]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=visit&lid=([0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlink&cid=([0-9]*)&orderby=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlink&cid=([0-9]*)&min=([0-9]*)&orderby=([a-zA-Z0-9]*)&show=([0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=viewlink&cid=([0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=search&query=([a-zA-Z0-9]*)&min=([0-9]*)&orderby=([a-zA-Z]*)&show=([0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=search&query=([a-zA-Z0-9]*)&orderby=([a-zA-Z]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=search&query=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links&l_op=search&query=([a-zA-Z0-9]*)'",
"'(?<!/)sec.php\?p=Web_Links'"
);

$urlout = array(
"index.html",
"article-\\1-\\2-\\3-\\4.html",
"article\\1.html",
"article\\1.html",
"article-topic-\\1.html",
"archive-\\1-\\2-\\3.html",
"archive.html",
"downloadview-\\1-\\2-\\3.html",
"download-mod-\\1.html",
"download-broken-\\1.html",
"download-shownew-\\1.html",
"download-seldate-\\1.html",
"download-file-\\1.html",
"ratedownload-\\1-\\2.html",
"ratedownload-\\1.html",
"ratedownload-\\1.html",
"download-\\1-\\2-\\3.html",
"downloads-\\1.html",
"download\\1-orderby\\2.html",
"download\\1-\\2-\\3-\\4.html",
"download-search-\\1-\\2-\\3-\\4.html",
"download-search-\\1-\\2.html",
"download-search-\\1.html",
"download-outside-\\1.html",
"downloads-cat\\1.html",
"downloads-cat\\1.html",
"downloads.html",
"journal-search-\\1.html",
"journal\\1-\\2\\3-\\4\\5.html",
"journal-\\1-\\2-\\3.html",
"journal\\1-\\2.html",
"journal.html",
"reviews-new.html",
"reviews-preview.html",
"reviews-\\1-page\\2.html",
"reviews-\\1.html",
"reviews-\\1.html",
"reviews-comment-\\1-\\2.html",
"reviews-\\1-delete.html",
"reviews-\\1-edit.html",
"reviews-\\1-delcomment-\\2.html",
"reviews-\\1-orderby-\\2-\\3.html",
"reviews-sortby-\\1.html",
"reviews.html",
"submit.html",
"pesquisar.html",
"topics.html",
"top-\\1.html",
"top.html",
"portifolioshow-\\1.html",
"portifolio.html",
"resultado-\\1-\\2-\\3-\\4.html",
"enquetescoment.html",
"enquetes-\\1.html",
"enquetes\\1.html",
"enquetes.html",
"envie-\\1.html",
"recomende.html",
"dominios.html",
"sites.html",
"linux.html",
"redes.html",
"manutencao.html",
"hospassc.html",
"hospass.html",
"hospedagem.html",
"hospesquisadominio.html",
"hoscontato.html",
"hosfaq.html",
"hospassine.html",
"hospcondicoes.html",
"hosprecos.html",
"hosplanos.html",
"hospedagem.html",
"webmail.html",
"empresa.html",
"tutoriais-\\1-\\2.html",
"tutoriais.html",
"saibamais.html",
"csalva.html",
"construtor.html",
"falenviado.html",
"send.html",
"faleconosco.html",
"noticias-\\1-page\\2.html",
"noticias-cat-\\1.html",
"noticias-\\1.html",
"content-\\1.html",
"noticias.html",
"aviso.html",
"processa.html",
"boletim.html",
"pagcat-\\1-\\2.html",
"pagina-\\1-\\2.html",
"vitrine-\\1.html",
"produto-\\1-\\2.html",
"album-\\1.html",
"produtos.html",
"forumx\\1-\\2-\\3.html",
"forum\\1-\\2\\3.html",
"forum\\1.html",
"postx\\1-\\2-\\3.html",
"postxf\\1-\\2-\\3.html",
"posts\\1-\\2\\3.html",
"topic\\1-\\2.html",
"post\\1\\2.html",
"register-coppa-\\1.html",
"register-\\1.html",
"poster\\1-\\2_\\3.html",
"modcp\\1-\\2.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2-\\3-\\4.html",
"forums-\\1-\\2.html",
"forum\\1-\\2-\\3-\\4.html",
"forums\\1-\\2-\\3.html",
"forums.html",
"forum-\\1.html",
"forums.html",
"sections-viewarticle\\1-page\\2.html",
"sections-\\1-\\2.html",
"sections-listarticles-\\1.html",
"sections.html",
"stats-\\1-\\2-\\3.html",
"stats-\\1-\\2.html",
"stats-\\1.html",
"advstats.html",
"stats.html",
"aconta-\\1.html",
"usercookieconfig.html",
"userconfig.html",
"useraguardando.html",
"userad.html",
"userativo-\\1.html",
"userinfo-\\1.html",
"deletusuar-\\1-\\2.html",
"suspendusuar-\\1-\\2.html",
"editausuar-\\1-\\2.html",
"avatarescolha-\\1-\\2.\\3",
"avatarlist.html",
"apagacookie2.html",
"apagacookie.html",
"passperdido.html",
"registrar.html",
"sair.html",
"mudatema.html",
"usereditcoment.html",
"useredithome.html",
"useredit.html",
"suaconta.html",
"viewlinkcomments-\\1-\\2.html",
"viewlinkdetails-\\1-\\2.html",
"vieweditorial-\\1-\\2.html",
"modifylink-\\1.html",
"brokenlink-\\1.html",
"outsidelink-\\1.html",
"linkop-\\1-\\2-\\3.html",
"newlinks-\\1.html",
"linksnew-\\1.html",
"linkop-\\1.html",
"ratelink-\\1-\\2.html",
"viewlink-\\1.html",
"links-\\1-\\2.html",
"links-\\1-\\2-\\3-\\4.html",
"link-\\1.html",
"links-search-\\1-\\2-orderby-\\3-\\4.html",
"links-search-\\1-orderby-\\2.html",
"links-search-\\1.html",
"links-search-\\1.html",
"links.html"
);

$s = preg_replace($urlin, $urlout, $s);
return $s;
}

 

rodape.php

$contents = ob_get_contents(); // store buffer in $contents
ob_end_clean(); // delete output buffer and stop buffering
echo replace_for_mod_rewrite($contents); //display modified buffer to screen

Compartilhar este post


Link para o post
Compartilhar em outros sites

×

Informação importante

Ao usar o fórum, você concorda com nossos Termos e condições.