Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Is there a way to get rid of the hyperlink from a bullet point but not the text in html?

I want the words from my list to remain hyperlinked but not the bullet points themselves.Or is this something that has to be solved with CSS?

I wrapped each link attribute in an a tag. This changes the color and click-ability of both the bullet point and the text. I only want the words to be a hyperlink.

 <ul>
     <a href="https.random.com" target="_blank"><li>Home</li></a>
     <a href="https.random.com" target="_blank"><li>About</li></a>
     <a href="https.random.com" target="_blank"><li>Contact</li></a>
     <a href="https.random.com" target="_blank"><li>Careers</li></a>

    </ul>

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

It’s easy if you think about it ..
You are using a list element inside a link but you can try using the link inside the list element

<ul>
  <li><a href="https.random.com" target="_blank">Home</a></li>
  <li><a href="https.random.com" target="_blank">About</a></li>
  <li><a href="https.random.com" target="_blank">Contact</a></li>
  <li><a href="https.random.com" target="_blank">Careers</a></li>
</ul>
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading