<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>apache 301 yönlendirme - Margarit</title>
	<atom:link href="https://www.margarit.com.tr/tag/apache-301-yonlendirme/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.margarit.com.tr</link>
	<description>Web Reklam ve Bilişim Hizmetleri</description>
	<lastBuildDate>Wed, 25 Nov 2020 19:21:28 +0000</lastBuildDate>
	<language>tr</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.5</generator>

<image>
	<url>https://www.margarit.com.tr/wp-content/uploads/2020/09/Favicon-v2-6309143-100x100.png</url>
	<title>apache 301 yönlendirme - Margarit</title>
	<link>https://www.margarit.com.tr</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Htaccess kullanımı ve 301 Yönlendirme Kuralları (Php, WordPress)</title>
		<link>https://www.margarit.com.tr/htaccess-kullanimi-ve-301-yonlendirme-kurallari-php-wordpress/</link>
					<comments>https://www.margarit.com.tr/htaccess-kullanimi-ve-301-yonlendirme-kurallari-php-wordpress/#respond</comments>
		
		<dc:creator><![CDATA[Margarit Bilişim]]></dc:creator>
		<pubDate>Sun, 20 Sep 2020 11:59:34 +0000</pubDate>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[301 yönlendirme]]></category>
		<category><![CDATA[apache 301 yönlendirme]]></category>
		<category><![CDATA[apache htaccess kuralları]]></category>
		<category><![CDATA[htaccess kuralları]]></category>
		<category><![CDATA[htaccess yönlendirme]]></category>
		<category><![CDATA[taşıma işlemi]]></category>
		<category><![CDATA[wordpress 301 yönlendirme]]></category>
		<category><![CDATA[wordpress 302 yönlendirme]]></category>
		<category><![CDATA[wordpress htaccess]]></category>
		<category><![CDATA[wordpress rewrite kuralları]]></category>
		<guid isPermaLink="false">https://www.margarit.com.tr/?p=4559</guid>

					<description><![CDATA[<p>Htaccess ve 301 Yönlendirme kuralları ile tüm işlemlerinizi kusursuzca yapabilirsiniz.</p>
<p>The post <a href="https://www.margarit.com.tr/htaccess-kullanimi-ve-301-yonlendirme-kurallari-php-wordpress/">Htaccess kullanımı ve 301 Yönlendirme Kuralları (Php, WordPress)</a> first appeared on <a href="https://www.margarit.com.tr">Margarit</a>.</p>]]></description>
										<content:encoded><![CDATA[<p class="wp-block-paragraph">Bir web siteniz var ve memnun olduğunuz halde farklı bir dizine, alt dizine, alt domaine veya farklı bir URL adresine taşımak mı istiyorsunuz?</p>



<p class="wp-block-paragraph">Aynı zamanda taşıma işlemi ve sonrasında sitenize gelen hitlerin kaybolmaması, URL adreslerinin 404 hatasına dönüşmeden yeni taşındığınız adrese sorunsuzca yönlendirilmesini mi istiyorsunuz? Kalıcı bir işlem olarak bu yönlendirme hareketine 301 Yeniden Yönlendirme aktivitesiyle kolayca uygulayabilirsiniz.</p>



<h3 class="wp-block-heading">Htaccess dosyası nedir? Htaccess ne işe yarar?</h3>



<p class="wp-block-paragraph">Server ve hosting kurulumları sonrasında WordPress, Joompla ve Drupal gibi CMS sistemleri ile çalışıyorsanız, mutlaka bu dosyanın varlığına ve elzem işlevselliğine tanık olmuş olmalısınız.</p>



<p class="wp-block-paragraph">Htaccess dosyası veya diğer ismiyle HyperText Access dosyası, yapı içerisindeki dizin kontrollerinin yapıldığı, elzem bir sunucu yönlendirme işlevi üstlenmektedir. Apache server kurulumları sonrasında sunucunuzun dosya düzenini işlevsel hale getirmek için htaccess düzenlemenizin, istediğiniz yapıda olması zorunludur.</p>



<p class="wp-block-paragraph">301 Redirection olarak web üerinde milyon tane alternatif yazıya denk gelebileceğiniz kalıcı yönlendirme işlevi olan 301 Yeniden Yönlendirme işlemi, htaccess dosyasına ekleyeceğınız basit ancak hayati kodlamalar ile gerçekleşmektedir.</p>



<h3 class="wp-block-heading">Sık Kullanılan Htaccess 301 Yönlendirme Kuralları Nelerdir?</h3>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile Tek bir sayfa yönlendirmek isterseniz</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Redirect 301 /pagename.php http://www.domain.com/pagename.html</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile bir domain veya ana adresi tamamiyle yenisine yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Redirect 301 / http://www.domain.com/</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile alt dizindeki bir siteyi başka ana adrese yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Redirect 301 /subfolder http://www.domain.com/</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile dosya ismi değişmeden aynı adresi farklı dosya formatına yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RedirectMatch 301 (.*).html$ http://www.domain.com$1.php</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile yeniden yazma yöntemiyle eski adresi yenisine yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteBase /
RewriteRule (.*) http://www.newdomain.com/$1 [R=301,L]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile www olmayan siteyi www versiyonuna yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteBase /
rewritecond %{http_host} ^domain.com [nc]
rewriterule ^(.*)$ http://www.domain.com/$1 [r=301,nc]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile www olmayan bir siteyi ww ve alt dizinli yeni adrese yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteBase /
RewriteCond %{HTTP_HOST} domain.com [NC]
RewriteRule ^(.*)$ http://www.domain.com/directory/index.html [R=301,NC]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 302 Yönlendirme ile bir domain veya ana adresi tamamiyle ve aynı link yapısını bozmadan yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Options +FollowSymLinks
RewriteEngine On
RewriteRule ^(.*) http://www.newdomain.com%{REQUEST_URI} [R=302,NC]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 302 Yönlendirme ile bir alt dizinde bulunan siteyi tamamiyle ve aynı link yapısını bozmadan bir alt dizinsiz yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/subdirname/(.*)$
RewriteRule ^(.*) http://www.newdomain.com/%1 [R=302,NC]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile bir dizinde bulunan siteyi query uzantılarıyla birlikte yeni bir dizine taşıma</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteCond %{QUERY_STRING} id=3
RewriteRule ^index.php$ /path-to-new-location/? [L,R=301]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile HTTP siteyi duplikasyon olmadan HTTPS versiyonuna çevirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteCond %{HTTPS} on
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI}</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile HTTPS yönlendirmesini yaparken HTTP&#8217;den de kurtarmak isterseniz</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine On
RewriteCond %{HTTPS} on
RewriteRule (.*) http://%{HTTP_HOST}%{REQUEST_URI}</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile index.php veya index.html yapılarından kurtarıp ana adrese yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine On
RewriteCond %{THE_REQUEST} /index.php HTTP [NC]
RewriteRule (.*)index.php$ /$1 [R=301,L]

veya 

RewriteEngine On
RewriteCond %{THE_REQUEST} /index.html HTTP [NC]
RewriteRule (.*)index.html$ /$1 [R=301,L]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile index sorgusundan kurtarıp direk adres olarak yönlendirmek</p>



<p class="wp-block-paragraph">Örnek: https://www.margarit.com.tr/index.php?id=100 adresinden https://www.margarit.com.tr/100/ adresine direk yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine On
RewriteRule ^([^/d]+)/?$ index.php?id=$1 [QSA]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile index sorgusundan kurtarıp alt dizin tanımlamasıyla direk adres olarak yönlendirmek</p>



<p class="wp-block-paragraph">Örnek: https://www.margarit.com.tr/index.php?kategori=kediler adresinden https://www.margarit.com.tr/kategori/kediler adresine direk yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine On
RewriteRule ^/?kategory/([^/d]+)/?$ index.php?kategory=$1 [L,QSA]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile URL yapısını bozmadan bir siteyi tamamen yenisine birebir taşımak</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>RewriteEngine on
RewriteCond %{HTTP_HOST} ^example-old.com$ [NC]
RewriteRule ^(.*)$ http://www.example-new.com/$1 [R=301,L]

If you do not want to pass the path to the new domain, change the last line to:
RewriteRule ^(.*)$ http://www.example-new.com/ [R=301,L]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme ile sub domain adresinden alt dizine yönlendirme</p>



<p class="wp-block-paragraph">Örnek: blog.margarit.com.tr adresinden https://www.margarit.com.tr/blog/ adresine direk yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_URI}/ blog
RewriteRule ^(.*) http://www.orneksiteadi.com/%{REQUEST_URI} [R=302,NC]
RewriteRule ^(.*) http://www.orneksiteadi.com/blog/%{REQUEST_URI} [R=302,NC]</code></pre></div>



<p class="wp-block-paragraph">Htaccess ve 301 Yönlendirme kuralları ile bir alt dizini başka bir alt dizine yönlendirme</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>Options +FollowSymLinks RewriteEngine On RewriteRule ^(.*)/old-directory/(.*)$ $1/new-directory/$2 [R,L]</code></pre></div>



<p class="wp-block-paragraph">Bir domainde yer alan sistemi tamamen bir alt dizine taşımak istiyorsunuz ve gelen hitlerin direk alt dizindeki url&#8217;ye yönelmesini istiyorsanız</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-php" data-lang="PHP"><code>&lt;IfModule mod_expires.c&gt;
RewriteEngine on
Options +FollowSymLinks
RewriteCond %{HTTP_HOST} ^margarit.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.margarit.com$
RewriteRule ^(.*)$ &quot;https://www.margarit.com/forum/$1&quot; [R=301,L]
&lt;IfModule&gt;</code></pre></div><p>The post <a href="https://www.margarit.com.tr/htaccess-kullanimi-ve-301-yonlendirme-kurallari-php-wordpress/">Htaccess kullanımı ve 301 Yönlendirme Kuralları (Php, WordPress)</a> first appeared on <a href="https://www.margarit.com.tr">Margarit</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.margarit.com.tr/htaccess-kullanimi-ve-301-yonlendirme-kurallari-php-wordpress/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
