Reply To: newhtml doesn’t work

PennController for IBEX Forums Support newhtml doesn’t work Reply To: newhtml doesn’t work


Hi Jeremy,

I changed my code to the following, and the final page shows up:

    newHtml("completion", "completion.html")

However, the function I created in the HTML file for generating a code does not work (i.e., the code simply doesn’t show up). The same HTML file works as intended in the old Ibex: [“completion”, “Form”, {continueMessage: null, html: { include: “completion.html” } } ].

Below is the content of the HTML file. May I know what caused the problem? Thank you so much!

<!DOCTYPE html>




<h3 id="demo"></h3>


<img src="qrcode.png" width="300" />

function functionName() {
    let alphanum = "0123456789";
    let code2 = "";
    let randChar;
    while (true) {
        for (i = 0; i < 10; i++) {
            randChar = alphanum.charAt(Math.floor(Math.random()*alphanum.length));
            code2 += randChar;
        if (code2.length > 10) {
            code2 = "";
        if (code2 % 11 === 1) {
    return code2;   

document.getElementById("demo").innerHTML = functionName();