Missing icons in TableTools for pages in subdirectories
Missing icons in TableTools for pages in subdirectories
tombrown
Posts: 7Questions: 0Answers: 0
I had an old version of TableTools running with the DataTables on my .NET site and noticed that there was a version 2.0 that was a bit more compact and featured PDF exports, so I decided to upgrade. I did so with no problem on the main page of the site, but there's an issue on sections of the site that are in subfolders: the exporting features work, but the icons do not show up.
To be clear: I can click on the "CSV" button and it exports to a file just fine, but the CSV icon is missing. But only on pages that are in sub-folders of the site.
I felt sure that this must be a CSS issue, so I have gone into the TableTools.css file and messed around with the paths for the image files. No effect.
This seems like such a minor issue but I cannot figure it out!
To be clear: I can click on the "CSV" button and it exports to a file just fine, but the CSV icon is missing. But only on pages that are in sub-folders of the site.
I felt sure that this must be a CSS issue, so I have gone into the TableTools.css file and messed around with the paths for the image files. No effect.
This seems like such a minor issue but I cannot figure it out!
This discussion has been closed.
Replies
In the line:
[code]
if ( this.s.dt.bJUI )
{
buttonDef.sButtonClass += " ui-button ui-state-default";
buttonDef.sButtonClassHover += " ui-button ui-state-default ui-state-hover";
}
[/code]
You have to remove the equal sign (=) because when you apply this class generates an unexpected behavior.
I think that evaluated css would be something like: "DTTT_button_xls = ui-ui-button-default state" and should be "DTTT_button_xls ui ui-button-state-default"
Would be something like:
[code]
if ( this.s.dt.bJUI )
{
buttonDef.sButtonClass + " ui-button ui-state-default";
buttonDef.sButtonClassHover + " ui-button ui-state-default ui-state-hover";
}
[/code]
Sorry for my English.
Ricardo.
It would be convenient to have a possibility to display icons in table tools when using jQuery UI
@braz: There are two options off the top of my head:
1. Use CSS and a suitable selector to give the button a background image
2. Add an IMG tag using the sButtonText property for the button.
Allan