Skip to content

Instantly share code, notes, and snippets.

View gtnsimon's full-sized avatar

Gaëtan SIMON gtnsimon

View GitHub Profile
@gtnsimon
gtnsimon / mat-icon-button_overlay-on-hover.css
Created September 10, 2018 22:02
Material Angular cheatsheet: mat-icon-button with background-color on hover
/*
<button mat-icon-button>
<mat-icon aria-label="Close main menu">close</mat-icon>
</button>
*/
/*
By default the opacity for the overlay focus is set to 0,
but it could be nice for the user to have a feedback when his mouse is hover the button.
*/
@gtnsimon
gtnsimon / doctrine_validator_swagger.md
Last active February 26, 2024 12:14
Doctrine ORM + Symfony Validator + Swagger-PHP annotations living together 🙌❤

This solve Exceptions below :

  • Doctrine\Common\Annotations\AnnotationException : [Semantical Error] The annotation "..." in property Class::$property does not exist, or could not be auto-loaded.
  • Doctrine\ORM\Mapping\MappingException : Class "..." is not a valid entity or mapped super class.

Packages

@gtnsimon
gtnsimon / ldap_escape.php
Last active June 20, 2016 15:54 — forked from egulhan/ldap_escape.php
ldap_escape() function
/**
* function ldap_escape
* @source http://stackoverflow.com/questions/8560874/php-ldap-add-function-to-escape-ldap-special-characters-in-dn-syntax#answer-8561604
* @author Chris Wright
* @version 2.0
* @param string $subject The subject string
* @param bool $dn Treat subject as a DN if TRUE
* @param string|array $ignore Set of characters to leave untouched
* @return string The escaped string
*/