如何重新运行已从数据库回显的轮播(materialize-css)。

时间:2018-02-22 02:26:53

标签: javascript php jquery css carousel

我试图保存&检索一个内置旋转木马的html div,但当我尝试存储它的内部(使用JavaScript .html()函数)时,这就是存储的内容...



<div id="panel1">
  <div id="div1" style="width: 100%; height: 100%;">
    <div id="div1_resize" class="div1 carousel carousel-slider initialized" data-namespace="DIVdiv1_resizediv1carouselcarousel-slider0" style="height: 100px; display: none;">
      <a class="carousel-item active" style="z-index: 0; opacity: 1; display: block; transform: translateX(0px) translateX(0px) translateX(0px) translateZ(0px);">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture1.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
      <a class="carousel-item" style="transform: translateX(0px) translateX(-100px) translateZ(0px); z-index: -1; opacity: 1; display: block;">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture2.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
    </div>
    <div id="div1_resize" class="div1 carousel carousel-slider initialized" data-namespace="DIVdiv1_resizediv1carouselcarousel-sliderinitialized1" style="height: 100px; display: none;">
      <a class="carousel-item" style="z-index: -1; opacity: 1; display: block; transform: translateX(0px) translateX(-100px) translateZ(0px);">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture1.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
      <a class="carousel-item active" style="transform: translateX(0px) translateX(0px) translateX(0px) translateZ(0px); z-index: 0; opacity: 1; display: block;">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture2.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
    </div>
    <div id="div1_resize" class="div1 carousel carousel-slider initialized" data-namespace="DIVdiv1_resizediv1carouselcarousel-sliderinitialized2" style="height: 400px;">
      <a class="carousel-item active" style="z-index: 0; opacity: 1; display: block; transform: translateX(0px) translateX(0px) translateX(0px) translateZ(0px);">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture1.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
      <a class="carousel-item" style="transform: translateX(0px) translateX(-103.344px) translateZ(0px); z-index: -1; opacity: 1; display: block;">
        <div style="background: url(http://172.20.1.23/dmb/public/img/picture2.jpg); background-size: 100% 100%;" class="slider-size2">
        </div>
      </a>
    </div>
  </div>
</div>
&#13;
&#13;
&#13;

当我试图回应它时,它只显示第一张图像而不是旋转木马,即使它是作为旋转木马类回应

&#13;
&#13;
<?php
echo htmlspecialchars_decode($temp_row->html);
?>
&#13;
&#13;
&#13;

有没有办法在回旋后重新运行旋转木马?

0 个答案:

没有答案