Skip to content

Instantly share code, notes, and snippets.

View jonhassall's full-sized avatar

Jonathan Hassall jonhassall

View GitHub Profile
@jonhassall
jonhassall / FullTextSearch.php
Last active January 26, 2024 13:29
Laravel Fulltext Search Trait with Weighting
<?php
namespace App\Traits;
/**
* Fulltext search trait. Requires column to have a FULLTEXT index
* Customizable weighted relevance per column
*
* Add to model:
*
@jonhassall
jonhassall / harvard-phrases.txt
Last active December 10, 2022 23:20
Harvard Phrases raw, unformatted - From "IEEE Recommended Practice for Speech Quality Measurements." IEEE Transactions on Audio and Electroacoustics, Vol. 17, Issue 3, 225-246, 1969. APPENDIX C 1965 Revised List of Phonetically Balanced Sentences (Harvard Sentences). DOI 10.1109/IEEESTD.1969.7405210 (IEEE standard 297-1969) and 10.1109/TAU.1969.…
The birch canoe slid on the smooth planks
Glue the sheet to the dark blue background
It's easy to tell the depth of a well
These days a chicken leg is a rare dish
Rice is often served in round bowls
The juice of lemons makes fine punch
The box was thrown beside the parked truck
The hogs were fed chopped corn and garbage
Four hours of steady work faced us
A large size in stockings is hard to sell
@jonhassall
jonhassall / SQL sorting - Alpha > Numbers > Symbols.sql
Created March 21, 2024 22:45
SQL sorting - Alpha > Numbers > Symbols
SELECT id, title
FROM table
ORDER BY
CASE
WHEN title regexp '^[a-zA-Z]+' THEN
1
WHEN title regexp '^[0-9]+' THEN
2
WHEN title regexp '^[^\w]+' THEN
3
@webdevgen
webdevgen / DigitalOcean Promo Code 2025 | $200 - $400 | 1-Year Valid.md
Last active June 27, 2025 17:03
DigitalOcean Promo Code 2025 / $200 - $400 / 1-Year Valid

DigitalOcean Promo Code 2025 / $200 - $400 / 1-Year Valid

DigitalOcean offers substantial discounts for new users via exclusive promo codes. These codes provide free credits ranging from $10 to $200 to experience DigitalOcean's cloud services.

This guide provides:

  • A list of currently active and latest DigitalOcean promo codes with applicable credit amounts, services, expiry dates and terms.
  • Step-by-step instructions to easily redeem codes as a new user, along with tips to maximize promotional savings.
  • One special offer that will give you free credits that is valid for 1 year.
====
config\cache.php:
====
'file-compressed' => [
'driver' => 'file-compressed',
'path' => storage_path('framework/cache/data'),
'file_chmod' => 0774,
],
====