Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

256
Views
How I pass an array of image from js file to HTML?

In this function I have in input an array of images(link of the img on google) and I want to show the image in my HTML code, in var fullLink I have the link to HTML page. Any suggestions?

My JS function:

function showImageContributors(data) {
    var url = "chrome-extension://paiocjmlmleigfefjijbaglphlbgfcdo/src/browser_action/contribuenti.html";
    var nameRepo = window.location.hash;
    var fullLink = url+nameRepo;
    
    document.getElementById("imageCollaborators").appendChild(() => data.map((image) => <img src='${data}' />));
  }

My HTML where the images have to be shown:

<div class="col-lg-4 ms-auto">
  <div id="imageCollaborators" class="imageCollaborators"><img id="image" src="" class="image" /></div>
</div>
about 4 years ago · Santiago Gelvez
1 answers
Answer question

0

You can do something like

function showImageContributors(contributors) {
  var data = [];
  var link = "chrome-extension://paiocjmlmleigfefjijbaglphlbgfcdo/src/browser_action/contribuenti.html/";
  contributors.forEach(c => {
    data.push(c.image);

    $.getJSON(link + $.param(data), function(res) {});
  });

  pimage.remove();
  document.getElementById("imageCollaborators").appendChild(() => contributors.map((contributor) => <img src=`${contributor.image}` />);

}
about 4 years ago · Santiago Gelvez Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!