205
EXTENDING FIREWORKS
The Fireworks Object
Las
t
up
d
a
ted
12/8/2009
Returns
A Boolean value:
true
if successful;
false
otherwise.
Description
Exports a document’s layers as individual images. The image names are based on the names in the Layers panel. The
layers from the current frame are exported.
Example
The following command exports the layers in the third open document to the C:\images directory.
fw.exportLayers(fw.documents[2], "file:///C|/images");
fw.exportMXMLAndImages()
Availability
Fireworks 9.
Usage
fw.exportMXMLAndImages(
doc, htmlUrl, imagesUrl
)
Arguments
doc
A Document object that specifies the document to be exported (see “
The Document object
” on page 27). If
doc
is
null
, the active document is exported.
htmlUrl
The filename of the exported MXML file, which is expressed as a file://URL. If
htmlUrl
is
null
, no MXML is
generated.
imagesUrl
The name of the file containing the exported image(s), which is expressed as a file://URL, and might not
be
null
. If a single image is generated, this function uses
imagesUrl
as the name of the image file. If multiple sliced
images are exported, it uses
imagesURL
to generate automatically named images, and all images are placed in this
directory.
Returns
A Boolean value:
true
if successful;
false
otherwise.
Description
Exports one image if the document contains no slice objects and multiple images if the document contains one or more
slice objects. It also optionally exports MXML. The document is exported using the current export settings and export
options.
Example
The following command exports the current document as HTML and as one or more images.
fw.exportMXMLAndImages(null, "file:///C|/mysite/nav.htm",
"file:///C|/mysite/images/nav.gif");
See also
fw.exportDocumentAs()