0

I have to develop an application which will generate product catalog. My plan is to build a webapp with PHP and MySQL and the catalog pages to be generated in SVG format. I was thinking to use RaphaelJS for the SVG file generation.

I don't expect to get a very smooth and a final version for the pages of the product catalog from my app. For the fine edits, the client wish to use corel draw. I know that I can convert the svg files to cdr, using the uniconvertor (if the client insist to have cdr file).

The problem is that I'm not sure if this is the right approach. Before I start coding I need some advice. Do you think that this is a good path?

Jakub Hampl
  • 39,863
  • 10
  • 77
  • 106
dole
  • 343
  • 2
  • 6
  • 23
  • 1
    Is the catalog meant to be consumed by a web browser? Or is this just a way to automate creation of static catalogs, and a webapp is the tool to achieve that? – peteorpeter Mar 14 '11 at 17:15
  • @peterorpeter: the webapp is for automation of the static catalog. later the user will use core draw to finalize the catalog and send it to the printer. – dole Mar 19 '11 at 10:47
  • You should accept an answer here. – KeatsKelleher Mar 23 '11 at 23:41

2 Answers2

1

Restating the problem, you want the user to create the SVG client-side in the web browser, and then send the SVG to the server later on for use with Corel Draw? If this is correct, then I think your general approach is reasonable. I wouldn't personally use RaphaëlJS, since I like coding directly to SVG (without the abstraction layer of Raphaël or the VML shim for older IE).

Since I don't use Raphaël personally, for serialization I can only provide this link that I have no personal experience with:

If you end up using raw SVG (or if you can access the <svg> element from Raphaël) then my answer to another question shows how you can get the serialized SVG from client-side generated data (to send to your server).

Community
  • 1
  • 1
Phrogz
  • 296,393
  • 112
  • 651
  • 745
1

A lot of dynamic SVG is done using svgweb. This allows you access to the SVG elements and doesn't limit your ability to manipulate them. It even patches unsupported JavaScript methods for IE.

Raphael doesn't currently support the (group) element. This is a major shortcoming if you are generating generally easy to manipulate groups of elements.

KeatsKelleher
  • 10,015
  • 4
  • 45
  • 52