Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function extract(content) {
- let textElement = document.getElementById('content').textContent;
- let regex = /\(([^)]+)\)/g;
- ///\([A-Z a-z]+\)/g;
- let arr = [];
- let matches = textElement.match(regex);
- arr.push(matches);
- let result = arr.join('; ')
- return result;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement