turist_ua

gitex2021-exibitors

Sep 22nd, 2021
621
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var da_nodes = document.getElementsByClassName('exhibitor4-clone');
  2.  var da_people=[];
  3. for(let i = 0; i < da_nodes.length; i++){
  4.       let rows = [
  5. da_nodes[i].getElementsByTagName('h3').item(0),
  6. da_nodes[i].getElementsByTagName('h4').item(0), da_nodes[i].getElementsByTagName('p').item(0), da_nodes[i].getElementsByTagName('small')
  7. ];
  8. company = rows[0] && rows[0].innerText;
  9. department = rows[1] && rows[1].innerText;
  10. desc = rows[2] && rows[2].innerText; rows[4] = '';
  11.  
  12.  console.log(rows[3]); for (let item of rows[3]) { rows[4] += item.innerText + ',';}
  13. person = [company,department, desc, rows[4]];
  14.  
  15. da_people.push(person.join(';'));
  16. }
RAW Paste Data