<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2russianfull.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" version="2.0">

<channel>
	<title>Denis.in.ua</title>
	
	<link>http://denis.in.ua</link>
	<description>Блог имени Меня</description>
	<pubDate>Wed, 24 Dec 2008 11:47:04 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/Denisinua" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="denisinua" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://add.my.yahoo.com/rss?url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif">Subscribe with My Yahoo!</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://www.newsgator.com/images/ngsub1.gif">Subscribe with NewsGator</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://feeds.my.aol.com/add.jsp?url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://o.aolcdn.com/favorites.my.aol.com/webmaster/ffclient/webroot/locale/en-US/images/myAOLButtonSmall.gif">Subscribe with My AOL</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://www.bloglines.com/sub/http://feeds.feedburner.com/Denisinua" src="http://www.bloglines.com/images/sub_modern11.gif">Subscribe with Bloglines</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://www.netvibes.com/subscribe.php?url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://www.netvibes.com/img/add2netvibes.gif">Subscribe with Netvibes</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://fusion.google.com/add?feedurl=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://buttons.googlesyndication.com/fusion/add.gif">Subscribe with Google</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://www.pageflakes.com/subscribe.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://www.pageflakes.com/ImageFile.ashx?instanceId=Static_4&amp;fileName=ATP_blu_91x17.gif">Subscribe with Pageflakes</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://lenta.yandex.ru/settings.xml?name=feed&amp;url=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua" src="http://lenta.yandex.ru/i/addfeed.gif">?????? ? ??????.?????</feedburner:feedFlare><feedburner:feedFlare xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" href="http://www.addtoany.com/?linkname=Denis.in.ua&amp;linkurl=http%3A%2F%2Ffeeds.feedburner.com%2FDenisinua&amp;type=feed" src="http://www.addtoany.com/addfr-b.gif">Add to Any Feed Reader</feedburner:feedFlare><item>
		<title>… В условиях кризиса</title>
		<link>http://denis.in.ua/in-crisis.htm</link>
		<comments>http://denis.in.ua/in-crisis.htm#comments</comments>
		<pubDate>Wed, 24 Dec 2008 11:45:28 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<guid isPermaLink="false">http://denis.in.ua/in-crisis.htm</guid>
		<description><![CDATA[Замечали в последнее время тенденцию брать какую-либо статью по маркетингу, экономике или чему-угодно и в конце заголовка обязательно добавлять: &#8220;в условиях кризиса&#8221;?
При этом в самой статье нет ничего особенного, что было бы полезно только в период кризиса. Например, совет: &#8220;в период кризиса минимизируйте расходы&#8221;. Или &#8220;проведите сео оптимизацию&#8221;.
Дальше ожидаем статей:


CSS верстка в условиях кризиса.
Переходим с [...]]]></description>
			<content:encoded><![CDATA[<p>Замечали в последнее время тенденцию брать какую-либо статью по маркетингу, экономике или чему-угодно и в конце заголовка обязательно добавлять: &#8220;в условиях кризиса&#8221;?<br />
При этом в самой статье нет ничего особенного, что было бы полезно только в период кризиса. Например, совет: &#8220;в период кризиса минимизируйте расходы&#8221;. Или &#8220;проведите сео оптимизацию&#8221;.</p>
<p>Дальше ожидаем статей:<br />
<span id="more-56"></span></p>
<ul>
<li><strong>CSS верстка в условиях кризиса.</strong></li>
<li><strong>Переходим с php4 на php5 в связи с кризисом</strong></li>
<li><strong>Антикризисные колготки</strong></li>
<li><strong>Как составить резюме в условиях кризиса</strong></li>
<li><strong>Ruby On Rails сливается с Merb в связи с финансовым кризисом</strong></li>
<li><strong>Unit-тесты как средство борьбы с глобальным кризисом</strong></li>
</ul>
<p>Ваши варианты?</p>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/in-crisis.htm">Permalink</a> |
	  <a href="http://denis.in.ua/in-crisis.htm#comments">10 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/in-crisis.htm&amp;title=&#8230; В условиях кризиса">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/in-crisis.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=UtM2V6HQ"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/jJgfWX9GvTc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/in-crisis.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>WEB 3.0 - это …</title>
		<link>http://denis.in.ua/web30-is-a.htm</link>
		<comments>http://denis.in.ua/web30-is-a.htm#comments</comments>
		<pubDate>Mon, 27 Oct 2008 19:27:30 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<category><![CDATA[Темный юмор]]></category>

		<guid isPermaLink="false">http://denis.in.ua/web30-is-a.htm</guid>
		<description><![CDATA[&#8230;Когда adsense встроен в зрачок и контекстная реклама появляется при просмотре окружающих предметов &#169;
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  2 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Ни о чем,  Темный юмор.]]></description>
			<content:encoded><![CDATA[<blockquote><p>&#8230;Когда adsense встроен в зрачок и контекстная реклама появляется при просмотре окружающих предметов &copy;</p></blockquote>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/web30-is-a.htm">Permalink</a> |
	  <a href="http://denis.in.ua/web30-is-a.htm#comments">2 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/web30-is-a.htm&amp;title=WEB 3.0 - это &#8230;">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/web30-is-a.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>,  <a href="http://denis.in.ua/category/dark-humor" title="Просмотреть все записи в рубрике &laquo;Темный юмор&raquo;" rel="category tag">Темный юмор</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=Rao3KBLG"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/PPiWN8enMAE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/web30-is-a.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>301 redirect с помощью nginx или мелкое seo</title>
		<link>http://denis.in.ua/301-redirect-with-nginx.htm</link>
		<comments>http://denis.in.ua/301-redirect-with-nginx.htm#comments</comments>
		<pubDate>Mon, 20 Oct 2008 22:14:31 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://denis.in.ua/301-redirect-with-nginx.htm</guid>
		<description><![CDATA[Никогда целенаправленно не занимался оптимизацией под поисковики, но вот недавно попался под руку один из миллиона сервисов предлагающих проанализировать сайт на предмет его дружелюбности к поисковикам. Без раздумий вбил один из своих проектов и первое что бросилось в глаза - заметка о том что сайт доступен по двум адресам: www.mysite.com и mysite.com, гугл и другие [...]]]></description>
			<content:encoded><![CDATA[<p><img src='http://denis.in.ua/wp-content/uploads/2008/10/1045473_coloured_web_adress_1.jpg' alt='301 redirect' class="fine-pic" />Никогда целенаправленно не занимался оптимизацией под поисковики, но вот недавно попался под руку один из миллиона сервисов предлагающих проанализировать сайт на предмет его дружелюбности к поисковикам. Без раздумий вбил один из своих проектов и первое что бросилось в глаза - заметка о том что сайт доступен по двум адресам: www.mysite.com и mysite.com, гугл и другие поисковики воспринимают эти адреса как два разных сайта. Казалось бы ничего страшного, но ведь при этом половинятся входящие ссылки, уникальность контента ставится под сомнение (какая уж тут уникальность, если один и тот же контент аж на двух сайтах), и есть, наверное, еще много негатива в таком вот дублировании.</p>
<p>Выход в данном случае достаточно простой, прописать редирект со статус-кодом 301 (permanently moved) с домена www.mydomain.com на mydomain.com.<br />
Для Апача rewrite правило очевидно, а вот nginx, который я использую у себя на хостинге, для меня пока более загадочен. Но все же решение было найдено и для него.<br />
<span id="more-53"></span><br />
В конфиге nginx это выглядит это приблизительно так:</p>
<div class="codecolorer-container apache " style="overflow:auto;white-space:nowrap;width:435px"><table cellspacing="0" cellpadding="0"><tbody><tr><td class="line-numbers"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br /></div></td><td><div class="apache codecolorer" style="font-family:Monaco,Lucida Console,monospace">server {<br />
&nbsp; &nbsp; <span class="co1">#общая конфигурация для сервера</span><br />
&nbsp; &nbsp; <span class="kw1">listen</span> mysite.com:<span class="nu0">80</span>;<br />
&nbsp; &nbsp; server_name mysite.com *.mysite.com;<br />
...<br />
&nbsp; &nbsp; <span class="co1">#редиректим http://www.mydomain.nl/foo =&gt; http://mydomain.nl/foo</span><br />
&nbsp; &nbsp; if ($host ~* www\.(.*)) {<br />
&nbsp; &nbsp; &nbsp; &nbsp;set $host_without_www $<span class="nu0">1</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp;rewrite ^(.*)$ http://$host_without_www$<span class="nu0">1</span> permanent;<br />
&nbsp; &nbsp; }<br />
}</div></td></tr></tbody></table></div>
<p>собственно <strong>permanent</strong> и означает 301 статус-код.</p>
<p>Решение найдено: <a href="http://wiki.codemongers.com/NginxHttpRewriteModule">здесь</a></p>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/301-redirect-with-nginx.htm">Permalink</a> |
	  <a href="http://denis.in.ua/301-redirect-with-nginx.htm#comments">3 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/301-redirect-with-nginx.htm&amp;title=301 redirect с помощью nginx или мелкое seo">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/301-redirect-with-nginx.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/php" title="Просмотреть все записи в рубрике &laquo;PHP&raquo;" rel="category tag">PHP</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=6p3E8eZO"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/V0B7GD_F2Ds" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/301-redirect-with-nginx.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Повышение производительности труда</title>
		<link>http://denis.in.ua/productivity-of-labour.htm</link>
		<comments>http://denis.in.ua/productivity-of-labour.htm#comments</comments>
		<pubDate>Mon, 07 Jul 2008 14:55:26 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<guid isPermaLink="false">http://denis.in.ua/productivity-of-labour.htm</guid>
		<description><![CDATA[Чтобы повысить производительность труда - нужно прекратить читать статьи о методах повышения производительности труда! &#169;
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  7 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Ни о чем.]]></description>
			<content:encoded><![CDATA[<blockquote><p>Чтобы повысить производительность труда - нужно прекратить читать статьи о методах повышения производительности труда! &copy;</p></blockquote>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/productivity-of-labour.htm">Permalink</a> |
	  <a href="http://denis.in.ua/productivity-of-labour.htm#comments">7 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/productivity-of-labour.htm&amp;title=Повышение производительности труда">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/productivity-of-labour.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=ZDBB9NKp"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/o7nqevP78HM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/productivity-of-labour.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Мысли о наболевшем</title>
		<link>http://denis.in.ua/thoughts-about-painful.htm</link>
		<comments>http://denis.in.ua/thoughts-about-painful.htm#comments</comments>
		<pubDate>Thu, 03 Jul 2008 21:28:31 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<guid isPermaLink="false">http://denis.in.ua/thoughts-about-painful.htm</guid>
		<description><![CDATA[Иногда зарплата вырастает до такой степени, что выдают ее только по частям. &#169;
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  7 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Ни о чем.]]></description>
			<content:encoded><![CDATA[<blockquote><p>Иногда зарплата вырастает до такой степени, что выдают ее только по частям. &copy;</p></blockquote>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/thoughts-about-painful.htm">Permalink</a> |
	  <a href="http://denis.in.ua/thoughts-about-painful.htm#comments">7 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/thoughts-about-painful.htm&amp;title=Мысли о наболевшем">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/thoughts-about-painful.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=FOAHbEAC"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/gJJaMk_vpWE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/thoughts-about-painful.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Tip:  Extjs + Rails</title>
		<link>http://denis.in.ua/tip-extjsrails.htm</link>
		<comments>http://denis.in.ua/tip-extjsrails.htm#comments</comments>
		<pubDate>Thu, 26 Jun 2008 22:24:19 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Javascript]]></category>

		<category><![CDATA[Rails]]></category>

		<guid isPermaLink="false">http://denis.in.ua/tip-extjsrails.htm</guid>
		<description><![CDATA[Для тех кто только использует связку Extjs и Rails.
В рельсах есть такой полезный метод: respond_to, который позволяет отдавать данный в нужном формате будь-то html, xml, json.
Например:
1234567respond_to do &#124;format&#124;
&#160; &#160; &#160; format.json &#123;
&#160; &#160; &#160; &#160; data = &#123;:success=&#62;true&#125;
&#160; &#160; &#160; &#160; render :json=&#62;data.to_json
&#160; &#160; &#160; &#125;
&#160; &#160; &#160; format.html &#123; redirect_to&#40;:controller =&#62; 'blablabla', :action =&#62; [...]]]></description>
			<content:encoded><![CDATA[<p>Для тех кто только использует связку Extjs и Rails.<br />
В рельсах есть такой полезный метод: respond_to, который позволяет отдавать данный в нужном формате будь-то html, xml, json.<br />
Например:</p>
<div class="codecolorer-container ruby " style="overflow:auto;white-space:nowrap;width:435px"><table cellspacing="0" cellpadding="0"><tbody><tr><td class="line-numbers"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="ruby codecolorer" style="font-family:Monaco,Lucida Console,monospace">respond_to <span class="kw1">do</span> <span class="sy0">|</span>format<span class="sy0">|</span><br />
&nbsp; &nbsp; &nbsp; <span class="kw3">format</span>.<span class="me1">json</span> <span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; data = <span class="br0">&#123;</span>:success<span class="sy0">=&gt;</span>true<span class="br0">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; render <span class="re3">:json</span><span class="sy0">=&gt;</span>data.<span class="me1">to_json</span><br />
&nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span><br />
&nbsp; &nbsp; &nbsp; <span class="kw3">format</span>.<span class="me1">html</span> <span class="br0">&#123;</span> redirect_to<span class="br0">&#40;</span><span class="re3">:controller</span> <span class="sy0">=&gt;</span> <span class="st0">'blablabla'</span>, <span class="re3">:action</span> <span class="sy0">=&gt;</span> <span class="st0">'index'</span>, <span class="re3">:id</span> <span class="sy0">=&gt;</span> <span class="st0">'all'</span><span class="br0">&#41;</span> <span class="br0">&#125;</span><br />
&nbsp;<span class="kw1">end</span></div></td></tr></tbody></table></div>
<p>В данном случае, если запрос пришел Аяксом - то просто вернуть ответ в формате json: {:success=>true}.<br />
Если же был обычный переход в браузере на данную страницу - то отредиректить на другую страницу.</p>
<p>При это рельсы пытаются определить, в каком формате тебе нужен ответ анализируя заголовки.</p>
<p>И все казалось бы без проблем, но если вы пытаетесь создать аяксовый запрос используя extjs - рельсы выполнят код блока html.<br />
Безобразие!</p>
<p>Чтобы вразумить их, придется использовать дополнительный параметр в аяксовом запросе:</p>
<p>headers: { &#8216;Accept&#8217; : &#8216;application/json&#8217; },</p>
<p>Например так:</p>
<div class="codecolorer-container javascript " style="overflow:auto;white-space:nowrap;width:435px"><table cellspacing="0" cellpadding="0"><tbody><tr><td class="line-numbers"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br /></div></td><td><div class="javascript codecolorer" style="font-family:Monaco,Lucida Console,monospace">Ext.<span class="me1">Ajax</span>.<span class="me1">request</span><span class="br0">&#40;</span><span class="br0">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; url <span class="sy0">:</span> my_url<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; method<span class="sy0">:</span> <span class="st0">'POST'</span><span class="sy0">,</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; headers<span class="sy0">:</span> <span class="br0">&#123;</span> <span class="st0">'Accept'</span> <span class="sy0">:</span> <span class="st0">'application/json'</span> <span class="br0">&#125;</span><span class="sy0">,</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; callback<span class="sy0">:</span> <span class="kw2">function</span> <span class="br0">&#40;</span> options<span class="sy0">,</span> success<span class="sy0">,</span> response <span class="br0">&#41;</span> <span class="br0">&#123;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="kw3">alert</span><span class="br0">&#40;</span><span class="st0">'ok!'</span><span class="br0">&#41;</span><span class="sy0">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span class="br0">&#125;</span><span class="br0">&#41;</span><span class="sy0">;</span></div></td></tr></tbody></table></div>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/tip-extjsrails.htm">Permalink</a> |
	  <a href="http://denis.in.ua/tip-extjsrails.htm#comments">4 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/tip-extjsrails.htm&amp;title=Tip:  Extjs + Rails">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/tip-extjsrails.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/javascript" title="Просмотреть все записи в рубрике &laquo;Javascript&raquo;" rel="category tag">Javascript</a>,  <a href="http://denis.in.ua/category/rails" title="Просмотреть все записи в рубрике &laquo;Rails&raquo;" rel="category tag">Rails</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=kL28YRrs"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/jZHIrFPqXz0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/tip-extjsrails.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Современная жизнь</title>
		<link>http://denis.in.ua/modern-life.htm</link>
		<comments>http://denis.in.ua/modern-life.htm#comments</comments>
		<pubDate>Thu, 19 Jun 2008 16:14:10 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<guid isPermaLink="false">http://denis.in.ua/modern-life.htm</guid>
		<description><![CDATA[Переписываться с человеком по аське, когда слышно как он набирает тебе сообщения&#8230;
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  7 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Ни о чем.]]></description>
			<content:encoded><![CDATA[<blockquote><p>Переписываться с человеком по аське, когда слышно как он набирает тебе сообщения&#8230;</p></blockquote>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/modern-life.htm">Permalink</a> |
	  <a href="http://denis.in.ua/modern-life.htm#comments">7 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/modern-life.htm&amp;title=Современная жизнь">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/modern-life.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=flVjE4sI"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/L2vissJ3Zjs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/modern-life.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Рекомендую к прочтению</title>
		<link>http://denis.in.ua/recommend-to-read.htm</link>
		<comments>http://denis.in.ua/recommend-to-read.htm#comments</comments>
		<pubDate>Thu, 19 Jun 2008 12:44:52 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Соль]]></category>

		<guid isPermaLink="false">http://denis.in.ua/recommend-to-read.htm</guid>
		<description><![CDATA[Бывает сидишь себе на работе, а почитать нечего.
Рекомендую две книжки и два блога:


Отличная книга: &#8220;Не мешайте мне работать!&#8221;
Рекомендую всем работникам и работодателям ИТ сферы. Читается очень легко. В открытом доступе - можно написать автору и он вышлет беслпатныую версию. По желанию можно оплатить.
Блог Михаила Елфимова
Околоайтишный блог. Рекомендую просмотреть архивы. Зависал на нем полдня.
Блог Сергея Большедворского
Достаточно [...]]]></description>
			<content:encoded><![CDATA[<p>Бывает сидишь себе на работе, а почитать нечего.<br />
Рекомендую две книжки и два блога:<br />
<span id="more-47"></span></p>
<ul>
<li>Отличная книга: <a target="blank" href="http://motivateme.ru/book/">&#8220;Не мешайте мне работать!&#8221;</a></li>
<p>Рекомендую всем работникам и работодателям ИТ сферы. Читается очень легко. В открытом доступе - можно написать автору и он вышлет беслпатныую версию. По желанию можно оплатить.</p>
<li><a target="_blank" href="http://elfimov.com/everything/">Блог Михаила Елфимова</a></li>
<p>Околоайтишный блог. Рекомендую просмотреть архивы. Зависал на нем полдня.</p>
<li><a target="_blank" href="http://www.bolshedvorsky.com/">Блог Сергея Большедворского</a></li>
<p>Достаточно редко встречал блоги настолько соответствующие моим вкусам. Отличный подбор музыки, отличные посты, отличные фильмы. Нет слов. Блог просто супер. Кстати, автор блога к тому же пишет книги. <a target="_blank" href="http://www.bolshedvorsky.com/2008/06/the-little-blue-book-of-software-marketing">Одну из них</a> выложил в открытый доступ.</p>
</ul>
<p>Приятного чтения.</p>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/recommend-to-read.htm">Permalink</a> |
	  <a href="http://denis.in.ua/recommend-to-read.htm#comments">5 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/recommend-to-read.htm&amp;title=Рекомендую к прочтению">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/recommend-to-read.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/salt" title="Просмотреть все записи в рубрике &laquo;Соль&raquo;" rel="category tag">Соль</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=jP9zsOpU"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/vQwTSWMW-c8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/recommend-to-read.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>Мысли вслух</title>
		<link>http://denis.in.ua/thoughts-aloud.htm</link>
		<comments>http://denis.in.ua/thoughts-aloud.htm#comments</comments>
		<pubDate>Tue, 17 Jun 2008 15:54:35 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Ни о чем]]></category>

		<guid isPermaLink="false">http://denis.in.ua/%d0%bc%d1%8b%d1%81%d0%bb%d0%b8-%d0%b2%d1%81%d0%bb%d1%83%d1%85.htm</guid>
		<description><![CDATA[Чтобы заставить программиста сделать что-то хорошо, надо заставить его пользоваться этим &#8220;что-то&#8221;(C)
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  4 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Ни о чем.]]></description>
			<content:encoded><![CDATA[<blockquote><p>Чтобы заставить программиста сделать что-то хорошо, надо заставить его пользоваться этим &#8220;что-то&#8221;(C)</p></blockquote>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/thoughts-aloud.htm">Permalink</a> |
	  <a href="http://denis.in.ua/thoughts-aloud.htm#comments">4 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/thoughts-aloud.htm&amp;title=Мысли вслух">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/thoughts-aloud.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/ni-o-chem" title="Просмотреть все записи в рубрике &laquo;Ни о чем&raquo;" rel="category tag">Ни о чем</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=6T5P8dEU"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/r_NTwh53htQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/thoughts-aloud.htm/feed</wfw:commentRss>
		</item>
		<item>
		<title>В этом году решил поучаствовать в CSS Naked Day</title>
		<link>http://denis.in.ua/css-naked-day-2008.htm</link>
		<comments>http://denis.in.ua/css-naked-day-2008.htm#comments</comments>
		<pubDate>Tue, 08 Apr 2008 08:12:48 +0000</pubDate>
		<dc:creator>Денис Солошенко</dc:creator>
		
		<category><![CDATA[Без рубрики]]></category>

		<guid isPermaLink="false">http://denis.in.ua/css-naked-day-2008.htm</guid>
		<description><![CDATA[Смысл сего действа в том, чтобы продвинуть веб-стандарты.
Метод продвижения: убрать на один день (9 апреля) CSS со своего сайта.

Подробнее смотри тут
	
	
	&#169; Денис Солошенко for Denis.in.ua, 2008. &#124;
	  Permalink &#124;
	  7 comments
	Add to del.icio.us
	Search blogs linking this post with Technorati
	Want more on these topics ? Browse the archive of posts filed under Без рубрики.]]></description>
			<content:encoded><![CDATA[<p>Смысл сего действа в том, чтобы продвинуть веб-стандарты.<br />
Метод продвижения: убрать на один день (9 апреля) CSS со своего сайта.</p>
<p><span id="more-45"></span><br />
Подробнее смотри <a href="http://naked.dustindiaz.com/" target="_blank">тут</a></p>
	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>&copy; Денис Солошенко for <a href="http://denis.in.ua">Denis.in.ua</a>, 2008. |
	  <a href="http://denis.in.ua/css-naked-day-2008.htm">Permalink</a> |
	  <a href="http://denis.in.ua/css-naked-day-2008.htm#comments">7 comments</a></p>
	<p>Add to <a href="http://del.icio.us/post?url=http://denis.in.ua/css-naked-day-2008.htm&amp;title=В этом году решил поучаствовать в CSS Naked Day">del.icio.us</a></p>
	<p>Search blogs linking this post with <a href="http://www.technorati.com/search/http://denis.in.ua/css-naked-day-2008.htm" title="Search on Technorati">Technorati</a></p>
	<p>Want more on these topics ? Browse the archive of posts filed under <a href="http://denis.in.ua/category/bez-rubriki" title="Просмотреть все записи в рубрике &laquo;Без рубрики&raquo;" rel="category tag">Без рубрики</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~f/Denisinua?a=vJzl8CpI"><img src="http://feeds.feedburner.com/~f/Denisinua?d=50" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/Denisinua/~4/uZPqQysJAZQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://denis.in.ua/css-naked-day-2008.htm/feed</wfw:commentRss>
		</item>
	</channel>
</rss><!-- Dynamic Page Served (once) in 0.542 seconds -->
