This is more a note to self to remember the steps needed to set up the local repository and doing an initial “push”. Continue reading “Git: Setting Up the Repository and Doing an Initial Commit and Push”
empty($var) is equivalent to !isset($var) || !$var and inherently
!empty($var) is equivalent to isset($var) && $var. Continue reading “PHP: When To Use empty()”
To prevent the blur event to occur when clicking on a button or link, while you were editing text in a HTML5 editable element, add the following code in your script: Continue reading “HTML5: Prevent Blur On contenteditable When Clicking Button/Link”
The aim of this post is to see different methods to wrap a line/border around your element and understand how they affect the element’s dimensions.
I’ll compare three ways of adding a border around an element:
- border and box-sizing:border-box,
- border (in the default box model) and
The native PHP’s mail() fucntion doesn’t allow you to chose the SMTP server of your choice, nor does it support SMTP authentication.
Fortunately, you can use the free PHPMailer email sending library to overcome PHP’s built-in shortcomings. Continue reading “PHP: Send Mail From SMTP Server Authentication Required”
The script below allows you to resize an image while keeping proportions. Continue reading “PHP: Resize Image on Upload | Thumbnail Image Resizing”