Forum: Ruby on Rails SVG showstopper

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.
Bda18ca8ac44f780eb41892afd22e954?d=identicon&s=25 jack (Guest)
on 2006-03-17 01:48
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.
1274a7b1e244f663b967aec378f9f525?d=identicon&s=25 Casey Cady (Guest)
on 2006-03-17 02:04
(Received via mailing list)
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
4005a47a8f2ceee49670b920593c1d52?d=identicon&s=25 Ben Munat (Guest)
on 2006-03-17 09:06
(Received via mailing list)
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
F3dc06f587d1ff4c7366b102bfda9204?d=identicon&s=25 David Mitchell (Guest)
on 2006-03-17 10:04
(Received via mailing list)
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.
Bda18ca8ac44f780eb41892afd22e954?d=identicon&s=25 jack (Guest)
on 2006-03-18 00:10
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
4005a47a8f2ceee49670b920593c1d52?d=identicon&s=25 Ben Munat (Guest)
on 2006-03-18 00:31
(Received via mailing list)
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
5d15c6821f3c3054c04b85471824ba7c?d=identicon&s=25 Mikkel Bruun (Guest)
on 2006-03-18 08:38
(Received via mailing list)
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 remember you were trying to do it with the object/embed tag, right?
>_______________________________________________
>Rails mailing list
>Rails@lists.rubyonrails.org
>http://lists.rubyonrails.org/mailman/listinfo/rails


Mikkel Bruun

www.strongside.dk    - Football Portal(DK)
nflfeed.helenius.org - Football News(DK)
ting.minline.dk      - Buy Old Stuff!(DK)
This topic is locked and can not be replied to.