HOWTO: Find a Physical Path in ASP.Net from URL
In a number of situations, we need to know a Physical Path in a server from URL. For example, we need to upload some photo. Thus, this is a very common task, and is very easy to do in C#
Code
string serverPath = Server.Map("~/Photo"); // e.g. it returns "C:\site\Photo" |
Tags: howto
Trackback address for this post
Trackback URL (right click and copy shortcut/link location)
Feedback awaiting moderation
This post has 3149 feedbacks awaiting moderation...
Form is loading...