"Szabolcs Szasz" <sz / szasz.hu> writes:

> I downloaded and tried it but fails to create a session (?).
> (That redirecting message appears, but that's all. I don't 
> have the energy to debug it out now, sorry. I have session 
> cookies enabled (not that it should be required), but well, 
> I could never get Ruby (1.6.7) cgi/sessions working here 
> yet for some reason, with reasonable effort. PHP sessions 
> work just fine on the same setup.)
>
> BTW, this iowa stuff looks very interesting. Anyone used 
> it with success?
>
> Cheers,
> Sab

I got iowa working under ruby 1.7.3, but I had to make some small
changes.  Two changes were minor and only served to remove warnings, but
one of the changes (the one in Context.rb) was essential for
oid-generated links to work.

Here are my patches:

*** Application.rb.orig	Sat Oct 19 17:43:54 2002
--- Application.rb	Sat Oct 19 13:47:33 2002
***************
*** 88,94 ****
  		data = file.read
  		
  		begin
! 			codefile = File.new(file.path.sub(".html", ".iwa"))
  #			puts "reloading " + codefile.path
  			codedata = codefile.read
  		rescue Exception
--- 88,94 ----
  		data = file.read
  		
  		begin
! 			codefile = File.new(file.path.sub(/\.html/, ".iwa"))
  #			puts "reloading " + codefile.path
  			codedata = codefile.read
  		rescue Exception
*** BindingsParser.rb.orig	Sat Oct 19 17:44:06 2002
--- BindingsParser.rb	Sat Oct 19 13:45:32 2002
***************
*** 23,29 ****
  		while data.sub!(BodyPattern, "")
  			key, value = $1, $2
  			if value =~ /^[\d"':]/
! 				bindingHash[key] = LiteralAssociation.new(eval value)
  			else
  				bindingHash[key] = PathAssociation.new(value)
  			end
--- 23,29 ----
  		while data.sub!(BodyPattern, "")
  			key, value = $1, $2
  			if value =~ /^[\d"':]/
! 				bindingHash[key] = LiteralAssociation.new(eval(value))
  			else
  				bindingHash[key] = PathAssociation.new(value)
  			end
*** Context.rb.orig	Sat Oct 19 17:44:18 2002
--- Context.rb	Sat Oct 19 14:15:24 2002
***************
*** 8,14 ****
  	attr_accessor :session
  	
  	def initialize(url, params, out)
! 		url =~ "(.*?/iowa/[^/]*)(/.*)?"
  		@urlRoot = $1
  		remainder = $2? $2 : ""
  		
--- 8,14 ----
  	attr_accessor :session
  	
  	def initialize(url, params, out)
! 		url =~ /(.*?\/iowa\/[^\/]*)(\/.*)?/
  		@urlRoot = $1
  		remainder = $2? $2 : ""
  		
-- 
 Lloyd Zusman
 ljz / asfast.com