I have made a jssor slider in my project it is working perfectly. I have decide to add database to my project and i want to save image address to database so i can i just add images to slider.
1.My question is it possible to dynamic images to jssor slider?
2.What i want is from database i will get all images and i will do a foreach to show images
this is how i do the code
<div u="slides" style="cursor: move; position: absolute; left: 0px; top: 0px; width: 720px; height: 480px;
overflow: hidden;">
<?php
foreach (LoadImageGallery() as $value){
echo $value['searchresultbigimg'];
echo "<li><img src=\"admin/".$value['searchresultbigimg']."\"></li>";
echo $value['searchresultthumbnailimg'];
echo "<li><img src=\"admin/".$value['searchresultthumbnailimg']."\"></li>";
}
?>
</div>
UPDATE
i get this error when i tried your solution sir jssor this is what i tried
Slides html code definition error, there must be at least 1 slide to initialize a slider.
<div u="slides" style="cursor: move; position: absolute; left: 0px; top: 0px; width: 600px; height: 300px; overflow: hidden;">
<?php
foreach (LoadImageGallery() as $value){
echo $value['searchresultbigimg'];
echo "<div><img src=\"admin/".$value['searchresultbigimg']."\"></div>";
echo $value['searchresultthumbnailimg'];
echo "<div><img src=\"admin/".$value['searchresultthumbnailimg']."\"></div>";
}
?>
</div>
I think you want something like this. I found the basic code for the array here http://www.the-art-of-web.com/php/directory-list-spl/
Yes, you can and you are on your way.
But you should use 'DIV' instead of 'LI'.
Jssor Slider slide html code is as below,
Reference http://www.jssor.com/development/define-slides-html-code.html