# Output

`string Output([string dest [, string name [, boolean isUTF8]]])`

## Description

Send the document to a given destination: browser, file or string. In the case of a browser, the PDF viewer may be used or a download may be forced.
The method first calls Close() if necessary to terminate the document.

## Parameters

`dest`
  Destination where to send the document. It can be one of the following:
  - `I`: send the file inline to the browser. The PDF viewer is used if available.
  - `D`: send to the browser and force a file download with the name given by `name`.
  - `F`: save to a local file with the name given by `name` (may include a path).
  - `S`: return the document as a string.
  The default value is `I`.
`name`
  The name of the file. It is ignored in case of destination `S`.
  The default value is `doc.pdf`.
`isUTF8`
  Indicates if `name` is encoded in ISO-8859-1 (`false`) or UTF-8 (`true`). Only used for destinations `I` and `D`.
  The default value is `false`.

## See also

Close

Index