Skip to content

Instantly share code, notes, and snippets.

@ihor-lev
ihor-lev / sublime_fix_home_end_keys.md
Last active January 22, 2026 16:49
Fix Sublime Text Home and End key usage on Mac OSX

Sublime Text Home/End keys default functionality jumps to the beginning and end of the file.

Fix Home and End keys to move the cursor to the beginning and end of lines.

Preferences > Key Bindings - User

Adding the following to the array:

{ "keys": ["home"], "command": "move_to", "args": {"to": "bol"} },
{ "keys": ["end"], "command": "move_to", "args": {"to": "eol"} },
<?php
$urlUploadImages = '../uploads/img/';
$nameImage = $_POST['nameImage'];
$data = base64_decode($_POST['strBase64']);
$img = imagecreatefromstring($data);
$width = imagesx($img);
$height = imagesy($img);
$image = imagecreatetruecolor($width, $height);
imagealphablending($image, true);
$alpha_image = imagecolorallocatealpha($image, 0, 0, 0, 127);