how to delete (or hide) characters in a string, for example: I have string with 20 characters and I need to delete all characters from 15. P.S. I got one idea, but don't think that its correct: create two paragraphs with different classes, one paragraph with 15 characters, second one doesn't matter and delete/hide second paragraph example:
    var count;
    count = $('#mydiv').text().length;
    if (count => 15) { 
    }
 
     
     
     
     
     
    