Displaying 20 results from an estimated 300 matches similar to: "RedirectHandler? mongrel_rewrite?"
2006 Jun 21
7
Mongrel 0.3.13.1 -- Quick Small Fixes
Hi Everyone,
This is a small release that fixes a little bug, some of the
documentation, and adds the new RedirectHandler code and a @redirect@
call for the mongrel.conf files. It''s fresh so don''t rely on it.
Everyone should upgrade with the usual *gem update* command (which tells
you it''s "Upgrading...") and tell me how it works.
This release fixes:
* The
2007 May 27
3
Stripping out textile markup
Hi,
I have several hundred pages of text, all carefully marked up with
textile, which I use redcloth to convert to html for display. Now I
find I need all these pages to alternatively output plain text - ie.
A-Za-z0-9 and simple punctuation only. Any suggestions on the best
way to do this? My only thought is to let redcloth do its stuff, and
then strip out the html tags - but it feels wrong.
2006 Aug 13
3
+ migrations in camping
Camping apps are supposed to be little independent apps, often contained in a
single file, which create the database tables and manage them without hassle.
These days it''s common to see in a Camping app:
module Tepee::Models
def self.schema(&block)
@@schema = block if block_given?
@@schema
end
end
Tepee::Models.schema do
create_table :tepee_pages,
2008 Jan 04
1
Howto write a mongrel handler for a CGI app using CGIWrapper
Hello,
Just for further reference in case of someone else want to do the same :
I wanted to write a mongrel for a CGI app :
[[[
require ''cgi''
require ''foo''
cgi = CGI.new
if !cgi[''uri''] || (cgi[''uri''] == '''')
Foo.error "URI argument is required"
end
uri = cgi[''uri'']
user =
2006 Jun 30
50
Time To Pick the Mongrel BUGS Mascot!
Bradley Taylor shot me this *goldmine* of ugly ugly ugly dogs:
http://www.sonoma-marinfair.org/uglydogvote.shtml
I *have* to use one of these for the Mongrel BUGS Mascot. He''ll go on
our bug list page and replace the little beetles on the left.
Pick the dog you think best represents a lovable but defective pooch and
reply to this with your +1.
Let the voting begin!
--
Zed A. Shaw
2006 Aug 10
1
acts_as_textiled
It''s nothing revolutionary. Just a plugin which lets you forget about
the whole Textile to HTML render process. Once you tell your model
which fields should acts_as_textiled (and as long as you''re using
form_for for your text entry) it Just Works. No DB changes or
whatnot.
Here''s the skivvy: http://errtheblog.com/post/14
Tips and tricks in that post and README.
2006 Oct 22
3
Keeping DRY - I like a simple life!
Hi,
I''m new to Ruby and Rails and I would be very grateful for some advice.
I''ve got the following code.
class Foo < ActiveRecord::Base
include Versionable # Some methods to handle my versioned objects
has_many :versions, :class_name => "FooVersion", :foreign_key =>
"parent_id"
belongs_to :curr, :class_name => "FooVersion",
2007 Jan 16
4
question about sessions and code re-use
hey there,
i have a simple model called key_words.rb
the purpose of this is to hold system config data.
it also holds the parameters that our system uses to judge the
condition of the stuff we monitor.
anyway, one of the methods is this
def self.get_in_wet_list(status)
wet_list = find(:first,
:conditions => "name = ''wet_list'' ")
2006 Aug 15
1
Camping with Dr. Nic
Campers. Dr. Nic.
The new migrations in Camping''s trunk are very nice. They also open
the door (just an inch) to using Dr. Nic''s Magic Models with Camping.
Here''s my stab at ''er:
http://require.errtheblog.com/camping/blog.rb
Run that against Camping trunk. Don''t forget to `sudo gem install
dr_nic_magic_models`.
The hackery is in
2007 Feb 26
2
undefined method ... from `alias_method'
0 wicked var/www % ./script/console
Loading development environment.
>> r = Recipe.find :first
NameError: undefined method `recipe_type='' for class `Recipe''
from ./script/../config/../config/../app/models/recipe.rb:
101:in `alias_method''
In recipes_controller:
alias_method :orig_recipe_type=, :recipe_type=
def recipe_type=(t)
if t.nil?
2017 Mar 14
2
httpd/sites-available directory
I just received some advice from a colleague of a colleague over at
openssl.org. But they use debian. Please look at this and help me out
on how Centos7 handles this:
Note the comment of the location of virtualhost config files. Centos7
does not have a "man a2ensite".
thanks
Rewriterules and https. Actually, looking at what you have doesn't
really tell me why it gets applied
2006 Aug 10
6
Multiple sites using one data source
Hi,
Just wondering if anyone has any suggestions as to the best way to
provide access to the same data source for the (possible) creation of
multiple web sites. I figure my options are:
- Direct database access over tcp
- ActionWebService
- Wait for ActionResource
I''ve done up some work with ActionWebService already, but I don''t think
it''s going to work because it
2006 Jul 02
0
Use mod_rewrite rules instead of rails-routes
Hi
I am trying to use mod_rewrite rules instead of rails routes (don''t ask
why.., routes are not flexible enough in my case):
Basically I have these two RewriteRules in my .htaccess file:
RewriteRule ^(.*\/)*index\.([0-9]+)\.([0-9]+)\.html$
/keywords/show?id=$2&page=$3
RewriteRule ^(.*)$ dispatch.fcgi [QSA,L]
So I want /foo/bar/index.123.4.html rewritten to
2006 Jul 25
0
configure rails on apache2 without virtual host
Hi, all:
I try to configure rails application on apache2 on fedora box without
using virtual host.
I can''t make it run correctly after following some ''hints'' from the web.
Following is what I have done:
- Apache2 already run well;
- mod_fcgid installed by source;
- ruby fcgi installed by source;
- test ok using some sample test.fcgi
I guessed something wrong with
2017 Mar 14
0
httpd/sites-available directory
Hello,
a2ensite and co is Debian/ubuntu specific. On CentOS there is no such thing.
It's not clear to me what you are trying to achieve. Can you rephrase so we can help?
--
Sent from the Delta quadrant using Borg technology!
Nux!
www.nux.ro
----- Original Message -----
> From: "Robert Moskowitz" <rgm at htt-consult.com>
> To: "CentOS mailing list"
2006 Aug 13
1
establish_connection method
I''m digging into rails source code.
But I''ve got a problem in undestading actionrecord::base source code
which is connection_specification.rb.
In the body of establish_connection method,
def self.establish_connection(spec = nil)
case spec
when nil
raise AdapterNotSpecified unless defined? RAILS_ENV
establish_connection(RAILS_ENV)
2006 Mar 02
0
March Ruby events in the SF Bay Area
Sadly, no South Bay Ruby events have been announced. C''mon,
guys, make something happen...
3/14 6:00 pm Beginner''s Presentation -
Chris Wanstrath will write a Ruby time server and
discuss the code, to compliment Barce''s time server
query script [from the Feb. meeting]. Chris says:
"Nothing
2006 Aug 23
0
emdash vs <del>
Hey guys. Is this a bug or what?
>> RedCloth.new("First part -- middle part -- end part.").to_html
=> "<p>First part <del>- middle part -</del> end part.</p>"
But http://textism.com/tools/textile/index.php says the output should
be:
<p>First part—middle part—end part.</p>
Thing is, I *want*
2009 Oct 02
0
[PATCH] configurator: update some migration examples
We now give an example of how a before_fork hook can be used
to incrementally migrate off the old code base without hitting
a thundering herd (especially in the "preload_app false") case.
Also comment on the per-worker listen usage in the RDoc, not
just a hidden comment.
---
I just pushed this out earlier, this example was inspired by Chris
Wanstrath''s before_fork hook but
2017 Mar 14
0
httpd/sites-available directory
If all you want is a really fast redirect, then indeed what those people advised should work.
NameVirtualHost IP:80 (you only need this on apache 2.2 and lower, not needed on CentOS7 which comes with apache 2.4)
<VirtualHost IP:80>
ServerName webmail.bar.com
Redirect permanent / https://webmail.bar.com/
</virtualHost>
--
Sent from the Delta quadrant using Borg technology!
Nux!