Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

214
Visualizações
jQuery Ajax File Uploader Widget multi image preview is inverted, last image is first, and first image is last

I use the following jQuery Ajax File Uploader Widget: https://github.com/danielm/uploader As you can see in the demo, the order of previewing the images is reversed.

Demo URL: https://danielmg.org/demo/java-script/uploader/basic

I want to fix this and i don't know how. I don't have very good knowledge of javascript. If anyone is good at Javascript and wants to help me with this issue, I would be grateful.

Thank you! Regards

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I found the solution, in the javascript file ui.js was the following function:

// Creates a new file and add it to our list
function ui_multi_add_file(id, file, file_type) {
var template = $('#files-template-' + file_type).text();
template = template.replace('%%filename%%', file.name);

template = $(template);
template.prop('id', 'uploaderFile' + id);
template.data('file-id', id);

$('#files-' + file_type).find('li.empty').fadeOut(); // remove the 'no files yet'
$('#files-' + file_type).prepend(template);
}

I changed prepend(template) with append(template), and now the uploading filles will show in the correct format.

Thanks anyway, I hope it is useful to other users.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda