Code:
function checkInput() {
  var input1 = document.getElementById("on").value;
  var input = document.getElementById("off").value;
  if (input1 === "on") {
    document.getElementById('reponse').innerHTML = "LED EST ON";
    return false;
  }
  
  if (input === "off") {
    document.getElementById('reponse').innerHTML = "LED EST off";
    return false;
  }
}<form action="url" method="POST">
  Allumer la LED D7 <br>
  <br>
  <input type="radio" name="arg" value="on" id="on">On.
  <br>
  <input type="radio" name="arg" value="off" id="off">Off.
  <br>
  <br>
  <input type="submit" value="OK" onclick="checkInput()">
  <br>
</form>
<p id="reponse"> </p>i want to if i selected On and submitted i get a message "LED EST ON";
and if i selected Off and submitted i get "LED EST Off"
 
     
    