The persistent underline on the tooltip just won't go away

Hey there, this is my first time posting a question here so I hope I got everything right!

I'm currently in the process of creating a form for a WordPress site using Bootstrap. I need to incorporate tooltips with Font Awesome icons, but for some reason, I can't seem to remove the underline from the tooltip.

Check out this image of the tooltip with the underline

Here's a snippet of the code:

<label for="name"><a data-toggle="tooltip" data-placement="bottom" title="Placeholder"><i class='far fa-question-circle'></i></a>Name:</label>

And here are some CSS snippets:

label a i {
  color: blue !important;
}

a:hover, a:visited, a:link, a:active
{
    text-decoration: none !important;
}

Additionally, here's the JavaScript used:

// Document loaded function
jQuery(document).ready(function(){
  jQuery('[data-toggle="tooltip"]').tooltip();
  jQuery('.fa-question-circle').hover(function() {
    jQuery(this).removeClass( 'far' ).addClass( 'fas' );
  }, function() {
    jQuery(this).removeClass( 'fas' ).addClass( 'far' );
  });
});

I've tried various solutions to no avail. Any help would be much appreciated!

Update: Turns out there was a border-bottom: 1px; being added by the blank theme I'm using (I'm working on a plugin). Even though border:0!important; didn't work, adding

border-bottom: 0px solid !important;
solved the issue.

Answer №1

After some investigation, I discovered that the blank theme I am using for my plugin was unexpectedly adding a border-bottom: 1px;. Despite trying border:0!important;, it didn't resolve the issue. However, when I added

border-bottom: 0px solid !important;
, the problem was finally fixed.

Answer №2

In my opinion, the text underline is specifically targeted at the a elements, therefore by using this CSS snippet you can effectively get rid of it:

label a {
   text-decoration: none !important;
}

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

Trouble with applying CSS class to checkboxlist

I am trying to display a border around each checkbox item in a checkboxlist. I believe that it can be achieved by setting the td cssclass as the checkboxlist saves items in td. However, the code I tried below is not working. Here is the ASPX code: < ...

Finding an element that lacks both a class and an id, and is not consistently present - what's the trick?

Currently, I am faced with a predicament in my code where a <li> element only appears under specific conditions, making it difficult to apply positioning. This element lacks an id and class attribute, which prevents me from targeting it accurately us ...

What is the best way to utilize MUI breakpoints for displaying images based on different screen sizes?

I need help displaying an image based on the screen size using MUI breakpoints. I'm struggling to understand how to implement this with MUI. Can someone assist me with the breakpoints? interface EmptyStateProps { title: string; description: string ...

When the user clicks on the body, I want the element to slide up, which will then slide down when the button is clicked

As a novice in Jquery, I am currently implementing a simple slide toggle on a button. Initially, the div is set to display none, and when the button is clicked, the slide toggle function is triggered. This works well. However, I also want the div to slide ...

Is it possible to extract a user's password from the WordPress database for use in a React application

Is it feasible to create a React application integrated with Postgres within Wordpress that operates on MySql? I am interested in leveraging Wordpress's built-in features for theming, posts, and user management accounts. However, I am unsure if I can ...

The slidedown feature is not functioning as initially planned

As a beginner in HTML, jQuery, and CSS, I am attempting to create a navigation bar that will trigger a jQuery slidedown effect when clicked. Unfortunately, my current code is not producing the desired outcome. Below is a snippet of what I have implemente ...

Simple Guide to Inserting Items in a Column with Flexbox and Material UI

I've been struggling to position these items on the modal and could use some advice. I'm aiming to include the item counter as text and stars below it, with the unassigned text at the bottom. Despite trying various layouts, I can't seem to g ...

Experience the magic of playing HTML5 video within the sleek confines of an iPhone image

After coming across a similar inquiry on Stack Overflow (), I decided to create my own solution since the original answer lacked code details. The task at hand is to embed an HTML5 video within an iPhone image frame, like so: The image dimensions are 300 ...

What is the reason for the disparity between CSS box-sizing content-box and border-box?

Consider the following example where I only changed the CSS box-sizing property from content-box to border-box. The resulting output difference is significant. Give this code a try: .box1 { width: 300px; height: 100px; border: 1px solid blue; pa ...

The footer is being covered by the section, despite my attempts to address the issue with

I have noticed a section overlapping issue and I am struggling to figure out the cause. I have attempted using margins and padding to adjust the footer with my .div-wrap, but so far it has not been effective. After searching around, I am still uncertain ...

How tall can an image be to load successfully on an iPad website?

Similar Query: Max image width in Mobile Safari? Dealing with unwanted downscaling on panoramas What is the maximum height an image can be loaded at on a website when viewed on an iPad? I've tried loading an image (a sprite) with a height exceeding ...

Presentation and selection list

Here is the CSS code I am using: .nav li a { background-color:#000; color:#fff; text-decoration:none; padding:10px 15px; display:block; } .nav > li { float:left; } .nav li a:hover { background-color:#4db4fa; } .nav li ul { ...

Issue with z-index not applying to a fixed header

I've been attempting to recreate the problem using this plunker. .demo-blog.mdl-layout .mdl-layout__content { padding-top: 0px; position: relative; margin-top: -80px; z-index: 100; } header.main-header{ z-index: -50; } My goal is ...

What is the best way to add multiple classes to an HTML element?

Can a single HTML container have more than one class assigned to it? For example, would the following code work: <article class="column wrapper"> ...

Chrome browser rendering image as PHP/CSS/HTML web navigation bar

I've hit a snag while working on my small website. The navigation of the website is functioning properly in Internet Explorer, but in Google Chrome, it's not clickable. Initially, I thought the issue might be related to the background image of ...

Set the height of a div based on the height of another div

My challenge involves a textarea that dynamically expands as content is added to it. The structure of the textarea within a div element is illustrated below: <div id='sendMes' class='container-fluid'> <form action='#&apos ...

How can I update my outdated manifest v2 code to manifest v3 for my Google Chrome Extension?

Currently, I am developing an extension and using a template from a previous YouTube video that is based on manifest v2. However, I am implementing manifest v3 in my extension. Can anyone guide me on how to update this specific piece of code? "backgro ...

Arrange elements both at the beginning and the end of a line using FlexLayout in Angular

Using the Angular flexlayout library in angular 7/8, I am trying to align 4 buttons on the left side (flex-start) and two checkboxes on the right side (flex-end) at the same level. I would prefer to achieve this layout using the flexlayout Angular library. ...

Is there a way to detect the completion of the fadeout animation before calling a function?

I am trying to create a toast message using jQuery. When the "show" class is appended to the div, I want the toast message to fade in and then fade out after a few seconds. Once the fade-out animation is complete, I need to remove the "show" class. This ...

Issue encountered when displaying error messages during validation with Laravel version 5.8

Why is the error message not displaying with this code? Although I can see the error message in the page source code. @if($errors->has('slug')) <span class="invalid-feedback" role="alert"> <strong>{{ $errors->first('slu ...