<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/atom10full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" xml:lang="en" xml:base="http://flip.netzbeben.de/wp-atom.php">
	<title type="text">flip's</title>
	<subtitle type="text">development, emo music, webdesign and inspiration</subtitle>

	<updated>2008-09-11T04:06:21Z</updated>
	<generator uri="http://wordpress.org/" version="2.6.2">WordPress</generator>

	<link rel="alternate" type="text/html" href="http://flip.netzbeben.de" />
	<id>http://flip.netzbeben.de/feed/atom/</id>
	

			<link rel="self" href="http://feeds.feedburner.com/flips" type="application/atom+xml" /><entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Smilies in Rails using BBCodeizer]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/378487074/" />
		<id>http://flip.netzbeben.de/?p=36</id>
		<updated>2008-09-11T04:06:21Z</updated>
		<published>2008-08-29T23:22:52Z</published>
		<category scheme="http://flip.netzbeben.de" term="Development" /><category scheme="http://flip.netzbeben.de" term="Emo" /><category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="German" /><category scheme="http://flip.netzbeben.de" term="Inspiration" /><category scheme="http://flip.netzbeben.de" term="Music" /><category scheme="http://flip.netzbeben.de" term="Rails 1.2" /><category scheme="http://flip.netzbeben.de" term="Rails 2.0" /><category scheme="http://flip.netzbeben.de" term="Rails 2.1" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[I&#8217;ve already described how to enable support for Smilies in Rails using RedCloth. If you want to use BBCodeizer instead of RedCloth (Textile), here&#8217;s how to do it.  We need to extend the BBCodeizer class. We could do this by creating a file in our /lib directory (e.g. my_string.rb), which has to be included [...]]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/08/smilies-in-rails-using-bbcodeizer/">&lt;p&gt;I&amp;#8217;ve already described how to enable support for &lt;a href="http://flip.netzbeben.de/2008/07/smilies-in-rails-using-redcloth/" target="_self"&gt;Smilies in Rails using RedCloth&lt;/a&gt;. If you want to use BBCodeizer instead of RedCloth (Textile), here&amp;#8217;s how to do it.  We need to extend the BBCodeizer class. We could do this by creating a file in our /lib directory (e.g. my_string.rb), which has to be included in the environment.rb (require &amp;#8220;my_string&amp;#8221;). Here&amp;#8217;s an example for three simple smilies:&lt;/p&gt;
&lt;pre&gt;# my_string.rb
module BBCodeizer
  class &amp;lt;&amp;lt; self
    Tags[:smiley1] = [/\:\-?\)/, '&amp;lt;img title=":)" src="/images/emoticons/smile.png" alt="smile"/&amp;gt;']
    Tags[:smiley2] = [/\;\-?\)/, '&amp;lt;img title=";)" src="/images/emoticons/wink.png" alt="wink" /&amp;gt;']
    Tags[:smiley3] = [/\:\-?\(/, '&amp;lt;img title=":(" src="/images/emoticons/sad.png" alt="sad" /&amp;gt;']

    TagList += [:smiley1, :smiley2, :smiley3]
  end
end&lt;/pre&gt;
&lt;p&gt;&lt;em&gt;Appendix: As you can see, i&amp;#8217;ve modified the constants Tags and TagList which is at least not good style and throws a warning. To use proper code, you could change the bbcodeizer plugin constants to variables (using lower-case characters, e.g. tags and tag_list). Other possibility is to adjust the constants directly in the plugin.&lt;br /&gt;
&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt; &lt;/em&gt;The smiley shortcuts are now replaced by the according images in any text you pass bbcodeize (e.g.&lt;/p&gt;
&lt;pre&gt;bbcodeize 'Hi :)'&lt;/pre&gt;
&lt;p&gt;returns&lt;/p&gt;
&lt;pre&gt;'Hi &amp;lt;img title=":)" src="/images/emoticons/smile.png" alt="smile" /&amp;gt;'&lt;/pre&gt;
&lt;p&gt;Dont forget to put some smilies in /images/emoticons  Keywords: smiley, smileys, smilie, smilies, rails, bbcode, bbcodeizer, ruby, emoticon, emoticons&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/378487074" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/08/smilies-in-rails-using-bbcodeizer/#comments" thr:count="1" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/08/smilies-in-rails-using-bbcodeizer/feed/atom/" thr:count="1" />
		<thr:total>1</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/08/smilies-in-rails-using-bbcodeizer/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Move Wubi installation (Ubuntu on Windows) to a native Ubuntu system]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/353745941/" />
		<id>http://flip.netzbeben.de/?p=25</id>
		<updated>2008-08-12T02:03:45Z</updated>
		<published>2008-08-02T18:26:41Z</published>
		<category scheme="http://flip.netzbeben.de" term="Linux" /><category scheme="http://flip.netzbeben.de" term="Ubuntu" />		<summary type="html"><![CDATA[There&#8217;s a tool called LVPM which could do the move, but there are sometimes problems with it. So I recommend to use a faster and safer way to do it - with the wubi-move-to-partition script:

Boot into your Wubi installation.
Open a shell and do a:
wget "https://wiki.ubuntu.com/WubiGuide?action=AttachFile&#38;do=get&#38;target=wubi-move-to-partition"
Install and run gparted:
sudo apt-get install gparted
sudo gparted
Now create a swap [...]]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/08/move-wubi-installation-ubuntu-on-windows-to-a-native-ubuntu-system/">&lt;p&gt;There&amp;#8217;s a tool called &lt;a href="http://lubi.sourceforge.net/lvpm.html" target="_blank"&gt;LVPM&lt;/a&gt; which could do the move, but there are sometimes problems with it. So I recommend to use a faster and safer way to do it - with the &lt;em&gt;wubi-move-to-partition&lt;/em&gt; script:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Boot into your Wubi installation.&lt;/li&gt;
&lt;li&gt;Open a shell and do a:&lt;br /&gt;
&lt;code&gt;wget "https://wiki.ubuntu.com/WubiGuide?action=AttachFile&amp;amp;do=get&amp;amp;target=wubi-move-to-partition"&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Install and run gparted:&lt;br /&gt;
&lt;code&gt;sudo apt-get install gparted&lt;/code&gt;&lt;br /&gt;
&lt;code&gt;sudo gparted&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Now create a swap partition (1x or better 2x the size of your memory) and an ext3 partition for your new ubuntu partition.&lt;/li&gt;
&lt;li&gt;Back in the shell, find out how the new partitions are called with:&lt;br /&gt;
&lt;code&gt;sudo fdisk -l&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Now start the move:&lt;br /&gt;
&lt;code&gt;sudo sh wubi-move-to-partition /dev/sdx1 /dev/sdx2&lt;/code&gt;&lt;br /&gt;
(where /dev/sdx1 is your new ubuntu partition and /dev/sdx2 is the new swap partition you&amp;#8217;ve just created with gparted)&lt;/li&gt;
&lt;li&gt;After the successful move, simply reboot your system. You should be able to boot into your new native ubuntu system.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;If there are no problems with your new system, you might want to boot into windows to uninstall your wubi installation (Start Menu/Control Panel/Add or Remove Programs). It&amp;#8217;s not needed any longer.&lt;br /&gt;
Keywords: transfer wubi, upgrade wubi, change wubi, native ubuntu, native linux, proper, clean, full, real, remove wubi&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/353745941" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/08/move-wubi-installation-ubuntu-on-windows-to-a-native-ubuntu-system/#comments" thr:count="1" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/08/move-wubi-installation-ubuntu-on-windows-to-a-native-ubuntu-system/feed/atom/" thr:count="1" />
		<thr:total>1</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/08/move-wubi-installation-ubuntu-on-windows-to-a-native-ubuntu-system/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Smilies in Rails using RedCloth]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/325235718/" />
		<id>http://flip.netzbeben.de/?p=24</id>
		<updated>2008-08-29T23:23:43Z</updated>
		<published>2008-07-02T21:16:03Z</published>
		<category scheme="http://flip.netzbeben.de" term="Development" /><category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="Rails 2.0" /><category scheme="http://flip.netzbeben.de" term="Rails 2.1" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[There&#8217;s also a guide to use Smilies in Rails using BBCodeizer.
RedCloth doesn&#8217;t come with support for smilies, so i&#8217;ve added it for one of my projects.
You need to extend the RedCloth class. You could do this by creating a file in your /lib directory, which you have to include in your environment.rb. Here an example [...]]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/07/smilies-in-rails-using-redcloth/">&lt;p&gt;There&amp;#8217;s also a guide to use &lt;a href="http://flip.netzbeben.de/2008/08/smilies-in-rails-using-bbcodeizer/" target="_self"&gt;Smilies in Rails using BBCodeizer&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;RedCloth doesn&amp;#8217;t come with support for smilies, so i&amp;#8217;ve added it for one of my projects.&lt;br /&gt;
You need to extend the RedCloth class. You could do this by creating a file in your /lib directory, which you have to include in your environment.rb. Here an example for three simple smilies:&lt;/p&gt;
&lt;pre&gt;class RedCloth
  def glyphs_smilies(text)
    text.gsub!(/\:\-?\)/, '&amp;lt;img src="/images/emoticons/smile.png" alt="smile" /&amp;gt;')
    text.gsub!(/\;\-?\)/, '&amp;lt;img src="/images/emoticons/wink.png" alt="wink" /&amp;gt;')
    text.gsub!(/\:\-?\(/, '&amp;lt;img src="/images/emoticons/sad.png" alt="sad" /&amp;gt;')
  end
end&lt;/pre&gt;
&lt;p&gt;To include this new function in your views, write an helper, e.g. format_text in ApplicationHelper:&lt;/p&gt;
&lt;pre&gt;module ApplicationHelper
  def format_text(text)
    RedCloth.new(text).to_html(:textile, :glyphs_smilies)
  end
end&lt;/pre&gt;
&lt;p&gt;Now you could use it anywhere in your views, like&lt;/p&gt;
&lt;pre&gt;  &amp;lt;%= format_text ":)" %&amp;gt;&lt;/pre&gt;
&lt;p&gt;or&lt;/p&gt;
&lt;pre&gt;  &amp;lt;%= format_text @your_record.your_text %&amp;gt;&lt;/pre&gt;
&lt;p&gt;Of course, you have to put some smilies in /images/emoticons &lt;img src='http://flip.netzbeben.de/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /&gt; &lt;/p&gt;
&lt;p&gt;Keywords: smiley, smileys, smilie, smilies, rails, textile, redcloth, ruby, emoticon, emoticons&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/325235718" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/07/smilies-in-rails-using-redcloth/#comments" thr:count="3" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/07/smilies-in-rails-using-redcloth/feed/atom/" thr:count="3" />
		<thr:total>3</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/07/smilies-in-rails-using-redcloth/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Rails: routes and special characters like dots]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/325196578/" />
		<id>http://flip.netzbeben.de/?p=23</id>
		<updated>2008-07-02T21:01:52Z</updated>
		<published>2008-07-02T21:00:26Z</published>
		<category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="Rails 1.2" /><category scheme="http://flip.netzbeben.de" term="Rails 2.0" /><category scheme="http://flip.netzbeben.de" term="Rails 2.1" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[Rails doesn&#8217;t seem to like dots and other special chars in its routes.
If you want to use URLs like http://www.domain.com/post/1/just_a_test.. logically the following route seems to be sensible:
map.connect '/post/:id/:title', :controller => 'forum', :action => 'show_post'
But rails won&#8217;t like the dots. Use a route like the following to allow a URL with special characters to be [...]]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/07/rails-routes-and-special-characters-like-dots/">&lt;p&gt;Rails doesn&amp;#8217;t seem to like dots and other special chars in its routes.&lt;br /&gt;
If you want to use URLs like http://www.domain.com/post/1/just_a_test.. logically the following route seems to be sensible:&lt;/p&gt;
&lt;pre&gt;map.connect '/post/:id/:title', :controller =&gt; 'forum', :action =&gt; 'show_post'&lt;/pre&gt;
&lt;p&gt;But rails won&amp;#8217;t like the dots. Use a route like the following to allow a URL with special characters to be routed:&lt;/p&gt;
&lt;pre&gt;map.connect '/post/:id/:title', :controller =&gt; 'forum', :action =&gt; 'show_post', :requirements =&gt; { :title =&gt; /.*/ }&lt;/pre&gt;
&lt;p&gt;Keywords: dots, dot, no route matches, punkt, punkte, routes.rb, routing, route, rails, problem, won&amp;#8217;t work&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/325196578" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/07/rails-routes-and-special-characters-like-dots/#comments" thr:count="2" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/07/rails-routes-and-special-characters-like-dots/feed/atom/" thr:count="2" />
		<thr:total>2</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/07/rails-routes-and-special-characters-like-dots/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Sehnsucht nach Ruhe]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/322276988/" />
		<id>http://flip.netzbeben.de/?p=22</id>
		<updated>2008-06-28T23:32:20Z</updated>
		<published>2008-06-28T23:29:11Z</published>
		<category scheme="http://flip.netzbeben.de" term="German" /><category scheme="http://flip.netzbeben.de" term="Inspiration" />		<summary type="html"><![CDATA[
]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/06/ruhe/">&lt;p&gt;&lt;embed src="/files/ruhe.mp3" loop="false" autostart="false" width="170" height="25" /&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/322276988" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/06/ruhe/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/06/ruhe/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/06/ruhe/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Functional test for HTTP Basic Authentication in Rails 2]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/317723318/" />
		<id>http://flip.netzbeben.de/?p=15</id>
		<updated>2008-07-04T23:59:01Z</updated>
		<published>2008-06-23T00:31:54Z</published>
		<category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="Rails 2.0" /><category scheme="http://flip.netzbeben.de" term="Rails 2.1" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby 1.8" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[If you want to provide a username and password for a HTTP Basic Authentication in one of your functional tests, simply use the following:

def test_should_get_index
  @request.env["HTTP_AUTHORIZATION"] = "Basic " + Base64::encode64("username:password")
  get :index
  assert_response :success
  assert_not_nil assigns(:articles)
end

Keywords: rails test, functionals, authorization, basic http authentication, how to test
]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/06/functional-test-for-http-authentication-in-rails-2/">&lt;p&gt;If you want to provide a username and password for a HTTP Basic Authentication in one of your functional tests, simply use the following:&lt;/p&gt;
&lt;pre&gt;
def test_should_get_index
  &lt;u&gt;@request.env["HTTP_AUTHORIZATION"] = "Basic " + Base64::encode64("username:password")&lt;/u&gt;
  get :index
  assert_response :success
  assert_not_nil assigns(:articles)
end
&lt;/pre&gt;
&lt;p&gt;Keywords: rails test, functionals, authorization, basic http authentication, how to test&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/317723318" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/06/functional-test-for-http-authentication-in-rails-2/#comments" thr:count="1" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/06/functional-test-for-http-authentication-in-rails-2/feed/atom/" thr:count="1" />
		<thr:total>1</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/06/functional-test-for-http-authentication-in-rails-2/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[404 in rails]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/317080804/" />
		<id>http://flip.netzbeben.de/?p=14</id>
		<updated>2008-06-29T03:18:25Z</updated>
		<published>2008-06-21T21:24:50Z</published>
		<category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[If you need to show a 404 error page from your controller without using an exception, this could help:
render :file => "#{RAILS_ROOT}/public/404.html",  :status => 404 and return
]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/06/404-in-rails/">&lt;p&gt;If you need to show a 404 error page from your controller without using an exception, this could help:&lt;/p&gt;
&lt;pre&gt;render :file =&gt; "#{RAILS_ROOT}/public/404.html",  :status =&gt; 404 and return&lt;/pre&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/317080804" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/06/404-in-rails/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/06/404-in-rails/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/06/404-in-rails/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Rails 2: authenticate_or_request_with_http_basic and Apache]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/314179950/" />
		<id>http://flip.netzbeben.de/?p=13</id>
		<updated>2008-06-29T03:18:33Z</updated>
		<published>2008-06-12T21:33:10Z</published>
		<category scheme="http://flip.netzbeben.de" term="English" /><category scheme="http://flip.netzbeben.de" term="Rails 2.0" /><category scheme="http://flip.netzbeben.de" term="Rails 2.1" /><category scheme="http://flip.netzbeben.de" term="Ruby" /><category scheme="http://flip.netzbeben.de" term="Ruby On Rails" />		<summary type="html"><![CDATA[I&#8217;ve tried to use the new authenticate_or_request_with_http_basic function of Rails 2 to include a simple authentication for some special pages in an application. But Apache kept refusing authorization, even if the authenticate_or_request_with_http_basic-block was set to be always true.
To fix this, add or change this in your public/.htaccess (if using FastCGI):
RewriteRule ^(.*)$ dispatch.fcgi [E=X-HTTP_AUTHORIZATION:%{HTTP:Authorization},QSA,L]
Keywords: rails2 rails [...]]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/06/authenticate_or_request_with_http_basic-and-apache/">&lt;p&gt;I&amp;#8217;ve tried to use the new authenticate_or_request_with_http_basic function of Rails 2 to include a simple authentication for some special pages in an application. But Apache kept refusing authorization, even if the authenticate_or_request_with_http_basic-block was set to be always true.&lt;/p&gt;
&lt;p&gt;To fix this, add or change this in your public/.htaccess (if using FastCGI):&lt;/p&gt;
&lt;pre&gt;RewriteRule ^(.*)$ dispatch.fcgi [E=X-HTTP_AUTHORIZATION:%{HTTP:Authorization},QSA,L]&lt;/pre&gt;
&lt;p&gt;Keywords: rails2 rails http authentication error bug refusing apache problem&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/314179950" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/06/authenticate_or_request_with_http_basic-and-apache/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/06/authenticate_or_request_with_http_basic-and-apache/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/06/authenticate_or_request_with_http_basic-and-apache/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Save my life]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/318597857/" />
		<id>http://flip.netzbeben.de/?p=16</id>
		<updated>2008-06-24T03:55:05Z</updated>
		<published>2008-03-24T19:59:38Z</published>
		<category scheme="http://flip.netzbeben.de" term="Emo" /><category scheme="http://flip.netzbeben.de" term="Inspiration" /><category scheme="http://flip.netzbeben.de" term="Music" />		<summary type="html"><![CDATA[Another piece of great emo

]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/03/save-my-life/">&lt;p&gt;Another piece of great emo&lt;/p&gt;
&lt;p&gt;&lt;object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="425" height="344" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"&gt;&lt;param name="src" value="http://www.youtube.com/v/BKqZZg2U6t4&amp;amp;hl=de" /&gt;&lt;embed type="application/x-shockwave-flash" width="425" height="344" src="http://www.youtube.com/v/BKqZZg2U6t4&amp;amp;hl=de"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/318597857" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/03/save-my-life/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/03/save-my-life/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/03/save-my-life/</feedburner:origLink></entry>
		<entry>
		<author>
			<name>flipkick</name>
						<uri>http://flipkick.netzbeben.de</uri>
					</author>
		<title type="html"><![CDATA[Okkervil River]]></title>
		<link rel="alternate" type="text/html" href="http://feeds.feedburner.com/~r/flips/~3/318589111/" />
		<id>http://flip.netzbeben.de/?p=18</id>
		<updated>2008-06-24T03:24:00Z</updated>
		<published>2008-01-24T19:33:58Z</published>
		<category scheme="http://flip.netzbeben.de" term="Emo" /><category scheme="http://flip.netzbeben.de" term="Music" />		<summary type="html"><![CDATA[That&#8217;s what I&#8217;d call EMO.

]]></summary>
		<content type="html" xml:base="http://flip.netzbeben.de/2008/01/okkervil-river/">&lt;p&gt;That&amp;#8217;s what I&amp;#8217;d call EMO.&lt;/p&gt;
&lt;p&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/tKuQrflPVlQ&amp;#038;hl=de"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/tKuQrflPVlQ&amp;#038;hl=de" type="application/x-shockwave-flash" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/p&gt;
&lt;img src="http://feeds.feedburner.com/~r/flips/~4/318589111" height="1" width="1"/&gt;</content>
		<link rel="replies" type="text/html" href="http://flip.netzbeben.de/2008/01/okkervil-river/#comments" thr:count="0" />
		<link rel="replies" type="application/atom+xml" href="http://flip.netzbeben.de/2008/01/okkervil-river/feed/atom/" thr:count="0" />
		<thr:total>0</thr:total>
	<feedburner:origLink>http://flip.netzbeben.de/2008/01/okkervil-river/</feedburner:origLink></entry>
	</feed>
