Stirling PDF is running.
+ + + """ + .formatted(escapedBaseUrlHtml, escapedBaseUrlJs, serverUrl); + } + + private String buildCallbackHtml() { + String baseUrl = contextPath.endsWith("/") ? contextPath : contextPath + "/"; + + // Escape for HTML attribute context + String escapedBaseUrlHtml = HtmlUtils.htmlEscape(baseUrl); + + // Escape for JavaScript string context + String escapedBaseUrlJs = JavaScriptUtils.javaScriptEscape(baseUrl); + + String serverUrl = "(window.location.origin + '" + escapedBaseUrlJs + "')"; + return """ + + + + +You can close this window and return to Stirling PDF.
+ +