We seem unable to get SVG running under Rails with apparent memory conflicts between the SVG xml object and parameters. For us, unless we can get SVG running okay under Rails, it is a showstopper for us to use Rails. There seem to be only 2 examples out there for SVG, the graph project that actually converts SVG to another image format (way too cumbersome/unworkable for our needs) and the pinkjuice example that requires a separate cgi file creation (again seemingly too complex for our dynamically generated SVG diagrams). Is there any help out there? Are we missing something or must we abandon Rails for now? Thanks for any help. -- Posted via http://www.ruby-forum.com/.
Have you looked at this: http://ruby-svg.sourceforge.jp/ Though the site is in Japanese, there''s an english language readme and a bunch of samples in the tarball. --Casey On Mar 16, 2006, at 4:48 PM, jack wrote:> We seem unable to get SVG running under Rails with apparent memory > conflicts between the SVG xml object and parameters. For us, > unless we > can get SVG running okay under Rails, it is a showstopper for us to > use > Rails. > > There seem to be only 2 examples out there for SVG, the graph project > that actually converts SVG to another image format (way too > cumbersome/unworkable for our needs) and the pinkjuice example that > requires a separate cgi file creation (again seemingly too complex for > our dynamically generated SVG diagrams). Is there any help out there? > Are we missing something or must we abandon Rails for now? Thanks for > any help. > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
The SVG is handled client-side... I don''t see how it would make a difference if you''re using rails, php, or just serving it as a static file. I remember you were trying to do it with the object/embed tag, right? So, given the same object/embed tag what is happening differently between serving it from a php site versus the rails site? b jack wrote:> We seem unable to get SVG running under Rails with apparent memory > conflicts between the SVG xml object and parameters. For us, unless we > can get SVG running okay under Rails, it is a showstopper for us to use > Rails. > > There seem to be only 2 examples out there for SVG, the graph project > that actually converts SVG to another image format (way too > cumbersome/unworkable for our needs) and the pinkjuice example that > requires a separate cgi file creation (again seemingly too complex for > our dynamically generated SVG diagrams). Is there any help out there? > Are we missing something or must we abandon Rails for now? Thanks for > any help. >
Just want to add my voice to Ben''s. The problem you''re seeing is (almost certainly) nothing to do with Rails. SVG is just a bunch of XML text that gets sent to the client browser within a regular HTML page - it would be a huge surprise to me if you''d found a bug in Rails that prevented this from happening correctly. If I get the chance tonight, I''ll have a play with it. If you''re using Firefox 1.5 to render the SVG, be aware that Firefox only works with a subset of SVG - it doesn''t support the whole SVG spec. Good luck Dave M. On 17/03/06, Ben Munat <bent@munat.com> wrote:> The SVG is handled client-side... I don''t see how it would make a difference if you''re > using rails, php, or just serving it as a static file. > > I remember you were trying to do it with the object/embed tag, right? So, given the same > object/embed tag what is happening differently between serving it from a php site versus > the rails site? > > b > > jack wrote: > > We seem unable to get SVG running under Rails with apparent memory > > conflicts between the SVG xml object and parameters. For us, unless we > > can get SVG running okay under Rails, it is a showstopper for us to use > > Rails. > > > > There seem to be only 2 examples out there for SVG, the graph project > > that actually converts SVG to another image format (way too > > cumbersome/unworkable for our needs) and the pinkjuice example that > > requires a separate cgi file creation (again seemingly too complex for > > our dynamically generated SVG diagrams). Is there any help out there? > > Are we missing something or must we abandon Rails for now? Thanks for > > any help. > > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
I don''t understand Rails internals well enought but what runs fine under html or under php creates major conflicts under Rails. And I''ve yet to see any SVG examples running under Rails to indicate the problem is on our side. Ben Munat wrote:> The SVG is handled client-side... I don''t see how it would make a > difference if you''re > using rails, php, or just serving it as a static file. > > I remember you were trying to do it with the object/embed tag, right? > So, given the same > object/embed tag what is happening differently between serving it from a > php site versus > the rails site? > > b-- Posted via http://www.ruby-forum.com/.
Still, rails should *not* be doing anything with your static svg other than serving it. There must be some difference in the resulting html file or how it''s served between your various setups... Rails internals shouldn''t even enter into it... the svg is served directly by the server. If you''re interested in making it work in rails, why not post complete examples of what you''re trying to do (code samples, platform info, server info, etc.). My memory of this thread is that you just keep saying "it doesn''t work" without saying what you''re trying to do or how. Or, if you''re happy enough with PHP and it works with PHP, just stick with that. b jack wrote:> I don''t understand Rails internals well enought but what runs fine under > html or under php creates major conflicts under Rails. And I''ve yet to > see any SVG examples running under Rails to indicate the problem is on > our side. > > Ben Munat wrote: > >>The SVG is handled client-side... I don''t see how it would make a >>difference if you''re >>using rails, php, or just serving it as a static file. >> >>I remember you were trying to do it with the object/embed tag, right? >>So, given the same >>object/embed tag what is happening differently between serving it from a >>php site versus >>the rails site? >> >>b > > >
show some code.. show how you are building the object tag, show the data for the svg then we all see how we can make it work... On Saturday, March 18, 2006, at 12:10 AM, jack wrote:>I don''t understand Rails internals well enought but what runs fine under >html or under php creates major conflicts under Rails. And I''ve yet to >see any SVG examples running under Rails to indicate the problem is on >our side. > >Ben Munat wrote: >> The SVG is handled client-side... I don''t see how it would make a >> difference if you''re >> using rails, php, or just serving it as a static file. >> >> I remember you were trying to do it with the object/embed tag, right? >> So, given the same >> object/embed tag what is happening differently between serving it from a >> php site versus >> the rails site? >> >> b > > >-- >Posted via http://www.ruby-forum.com/. >_______________________________________________ >Rails mailing list >Rails@lists.rubyonrails.org >http://lists.rubyonrails.org/mailman/listinfo/railsMikkel Bruun www.strongside.dk - Football Portal(DK) nflfeed.helenius.org - Football News(DK) ting.minline.dk - Buy Old Stuff!(DK) -- Posted with http://DevLists.com. Sign up and save your time!