KW Online Tools Zone
Knowledge Walls
View All Tools Home
HOW TO PUT DOTS AT DIV END IF IT HAS MORE CHARACTERS USING JQUERY
[Jquery editor]
Run
Share Link
Clear
HTML [Ctrl+Enter] - to run
How to find difference between java and java Fx using Highflyer technology.
CSS [Ctrl+Enter] - to run
Jquery [Ctrl+Enter] - to run
$(function(){ $.each($(".sline_wc"),function(){ var SplitedData = $(this).attr("class").split(" "); for (var dataIndex in SplitedData){ if (SplitedData[dataIndex].startsWith("sline_wc_")){ $(this).css({"overflow":"hidden", "width":parseInt(SplitedData[dataIndex].substring(SplitedData[dataIndex].lastIndexOf("_")+1,SplitedData[dataIndex].length))+40, "white-space":"nowrap", "position":"relative"}); $(this).append('
(..)
'); } } }); });
OUTPUT
Copyright © 2021 Knowledge walls, All rights reserved
Copyright © 2021 Knowledge walls, All rights reserved