DayPilot.Modal.showUrl

The showUrl() method displays the modal dialog and loads the content from the specified URL.

Declaration

DayPilot.Modal.showUrl(url: string): void

Parameters

  • url (string) - content page URL

Notes

The modal dialog content is displayed using an <iframe>. That means the content page runs in a different JavaScript context.

To reach the parent window from the content page, use the parent object. You can also access the DayPilot.Modal instance that opened this dialog using the DayPilot.Modal.opener() method. The content page must include the daypilot-modal.js script to access DayPilot.Modal.

Example

const modal = new DayPilot.Modal({
  onClose: (args) => {
    console.log("result", args.result);
  }
});
modal.showUrl("/edit/123");

See Also

DayPilot.Modal.showHtml()

DayPilot.Modal.opener()

DayPilot.Modal Class

Availability

Availability of this API item in DayPilot editions:

LitePro
DayPilot for JavaScript