Using trim() function in jQuery

jQuery also have trim function like javascript trim, which removes spaces from starting and from end of the string. See below code.
<script type="text/javascript">
    var str = "    I Love jQuery    ";
    str = jQuery.trim(str);

Output of this would be "I Love jQuery". trim function only removes spaces from starting and end of the string. If there are any space between middle of the statement that is ignored.

Feel free to contact me for any help related to jQuery, I will gladly help you.

Nothing shocks me, I'm a Software Engineer. And I am not young enough to know everything. I live in World Wide Web and from there take care of this website. This website communicates about my work, learning and experience. I believe life is short, and it is for loving, sharing, learning and connecting. So lets connect..