Use $('#more-less').text('show more');instead of innerHTML.
jQuery wraps DOM elements in jQuery objects if you want to use a property innerHTML, you can use a function instead .html(), but .text()better since the html is escape content.
An alternative to actually gain access to the property innerHTML, is to get a DOM element of jQuery object, as such: $('#more-less')[0].innerHTML = 'show more';.
source
share