mvc
HTML5 Drag and Drop file upload with preview using jQuery and MVC 4
With the advent of HTML5 and its wide adoption by all major browsers, web developers now have a new arsenal in their hands for implementing powerful file upload functionality on their website. In this tutorial we will see how to implement this using the FileDrop jQuery plugin and an MVC controller to receive and store [...]
NLog with SQL Server and MVC 4
NLog is an awesome open-source logging tool that allows developers to easily and efficiently implement custom logging. Nlog can be configured to log to a number of targets, but on this tutorial we will be looking at logging to the database. First you need to add NLog to your MVC website. Bring up the Nuget package [...]
jQuery UI Autocomplete with jSON in MVC 4
jQueryUi has an autocomplete plugin that allows developers to turn any standard text box to turn any standard textbox to an autocomplete search box. In this case we will try to implement this in the simplest way possible using a web service as the data source. First of all, create a standard MVC 4 project. [...]
Using an Smtp client in ASP.NET MVC 4 and C#
If you need to send emails from your website, the .NET framework provides a very handy library for this: System.Net.Mail. The configuration and testing is pretty straightforward so let’s get started. Firstly we need to configure the SMTP settings in the web.config. Under the <configuration> element add the following config section:
|
1 2 3 4 5 6 7 8 9 10 |
<system.net> <mailSettings> <!-- Method#1: Send emails over the network --> <smtp deliveryMethod="Network" from="anyemailaddress@test.com"> <network host="your_smpt_server_dns_name" userName="your_smpt_server_username" password="your_smpt_server_password" port="25" /> </smtp> </mailSettings> </system.net> |
The port in [...]



