A webpage styled with w3.css featuring text without any underline

I am currently using w3.css but I'm facing an issue where some of my hyperlinks have underlines while others do not. My goal is to remove all underlines from the hyperlinks in the content below:

<ul class="w3-ul w3-white">
<a class="" href="./proverb_1.php?answer=yes&answered=20">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Malý trs trávy často převrátí i těžký náklad.</span>
<br></li></a>   
<a class="" href="./proverb_1.php?answer=yes&answered=54">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Ranní ptáče dál doskáče.</span>
<br></li></a>  
<a class="" href="./proverb_1.php?answer=yes&answered=43">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Nejlepší je mluvit pravdu.</span>
<br></li></a>    
</ul>

Answer №1

The reason is that w3.css does not use text-decoration:none for the a tag. To resolve this, you can either create a custom class for the a tag Example (check the a tag class w3.a), or you can utilize css selectors to remove the underline

  ul.w3-ul a{
  text-decoration:none;
  }
  
   
<link rel="stylesheet" href="http://www.w3schools.com/lib/w3.css">
<body>
 <ul class="w3-ul w3-white">
  <a class="" href="./proverb_1.php?answer=yes&answered=20">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Malý trs trávy často převrátí i těžký náklad.</span>
<br></li></a>   
<a class="" href="./proverb_1.php?answer=yes&answered=54">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Ranní ptáče dál doskáče.</span>
<br></li></a>  
<a class="" href="./proverb_1.php?answer=yes&answered=43">
    <li class="w3-hover-yellow w3-white w3-xlarge w3-padding-16 w3-text-black w3-left-align w3-border-top w3-border-bottom"> 
<span class="">Nejlepší je mluvit pravdu.</span>
<br></li></a>    
</ul>
</body>

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

alignment of text output and label that responds to various screensizes

Here is some html code with a label and an output next to it. <div class="panel-body"> <div class="col-sm-6"> <label class="head6">Company Name : </label><span class="head9 halfR"> ...

jQuery does not support iterating over JavaScript objects

Here is the code snippet I am working with: $(obj).each(function(i, prop) { tr.append('<td>'+ i +'</td>' + '<td>'+ prop +'</td>'); }); Intriguingly, the data in $(obj) appears as: Obje ...

Positioning an image so that it is perfectly aligned on top of another image that is centered

http://jsfiddle.net/Weach/1/ The issue at hand involves a background image created using CSS. This image has been center aligned both horizontally and starting from the top, as visible in the provided JSFiddle link. Specifically, there is another image t ...

Autocomplete feature seems to be functioning properly in the online demonstration, while it does not seem

I can see that the autocomplete feature is working in the example provided, but it's not functioning properly in my attempt. What could be causing this issue? <!doctype html> <html lang="en"> <head> <meta charset="utf-8> & ...

Slide the menu off to the right

Check out these images to see my progress: Main Image. When you click on the menu, everything shifts right. I've managed to set up the push menu, toggle switch menu, and main divs. Now I need help with centering the 3 lines that are clicked within th ...

Hierarchy in CSS: The battle between author and user styling

Following a hierarchy of precedence: User agent declarations User normal declarations Author normal declarations Author important declarations User important declarations The CSS specification distinguishes between author and user: Author. The author s ...

BorderWoocommerce

Something odd has appeared around my shopping cart total ("WARENKORB SUMME") today. Could you please take a look at the screenshot below? Any idea how to remove it? This is for a Wordpress/WooCommerce store. I haven't made any recent changes - I su ...

The issue of ngModel not binding to the value of ion-select in Angular Ionic

Having an ion select outside of a form with an ngModel attribute bound to "selectedValue", I encounter an issue where my selections are not being properly populated in the selectedValue variable even though they appear in the ionChange method. The main pur ...

Improving the way text entered in an input box is displayed using HTML table cells

Seeking advice on how to display the last two input boxes in a dynamic HTML table so that users can easily view the data they have entered. The issue arises when the length of the data in these columns is large, making it difficult for users to see all the ...

the best way to transfer a JavaScript value to a PHP page

I am experiencing an issue with an undefined function in my PHP page. I have tried everything and it just doesn't seem to work for me. Can anyone please assist me with this problem? <!DOCTYPE html> <html> <head> <scrip ...

Exploring the Images directory

I hate to admit it, but I'm really struggling with this question. It's frustrating and I've searched everywhere for an answer. Currently, I'm using WAMP on Localhost with PHPstorm. The issue I'm facing is accessing the images di ...

I find it difficult to customize columns in grid template areas

I am having trouble adjusting the width of my header's columns to be 24vw, 24vw, 4vw, 24vw, and 24vw respectively. Despite specifying these widths, the browser is rendering all columns with equal width. Specifically, I am unable to change the width of ...

I need help with importing CSS in Vue.js

When working with the Vue package, I have a need to import a CSS file directly into the index.html file. Currently, the 'index.html' file mounts #app > 'App.vue', which then mounts Todo.vue using the router. Any assistance on how t ...

Troubleshooting: Jquery Toggle Issue When Used with Adjacent Div Element

I've been puzzling over this issue for hours now. The intention of this code is to display a div, but it's just not cooperating. <div id="butbr"> <div id="sup_nav"> <div id="stup" class="bxt1"></div> <div id= ...

Switch the color of the final letter

Sample code snippet: <p class="test">string</p> Looking to dynamically change the color of the last letter, specifically the letter "g", using CSS only, without relying on JavaScript. I am displaying the string character by character and nee ...

Is there a child missing? If so, add a class

I need to add the class span.toggle if the parent element of li does not have a child ul element. click here to view on codepen Snippet of HTML: <html lang="en"> <head> <meta charset="UTF-8> <title>No Title</title>& ...

Unable to retrieve field values from Firestore if they are numeric rather than strings

I need to display this information in a list format: li.setAttribute('data-id', updatesArgument.id);//'id' here unique id Example 1 name.textContent = updatesArgument.data().count;// Works if String Example 2 let i=1; nam ...

Modify the button's background color for Django's image upload field

In one of the forms in my Django application, I have included a field that allows users to upload an image. Here is the code for this field: image = models.ImageField(upload_to=upload_location, null=True, blank=True) To display this field in my form tabl ...

Adding hyperlinks that do not redirect

I have 2 separate divs displayed on a website: <button class="form-control margin btn btn-warning hide_all" id="addLinks">Link Pages</button> <button style="display: none" class="form-control margin btn btn-primary hide_all" id="hideLinks"& ...

Center two elements within a div container both horizontally and vertically

I am trying to vertically center a text and a button within a container. The text should be positioned in the middle of the div, while the button should be aligned to the right. What is the best way to achieve this layout where the text element is centere ...