DocTool: documentation of the -upload options such as -namedFile2

Home › Forums › PDF24 Creator › DocTool: documentation of the -upload options such as -namedFile2

Tagged: 

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #63996
    apinske
    Participant

    Are there any up-to-date docs for DocTool? This website https://creator.pdf24.org/manual/11/ does not seem to be recent, e.g. it does not mention the parameters shown in the "Upload" template present in the UI:

    • pdf24-docTool.exe -upload -url "URL" -namedFile2 "${file}" "${fileName}" "FIELD_NAME"

    #65238
    PDF24 Support
    Moderator

    Hello,

    https://creator.pdf24.org/manual/11/ is the current manual, but you are right: section 11.1.11 does not yet describe all options of -upload: https://creator.pdf24.org/manual/11/#11111-upload-a-file-via-the-http-protocol

    It is on our to-do list to add them. Until then, here is the complete form:

    pdf24-DocTool.exe -upload -url URL [-header key value] [-appendAppInfo] file1 [file2] ...

    Instead of a plain file you can also write:

    • -namedFile file name: uploads file and sends name as its file name.
    • -namedFile2 file name fieldName: the same, plus the name of the form field for this file.

    How the upload works:

    • All files are sent in one multipart/form-data request to the URL. Without a field name, the fields are called file0, file1, ... in the order of the files.
    • -header key value sets a request header and can be used several times (since version 11.29.0).
    • -appendAppInfo adds a form field appInfo with information about the PDF24 installation (name, version, language and similar).
    • If the response contains a Location header, PDF24 opens this URL in the browser. Otherwise the upload counts as failed and the beginning of the response text is shown as the error message.

    In the "Upload" template of the PDF printer settings (Execute the following command after saving), ${file} is the saved PDF file, ${fileName} is the name of the print job, and you replace URL and FIELD_NAME with the address and the form field name your server expects.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.