removing elements from html with javascript
02:16 16 Dec 2025

java springboot jsp

Preface: complete front-end noob and javascript neophyte.

Goal: if an object is not added to the DOM remove some elements already present

IndexController.java

        boolean isDeleteAddButtons = true;
        if( isDeleteAddButtons ) {
            mv.addObject("this_might_work", true);
        }   

index.jsp ( assume the 3 elements are present and functional)

     ......
     
     
   

What am I doing wrong/not doing right?

javascript