-1

In the HTML code posted below, how can I make both of the edit text aligned to each other horizontally.

html:

<form action="/action_page.php">
  <label for="originLngLabel">origin Longitude:</label>
  <input type="text" id="originLngTextId" name="originLngText"><br><br>
  <label for="originLatLabel">origin Latitude:</label>
  <input type="text" id="originLatTextId" name="originLatText"><br><br>
  <input type="submit" value="Meaure Distance">
</form>

screen shot: enter image description here

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Amrmsmb
  • 1
  • 27
  • 104
  • 226

1 Answers1

0

Do you mean like this? Remove the br code to make them aligned to each other horizontally.

<form action="/action_page.php">
  <span class="addClassHere" style="margin-right:10px">
     <label for="originLngLabel">origin Longitude:</label>
     <input type="text" id="originLngTextId" name="originLngText">
   </span>
  <span class="addClassHere">
      <label for="originLatLabel">origin Latitude:</label>
      <input type="text" id="originLatTextId" name="originLatText">
  </span>
  <input type="submit" value="Meaure Distance">
</form>
Sprep
  • 528
  • 10
  • 18
  • 1
    yes exactly..but i would like to have some spacing separating origin Latitude label and the edittext to its left..in other words, i would like to add some spaces to the left of origin Latitude – Amrmsmb Mar 29 '21 at 07:39
  • ok cool, I added a style="margin-right:10px" on the span, that adds space to the right of the first block. You can style this better with stylesheets. If this is the correct answer, then hit me up with a correct answer. – Sprep Mar 29 '21 at 07:54
  • hey..maybe this might be a question to you https://stackoverflow.com/questions/66850915/how-set-value-to-input-text-area – Amrmsmb Mar 29 '21 at 08:27
  • page not found?? – Sprep Mar 29 '21 at 08:33
  • 1
    i just figured the answer out – Amrmsmb Mar 29 '21 at 08:37
  • can you please answer this one https://stackoverflow.com/questions/66851458/how-to-initialze-a-variable-of-type-number – Amrmsmb Mar 29 '21 at 09:17