ASP.NET MVC

Data Annotation Entity Framework

Source: Mosh Hamedani 1. Table Name [Table(“tbl_Course”, Schema = “”)] public class Course 2. Column Names [Column(“sName”, TypeName=”varchar”)] public string Name {get; set;} 3. Primary Key [Key] DatabaseGenerated(DatabaseGeneratedOption.None)] public string ISBN {get; set;} Lưu ý: DatabaseGeneratedOption có 3 thuộc tính: None, Identity và Computed 4. Composite Keys public class OrderItem { [Key] [Column(Order=1)] public int OrderId… Continue reading Data Annotation Entity Framework

ASP.NET MVC · Uncategorized

Code! MVC 5 App with Facebook, Twitter, LinkedIn and Google OAuth2 Sign-on

Source: https://docs.microsoft.com/en-us/aspnet/mvc/overview/security/create-an-aspnet-mvc-5-app-with-facebook-and-google-oauth2-and-openid-sign-on   Getting Started Start by installing and running Visual Studio Express 2013 for Web or Visual Studio 2013. Install Visual Studio 2013 Update 3 or higher. For help with Dropbox, GitHub, Linkedin, Instagram, buffer, salesforce, STEAM, Stack Exchange, Tripit, twitch, Twitter, Yahoo and more, see this one stop guide.1 Note You must install Visual… Continue reading Code! MVC 5 App with Facebook, Twitter, LinkedIn and Google OAuth2 Sign-on

IT · Uncategorized

Capture Traffic from Another Machine (Any OS)

Set Remote Machine Proxy Settings Start Fiddler on Fiddler server (the machine that will capture the traffic). Click Tools > Fiddler Options. Ensure Allow remote clients to connect is checked. On the other machine, set the proxy settings to the machine name of the Fiddler server at port 8888. Decrypt HTTPS traffic from the Remote… Continue reading Capture Traffic from Another Machine (Any OS)

IT

Hướng dẫn tạo bộ cài macOS Sierra chính thức trên USB

Link : https://applife.vn/21080/huong-dan-tao-bo-cai-macos-sierra-chinh-thuc-tren-usb.html Yêu cầu: Máy Mac hỗ trợ macOS Sierra. (danh sách xem ở đây) 01 thanh USB 8GB trở lên, trống. Tài khoản Apple ID. Đường truyền Internet tốc độ cao để tải bộ cài macOS Sierra. Tiến hành: Bước 1: Tải về bộ cài macOS Sierra Khởi động Mac App Store, sau đó… Continue reading Hướng dẫn tạo bộ cài macOS Sierra chính thức trên USB

Linux

How To Set Up a Firewall with UFW on Ubuntu 14.04

Link : https://www.digitalocean.com/community/tutorials/how-to-set-up-a-firewall-with-ufw-on-ubuntu-14-04 Introduction UFW, or Uncomplicated Firewall, is an interface to iptables that is geared towards simplifying the process of configuring a firewall. While iptables is a solid and flexible tool, it can be difficult for beginners to learn how to use it to properly configure a firewall. If you’re looking to get started securing… Continue reading How To Set Up a Firewall with UFW on Ubuntu 14.04

IT · Linux

Keep chrome extension id same during development

Link: http://stackoverflow.com/questions/23873623/obtaining-chrome-extension-id-for-development The easiest way to get an extension ID is to generate the .pem file and extract the extension ID using the steps described in this answer (read the part below the image). If you want to generate the extension ID with command-line tools only, then look further. I’m going to use OpenSSL because it… Continue reading Keep chrome extension id same during development