I think it is under file -> export->"export image or script",
then you get a pop up window. I think jpg is the only choice currently
available,
but I don't remember for sure.
> thanks.
>
> >
>
I think the original poster (Janzo) wants a dynamically rotatable Jmol
java applet embedded right in his webpage, rather than a static
jpg image. If you just want a static image, you can take a screen shot,
or use viewer='tachyon' as an option to the plot3d or show command
in Sage.
It is definitely possible to have the Jmol applet embedded right in a
blog post -- in fact, that's exactly how I first learned about Jmol.
Look at the last example here:
http://www.openscience.org/blog/
Look at the discussion here:
http://groups.google.com/group/sage-devel/browse_thread/thread/b0dd0a6788db2471/ecbe425e6ab9a625?lnk=gst&q=chemists+rock#ecbe425e6ab9a625
This might help.
William
Get the jmol applet from the jmol website.
-- william
Maybe you don't meed the "code of the applet", but the data that Sage
creates which is then read in by the applet? If so, the only way to
answer your question is to wait to see if Robert Bradshaw responds (he
probably will by Monday),
or to look in detail at the appropriate part of the Sage source code.
-- William
> Sorry it could be my poor english but you don't understand me.
>
> Actually I have running jmol's applets of some molecules in my blog.
> What I can't do is get the code of my sage's applet, I mean I plot
> some parametric surface in a jmol applet, ok, now... where is the code
> of that applet??
>
> I hope to be more clear :)
> thanks.
I assume you're looking for the actual script that generates the
surface, right? There should be an easier way to get it (should we
always provide a direct link or would that be too intrusive?) but
here's a way to do it currently. At the top of the cell type
open ('a.txt', 'w')
which will create a file. This will turn into a link at the bottom of
the cell which you can click on. The url will be something like
https://localhost:8000/home/admin/73/cells/1/a.txt . This tells you
that all the data files for that cell are in https://localhost:8000/
home/admin/73/cells/1 . (Once you know the folder, you don't need
a.txt anymore, but that's the easiest way to get to it.)
Specifically, there is a .jmol script, and a .jmol.zip file.
The .jmol script is what needs to be fed into the applet, and all it
does is tell the applet to load everything in the .jmol.zip file
(which is an ordinary zip file, but all packaged into a single bundle
so it's easier to keep track of). This should be all you need to run
the applet statically on any web page.
- Robert
If you refresh a sage notebook page that shows a 3d jmol image you'll
see that it contains:
jmol_applet(500, "/home/admin/37/cells/16/sage0-size500.jmol")
where jmol_applet is some javascript function that is defined by main.js
(part of Sage) basically to be
jmolApplet(size, "script " + url);
where jmolApplet is defined in Jmol.js (which is from the jmol website).
By the way, this email should be in sage-support. It's not a sage-edu
question, and there are over 10 times as many people subscribed to sage-support.
-- William