John Cox

Blogs · @wyome · Now · Shelf

Tagged tips · everything

Interesting

Super Stripes

This piece describes a practical web design technique for creating reusable stripe patterns using small transparent GIF images layered over different background colors in CSS. By preparing a few basic GIF files with alternating transparent and solid pixels, designers can quickly generate varied striped backgrounds across a website by simply changing the background-color property rather than creating new images for each color variation. The author suggests using this approach to visually distinguish different sections of a website while maintaining a cohesive design theme.

Permalink

Tips for getting to sleep faster & sleeping better

Josh describes his lifelong struggle with racing thoughts that keep him awake for hours despite not having clinical insomnia, then offers six practical remedies he's collected and tested. The advice ranges from avoiding screens thirty minutes before bed (because their light mimics daylight) to drinking milk for its tryptophan content, going to bed only when genuinely tired, reserving the bed primarily for sleep, practicing meditation or progressive muscle relaxation, and exercising during daytime rather than evening.

Permalink

.htaccess tricks and tips.. part one: tasty food for web serving thoughts.

This guide explains how to use .htaccess files—invisible configuration files placed on web servers—to control access permissions, customize error pages, password-protect directories, enable directory browsing, compress output to save bandwidth, and hide sensitive files from direct access. It covers practical directives like Allow/Deny rules, AuthType for password protection, ErrorDocument for custom error pages, and various PHP settings that can be configured at the folder level rather than requiring changes to the main server configuration. The author emphasizes testing changes on a local server first to avoid 500 errors and demonstrates how conditional blocks like `<ifModule>` can safely apply directives only when specific server components are available.

Permalink