Forum: Ruby on Rails Typo and Instant Rails 1.2

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
662321361e686beeb0693e82d398f83f?d=identicon&s=25 Ed Gard (egard)
on 2006-04-08 18:03
Instant Rails is at 1.2 and I have installed Typo SVN Revsion 1000.

The sidebar changes stall with the spinner running even after the
*publish* button is clicked.  The changes, themselves, do appear in the
actual blog.

When the *Sort Alphabetically* is clicked under categories an error
occurrred.  I changed the code as follows:

C:\InstantRails-1.2\rails_apps\typo1000\app\controllers\admin\categories_controller.rb
<typo:code lang="ruby">
 def asort
    Category.reorder_alpha
    #render_component :action => "category_container" - Removed and
added two lines below - Ed Gard
	@categories = Category.find(:all, :order => :position)
    render :partial => "categories"
  end
</typo:code>

Other that that, Typo appears to run on IR 1.2 WITHOUT the need for
vendor/rails (frozen rails).

I like to see in the SCGI console which app is running, so I added the
following change which is just cosmetic.

To display the environment and the port in the SCGI console window, I
made the following changes:



C:\InstantRails-1.2\ruby\lib\ruby\gems\1.8\gems\scgi_rails-0.4.3\bin\scgi_service
<typo:code lang="ruby">
# Added Port for display -- Ed Gard
def configure_rails(environment, port)
    ENV["RAILS_ENV"] = environment
		# Added to display environment and port -- Ed Gard
    STDERR.puts("Environment: #{environment}; Port: #{port}")
    require "config/environment"
    ActiveRecord::Base.threaded_connections = false
    require 'dispatcher'
end

class RailsController < SCGI::Controller
    def initialize(config_file)
        @config_file = config_file
				# Added the port for display -- Ed Gard
        configure_rails(config[:env], config[:port])
        super(RailsProcessor.new(config))
    end
</typo:code>

Checkout the Typo head at *svn checkout svn://typosphere.org/typo/trunk
typo*

So, for you Typo fans, Instant Rails 1.2 and typo are a go!

Ed
This topic is locked and can not be replied to.