使用Visual Studio部署ASP.NET网站 [英] Deploying asp.net site with visual studio

查看:88
本文介绍了使用Visual Studio部署ASP.NET网站的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚开始使用VS2008发布网站,而不是直接将代码存储在Web服务器上.我有一个文件夹,其中所有用户上传的文件均为"Static_Files",但是每次发布时,都必须将该文件夹复制回去,因为目录中的所有文件都被删除了.真烦人.发布网站时,有什么方法可以忽略此文件夹,而不将其删除?

非常感谢.

更新:我对VS08中的"​​Web应用程序项目"一无所知,我习惯于仅使用开放网站".我必须对此进行一些研究.

I just started publishing my sites with VS2008 rather than having the code directly on the web servers. I have a folder where all the user-uploaded files are, "Static_Files", but every time I publish it I have to copy that folder back over because all the files are deleted in the directory. It''s really annoying. Is there any way I can have this folder ignored and not deleted when I publish my site?

Thanks much.

Update: I didn''t know about the "web application project" in VS08, I''m used to using simply "Open Web Site". I have to do some research on that.

推荐答案

我不认为您选择了在发布之前删除所有现有文件" "而不是用本地副本替换匹配的文件"?
I don''t suppose you''ve selected ''Delete all existing files prior to publish'' rather than ''Replace matching files with local copies''?


http://forums.asp.net/p/1425906/3181059.aspx#3181059[^]

Short answer is "No". This link has some workarounds for my question.


这篇关于使用Visual Studio部署ASP.NET网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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