# Better Tooltips

**URL:** <https://www.dolibarr.org/forum/t/better-tooltips/17167>\
**Category:** Using my Dolibarr\
**Created:** [December 9, 2018, 10:57am UTC](https://www.dolibarr.org/forum/t/better-tooltips/17167 "2018-12-09T10:57:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aljawaid](https://www.dolibarr.org/forum/user_avatar/www.dolibarr.org/aljawaid/32/388_2.png) [@aljawaid](https://www.dolibarr.org/forum/u/aljawaid)\
**Post date:** [December 9, 2018, 10:57am UTC](https://www.dolibarr.org/forum/t/better-tooltips/17167/1 "2018-12-09T10:57:05Z")

</div>

Better Tooltips

WARNING:  
This information and code is presented to you in good faith. Using parts of this code or file is at your own risk. Amending code your code using the method below will enable the feature only in the current version that you are using. If you upgrade your Dolibarr version, then this code will be automatically erased (and the feature will be removed). Unless the feature below has been included in the core, you would need to apply this code again in your new version. Always backup the files mentioned before manually changing any code.

[tt]Tested on: 7.0.4[/tt]  
[hr]  
What this does  
In recent versions of Dolibarr (maybe from around v6), the tooltips around the interface have removed to a bettter style and design. The suggested code in this post just improves on that and if applied, give you a different look and feel to your interface. This only applies to the default ‘edly’ theme.

Changes from the default tooltips

- Derived from the default tooltip fields with `classfortooltip` css class
- Rounded borders for tooltip and contained images
- Centered contained images
- Slim black thin left bar to simulate tooltip as a badge or band
- Black text, even on links (as links are currently unclickable in the tooltip core)

Examples

![tooltip-contact.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/3/3dedc2deef97b7f033500f2ba863b8cd7cf9cef4.png)

![tooltip-docs.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/3/3bb00ffc61f0f67a355a04a7409cf3743b3133a7.png)

![tooltip-logout.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/9/961ad7ab012dc20d1279b1157ccb94082ef8c35a.png)

![tooltip-print.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/5/556def930839b59354da1d320e656b827d002e1b.png)

![tooltip-product.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/a/aeacbcf7595b38f74fa2d4b1809ac46806a15176.png)

![tooltip-product2.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/b/bcfa7ca74366b319c1eb437e89242e237bffcf59.png)

![tooltip-thirdparty.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/2/2b5592083140c3628b7adb1ede22a3ff89be7311.png)

![tooltip-user.png](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/e/e2e50fbc0b9e7c0ba58a4c5c6c180c8feda754e9.png)

How to do it:

In file:

`
/theme/eldy/style.css.php`

Replace section: [tt](around line 3403)[/tt]

```auto
.mytooltip {
	border-top: solid 1px #BBBBBB;
	border-<?php print $left; ?>: solid 1px #BBBBBB;
	border-<?php print $right; ?>: solid 1px #444444;
	border-bottom: solid 1px #444444;
	padding: 5px 20px;
	border-radius: 0;
	box-shadow: 0 0 4px grey;
	margin: 2px;
	font-stretch: condensed;
```

With:

```auto
/* BLACK TOOLTIP */
.ui-tooltip {
	border-top: solid 1px #000 !important;
	border-left: solid 10px #000 !important;
	border-right: solid 1px #000 !important;
	border-bottom: solid 1px #000 !important;
	padding: 5px 10px !important;
	color: #000 !important;
	border-radius: 3px !important;
	box-shadow: 0 0 3px #000 !important;
	margin: 2px !important;
}
 
/* BLACK TOOLTIP - BLACK TEXT */
.ui-tooltip-content {
	color: #000!important;
	border-radius: 3px !important;
}
 
/* BLACK TOOLTIP - IMAGE */
.ui-tooltip-content img {
	border-radius: 3px !important;
	display: block;
	margin-left: auto;
	margin-right: auto;
}
 
/* BLACK TOOLTIP - LINK IS NOT CLICKABLE SO NO NEED FOR DIFFERENT COLOR */
.ui-tooltip-content a {
	color: #000;
	padding-bottom: 5px;
}
```

Save Changes

1. Save your changes to the file  
[li]Logout first if you’re already logged in ► Close your browser ► Clear your browser cache.
2. Log in again to see the tooltips

---

<div class="post-metadata">

**Author:** ![nazeer](https://www.dolibarr.org/forum/user_avatar/www.dolibarr.org/nazeer/32/37_2.png) [@nazeer](https://www.dolibarr.org/forum/u/nazeer)\
**Post date:** [February 7, 2019, 3:20am UTC](https://www.dolibarr.org/forum/t/better-tooltips/17167/2 "2019-02-07T03:20:33Z")

</div>

How do we hide the account information after user information from the tooltips ?

---

<div class="post-metadata">

**Author:** ![nazeer](https://www.dolibarr.org/forum/user_avatar/www.dolibarr.org/nazeer/32/37_2.png) [@nazeer](https://www.dolibarr.org/forum/u/nazeer)\
**Post date:** [March 31, 2019, 2:23am UTC](https://www.dolibarr.org/forum/t/better-tooltips/17167/3 "2019-03-31T02:23:02Z")

</div>

Not relevant to my question.
