有关登录管理员的基本问题 [英] basic question regarding login for admin
问题描述
嗨
我有管理员,我上传包的图片
i需要一些想法如何处理它..
当我选择图片,然后说上传,该怎么办?在服务器和数据库中给出的路径中保存图像...
或保留一段时间或某些时间段,然后当我保存时,它应该上传服务器上的图像并在数据库中保存图像名称...
因为,再次编辑包时,我应该得到该包中的图像列表
pls advice
Hi
I have admin, where i upload images for package
i need some idea how to work on it..
when i select image , and say upload, what it should do ??? save image in path given on server , and in database ...
or keep in some session or something for time period, and then when i save ,it should upload image on server and save image name in database ...
because , when again , edit package, i should get list of images in that package
pls advice
推荐答案
您可以将图像保存在数据库,单独的数据库或文件系统中。将它们放入数据库中的主要功能是,使您的应用程序易于移动(所有数据都在数据库中)并且易于保护(您的代码将图像拉出并可以选择不使用)。
You can save images in your database, in a separate database, or in the file system. The main thing that putting them in the DB helps with, is making your app easy to move ( all the data is in the DB ) and easy to secure (your code pulls the images out and can choose not to).
或保留一段时间或某段时间,以及然后当我保存时,它应该在服务器上传图像并将图像名称保存在数据库中...
or keep in some session or something for time period, and then when i save ,it should upload image on server and save image name in database ...
我不知道你的意思,但是听起来很蠢。永久存储图像,而不是暂时存储你的建议只会让事情变得更难。
I have no idea what you mean here, but it sounds dumb. Store images permanently, not temporarily. What you're suggesting only makes things harder.
因为,再次,编辑包,我应该得到该包中的图像列表
because , when again , edit package, i should get list of images in that package
这意味着,无论图像是什么,数据库需要了解它们(通过存储细节,无论实际图像是否在数据库中)
Which means that, where-ever the images are, the database needs to know about them ( by storing details, no matter if the actual image is in the DB or not )
这篇关于有关登录管理员的基本问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!