get selector class all text in javascript code example Example: javascript get all elements by class starting with document.querySelectorAll("[class^=page]")