Website security must be thought about while building every level of the web stack. However, this section is included for topics that deserve particular treatment, such as Cross-site scripting (XSS), SQL injection, Cross-site request forgery and usage of public-private keypairs.
How HTTPS Secures Connections: What Every Web Dev Should Know
The Open Web Application Security Project (OWASP) has cheat sheets for security topics.