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

99
Views
Agregar cargador hasta que la imagen stl cargue PHP

Estoy usando Stl Viewer Javascript Plugin para mostrar imágenes en 3D en mi sitio web. El tamaño de la imagen STL es de alrededor de 50 MB. Por lo tanto, está tomando mucho tiempo para cargar. Entonces, ¿es factible agregar la imagen del cargador hasta que se cargue la imagen stl?

Estoy usando este complemento, https://www.viewstl.com/plugin/

Por favor, compruebe mi código a continuación,

 <body style="margin:0px;"> <div id="stl_cont" style="width:600px;height:600px;margin:0; background:#ebebeb; overflow: hidden;"></div> <script src="stl_viewer.min.js"></script> <script> var stl_viewer=new StlViewer ( document.getElementById("stl_cont"), { models: [ {filename:"/test/Sienna.stl"} ] } ); </script> </body>

Verifique la captura de pantalla del front-end, ingrese la descripción de la imagen aquí

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Probé el código que pegué a continuación y funciona bien en mi máquina local, verifique y avíseme si también funciona para usted.

PD, reemplace la fuente del elemento de imagen con una URL de gif apropiada para que funcione

 <body style="margin: 0px"> <div id="stl_cont" style=" width: 600px; height: 600px; margin: 0; background: #ebebeb; overflow: hidden; " > <div class="loading" style=" width: 600px; height: 600px; display: flex; align-items: center; justify-content: center; " > <img src="./assets/images/icons8-dots-loading.gif" alt="" /> </div> </div> <script src="stl_viewer.min.js"></script> <script> var stl_viewer = new StlViewer(document.getElementById("stl_cont"), { models: [ { filename: "/test/Sienna.stl" } ], all_loaded_callback: function () { document.querySelector(".loading").remove(); }, } ); </script> </body>

about 4 years ago · Juan Pablo Isaza 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!