如何在MVC .net的wwwroot图像文件夹中显示图像的幻灯片。 [英] How to display slideshow of images from wwwroot image folder for MVC .net.

查看:92
本文介绍了如何在MVC .net的wwwroot图像文件夹中显示图像的幻灯片。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在MVC .net的wwwroot图像文件夹中显示图像的幻灯片。

每当我在wwroot图像文件夹中上传新图像时,它都会自动添加并在我的幻灯片中显示新图像。

怎么实现呢?我需要使用for循环还是其他什么?

可以提供一些示例或源代码吗?



我尝试了什么:



我知道如何硬编码吗?我只是想自动添加并显示幻灯片的图像

how to display slideshow of images from wwwroot image folder for MVC .net.
Whenever I upload new images in wwroot image folder, it will automatically add and show the new image in my slideshow.
how to achieve that? do I need to use for loop or something else?
can give some example or source code ?

What I have tried:

I know how to hardcoded for it? I just want to automatically add and show the image for the slideshow

推荐答案

使用AJAX调用来显示下一个图像并显示它们。然后它将显示新图像,甚至无需重新加载页面,并且您没有将大量图像传递给客户端。



有一座山世界各地的免费幻灯片控件。
Use AJAX calls to get the next image to show, and to show them. Then it will show new images without even having to reload the page, and you're not passing a big list of images down to the client.

There's a mountain of free slideshow controls in the world.


这篇关于如何在MVC .net的wwwroot图像文件夹中显示图像的幻灯片。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆