JSON API - addHtml

addHtml

PREMIUM TRIAL / ADVANCED

Inserts HTML and CSS into the PowerPoint presentation.

Note

You are reading the JSON API documentation. For the PHP API method please go to addHtml.

JSON data
Key Description
html HTML and CSS content to be transformed.
placeholder

The content is added in a placeholder of the layout. One of the following options can be used to get the text box.

  • "name" name.
  • "descr" alt text (descr) value.
  • "position" position by order. 0 is the first order position.
  • "type" title (Title), body (Body), ctrTitle (Centered Title), subTitle (Subtitle).
new

A new position is generated.

  • "coordinateX" EMUs (English Metric Unit).
  • "coordinateY" EMUs (English Metric Unit).
  • "sizeX" EMUs (English Metric Unit).
  • "sizeY" EMUs (English Metric Unit).
  • "name" internal name. If not set, a random name is generated.
  • "order" set the display order. Default after existing contents. 0 is the first order position. If the order position doesn't exist add after existing contents.
  • "textBoxStyles" See addTextBox for text box styles.
disableWrapValue If true disable using a wrap value with Tidy to prevent extra blank spaces. Default as false.
forceNotTidy Default as false. If true, avoid using Tidy. Only recommended if Tidy can't be installed.
insertMode

Insert mode if the position contains an existing content:

  • append
  • replace

Default as append.

parseCSSVars If true parses CSS variables.
useHtmlExtended If true allows using HTML Extended tags. Default as false. Only available in Premium licenses.
Code samples

Example #1

Release notes
  • phppptx 5.0:
    • new action.