Ninja_1 15 Newbie Poster

How can I show a div when menu item is clicked in angular?

The Div show fine when I click list item, but dsn't disappear when I navigate to other menu items.

  • Slots TOP NEW TS file: showme : boolean = false;
  • rproffitt commented: Please format your code in a code block so it can show in the forum. +15
    Ninja_1 15 Newbie Poster

    I need assistance in storing checkbox API values. I have multiple checkboxes and I can display API values in html when checkbox is checked. But how do I store the initial value of a checked checkbox and show it in a span?

    I currently get “on” value instead of API initial value.

    eg. The value I want is “Faculty Lecture” as stored in the API

    Ninja_1 15 Newbie Poster

    I need assistance in storing checkbox API values. I have multiple checkboxes and I can display API values in html when checkbox is checked. But how do I store the initial value of a checked checkbox and show it in a span?

    I currently get “on” value instead of API initial value instead of "on" value.

    eg. The value I want is “Breakfast Event” as stored in the API

    Below is my code:

    <input type="checkbox" id="myCheck1" name="checks" class="round">
    <span id="eventTitle" class="results"></span>
    
    //store checkbox values
     $('#myCheck1').on('change', function() {
        $('.results').html(this.checked ? this.value : '');
    });