Posted by JP on November 30, 2010
Visual Studio really makes it simple for deploying web applications.
In this article we are going to use FTP for deployment.
Hope you have a web application with multiple folders and dozens of file. Selecting each item and uploading to the site is really tedious job. We can simplify it by the following.
You should have the following:
- FTP Server Name
- Username and Password
- Folder on server
Open the solution and right click on the web project and choose the option Publish.
You should see the following dialog window.
Click on the “…” button highlighted against the Target location item.
You will be prompted with the dialog box below.
Enter your Server name, Directory, Username and Password.
Uncheck the Anonymous Login checkbox.
After entering, cilck the Open button. This will close the dialog box.
Now you can click Publish to do the deployment.
Posted in ASP.NET, IIS | Tagged: asp.net, deploy, ftp, guide | Leave a Comment »
Posted by JP on October 30, 2010
Sometimes you might end up with a machine where the ftp tools are not accessible. Here we can use the ftp.exe command line tool along with Windows Operating system.
Type ftp in the windows run command box.
In the appearing command line window type open www.yoursite.com. (I am typing my site named www.fortuneanalyst.com)
It will be prompting for the user name and password.
Type your username and press enter. Wait for 2 seconds and you will be prompted for the password. Type the correct password and press enter. Wait for 2 seconds and if the password is valid you will be getting the message”User * logged in”.
Note: The password typed won’t be displayed on the screen.
If you can see the above message Congratulations!!! You have successfully logged in.
Now we can move to the next step
Type the command dir in the above screen. Wait for 2 seconds. You will be listed with the directories and files in the root folder.
Create a new directory named “fxlogics”. For creating a new directory use command
Copy files to the new directory.
First we have to change the directory to fxlogics. For this type the command
You can ensure you are in the correct directory by entering the dir command again.
Step 8: Upload File
Here you are uploading a file from the local computer to the ftp site’s current directory.
Use command put filepath
Alternatively you can type put and drag and drop the file from explorer to the command window. So the exact path will be shown correctly.
Eg: put c:\readme.txt
Ensure the file is copied correctly by typing the dir command again.
If you can see the file in the command screen you have uploaded the file successfully.
Close the command window by typing the quit command.
||Shows the commands list
||Closes the ftp window
||Displays the directory contents
||Uploads a file from the local file system.
||put “c:\program files\a.txt”
||Deletes the file from the directory
||delete “the file name.exe”
You can use the up and down arrow while in the command window, to traverse between the commands typed. It will save the time and effort to type the command again.
Hope you enjoyed the article 🙂
Posted in C# | Tagged: command, file, ftp, upload | 2 Comments »