Khan Hafizur Rahman (1) [Avatar] Offline
#1
In page 257, it states that run localhost:4568/iq to show dashboard application. The web application updates automatically.

The relevant code is in file
src/main/java/bbejeck/webserver/InteractiveQueryServer.java
In init method, the following snippet is written :

get("/iq", (req, res) -> {
            res.redirect("interactiveQueriesApplication.html");
            return "";
    });


My questions are:

1. where is the HTML file located?
2. How is the ajax code handled?

Any kind of help is highly appreciated.

Bill Bejeck (44) [Avatar] Offline
#2
Hi,

Thanks for taking the time to ask a question.

The interactiveQueriesApplication.html file is located in the src/main/resources/webserver directory.

The ajax is handled using the jQuery library https://jquery.com/ version 3.2.1

Cheers,
Bill