Skip to content

Instantly share code, notes, and snippets.

View jsanbae's full-sized avatar

Javier Sánchez Baeza jsanbae

View GitHub Profile
@jsanbae
jsanbae / CsrfProtect.php
Last active January 3, 2020 15:48 — forked from luismayta/CsrfProtect.php
CsrfProtect by zend framework
<?php
/**
* A controller plugin for protecting forms from CSRF
*
* Works by looking at the response and adding a hidden element to every
* form, which contains an automatically generated key that is checked
* on the next request against a key stored in the session
*
* @author Jani Hartikainen <firstname at codeutopia net>
*/
@jsanbae
jsanbae / Zend_Mail_InlineImages.php
Created December 18, 2019 17:37 — forked from basvandorst/Zend_Mail_InlineImages.php
Zend_Mail inline images in e-mail: CID attachment (tested in Gmail, Outlook.com, Outlook 2010)
<?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd