0

How can I make this one line?

<div data-reactroot="">
    <div>
        <div>
            <a href="/home">Home</a>
            <br>
        </div>
    </div>
    <div>
        <div>
            <a href="/about">About</a>
            <br>
        </div>
    </div>
    <div>
        <div>
            <a href="/services">Services</a>
            <br>
        </div>
    </div>
    <div>
        <div>
            <a href="/portfolio">Portfolio</a>
            <br>
        </div>
    </div>
    <div>
        <div>
            <a href="/contact-us">Contact us</a>
            <br>
        </div>
    </div>
</div>
Barry Michael Doyle
  • 9,333
  • 30
  • 83
  • 143

2 Answers2

0

This should put everything into one line:

<div data-reactroot="">
    <a href="/home">Home</a>
    <a href="/about">About</a>
    <a href="/services">Services</a>
    <a href="/portfolio">Portfolio</a>
    <a href="/contact-us">Contact us</a>
</div>

You just need to remove all the <br> tags (which are used for breaking lines) and keep them in the same <div> to override any styles that may be placing them on new line.

Barry Michael Doyle
  • 9,333
  • 30
  • 83
  • 143
0

You used 4 tags that are completely unrelated with the problem. You want do display those links side by side? That's a CSS related issue.

João Vilaça
  • 601
  • 1
  • 6
  • 13