Quantcast
Channel: Recent Discussions — DataTables forums
Viewing all articles
Browse latest Browse all 82273

Dynamically altering the SearchPane placeHolder text for all SearchPanes

$
0
0

I need to alter the SearchPane placeholder text, and am doing it like this based on a forum post I found:

    initComplete: function () {
        // Loop through SearchPane inputs to adjust placeholder text to remove HTML.
        $('.dtsp-searchPane').find('input').each(function( index ) {
            var placeholder = $( this ).attr('placeholder');
            $( this ).attr('placeholder', placeholder.replace('<br>',' ').replace('\n',' '))
        });
    }

It works great.

Would be a nice feature option to be able to specify to remove any formatting and only show the text.


Viewing all articles
Browse latest Browse all 82273

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>