John Cox

Blogs · @wyome · Now · Shelf

Interesting

Mobiscroll - The customizable date and time picker for touch devices

Mobiscroll's landing page pitches a toolkit for building scheduling products, split into two offerings: Mobiscroll UI, a set of components for calendars, schedulers, timelines, agendas, pickers, and resource planning views, and Mobiscroll Connect, a single integration for syncing with supported calendar providers. The saved text is marketing copy with no technical argument or comparison, so it doesn't say which tool suits which workflow beyond inviting you to contact sales. The only concrete details are a "latest version" notice of v5.0.0 (listed as released three years ago, suggesting the page is dated or stale) and a $50 referral offer.

Permalink

My first API: Google Weather. Thoughts? : PHP

This is a code-review thread on a small PHP wrapper around the Google Weather API. The reviewer argues that a library like this should stay out of view logic: getWeather() should require a location rather than default to one, setIcons() and displayError() should go, and failures should return false so the calling controller picks the error view. Developers can build icon paths themselves from the returned condition value. The author adopts those changes, and a later commenter suggests PHP namespaces and PSR-0 autoloading in place of the underscore-style class name. The author also settles on suppressing simplexml_load_file() errors and returning false on a bad response.

Permalink

Welcome to Betterment - The smart, simple way to invest

What was saved appears to be only the legal footer from a Betterment.com page, with no article body. It holds disclosures on FDIC insurance limits for the Cash Reserve sweep program (up to $4M individual, $8M joint across program banks), the split of advisory, brokerage, checking and 401(k) services among Betterment's entities, and the usual investment-risk and market-data notices. It also cites company stats (over $70B in assets under management, 1M+ customers) and a national average savings APY benchmark, but nothing here shows what the original piece argued, so it's worth re-opening the link or finding another copy to recover the content.

Permalink

What does "size" in int(size) of MySQL mean? » alexander kirk » Blog Archive

The number in MySQL integer types like int(11) or tinyint(1) is only a display width, not a storage size in bits or bytes, and it doesn't limit the values you can store. The post shows this by putting 100 into a tinyint(1) and 10000 into an int(4) without truncation, and the width only has a visible effect when ZEROFILL is set, which pads shorter values with leading zeros (handy for invoice IDs). The author works this out from the vague manual entries and backs it up with a series of ALTER TABLE experiments that change the width and watch the output.

Permalink

Lazy Load Plugin for jQuery

Documentation for a vanilla JavaScript rewrite of the Lazy Load plugin, which postpones loading of off-screen images until the user scrolls near them. It uses the Intersection Observer API instead of scroll handlers. Images take their full-size URL from `data-src`, with an optional low-res `src` placeholder. It can be initialized through a factory function or constructor, and the observer options (root, rootMargin, threshold) can be passed in. Extra methods (`loadimages()`, `destroy()`, `loadAndDestroy()`) are available on the instance, and a jQuery wrapper using `data-original` serves as a drop-in replacement for the old version. The cookbook covers blur-up placeholders, responsive images via `data-srcset`, and inlined data-URI placeholders. The release is still a beta (2.0.0-rc.2) installable via npm or yarn, under the MIT license.

Permalink

5 Ways to Boost MySQL Scalability

A practical checklist of five fixes for MySQL scaling problems, drawn from recurring client issues: tune slow queries (slow query log, Maatkit's mk-query-digest, EXPLAIN, missing indexes), use master-master replication so a read-only slave absorbs the roughly 80% read traffic, and size the memory buffers properly (InnoDB buffer pool, key buffer, log and sort buffers). It also advises using RAID 10 rather than RAID5 for disk I/O, with striped EBS volumes on EC2, and setting a few key parameters such as innodb_flush_log_at_trx_commit=2 and innodb_file_per_table. Worth keeping for the concrete parameter list and the caveats, like replication drifting silently and needing checksums, though the advice is dated (query cache, MyISAM, Maatkit) and the FAQ section is thin filler.

Permalink

Untitled (http://mashable.com/2012/07/26/mountain-lion-clean-install/)

A 2012 how-to for doing a clean install of OS X Mountain Lion rather than the standard Mac App Store upgrade, by creating a bootable DVD or USB installer. The steps match the previous year's Lion guide, except that the downloaded DMG must be mounted before it is restored to a USB stick in Disk Utility. It also points to easier alternatives: the free Lion DiskMaker app, and Apple's forthcoming Recovery Disk Assistant, which could also restore from a Time Machine backup. A note at the top says it is outdated and links to a newer Mavericks clean-install guide.

Permalink

What is Anemometer? · box/Anemometer Wiki · GitHub

Anemometer is a web front end for exploring MySQL slow query log data, which it gets by having Percona Toolkit's pt-query-digest parse the logs into a database. It graphs aggregate stats over time with click-and-drag zoom, and offers customizable report tables for ranking the worst queries by time, index efficiency, temp table use and so on. It can pull from many servers at once, supports separate datasources such as production versus development, and uses HTTP GET for every form so graphs and reports can be shared as links. Installation is covered by a quickstart in the project README, with side pages on extra features and on using Performance Schema in MySQL 5.6.

Permalink

Adjacency list vs. nested sets: MySQL | EXPLAIN EXTENDED

Closing the series comparing adjacency lists with nested sets, this installment covers MySQL, which lacks recursive CTEs and CONNECT BY, so adjacency-list traversal must be emulated with session variables and custom functions. Its distinguishing advantage is SPATIAL (R-Tree) indexes on MyISAM tables: by storing each (lft, rgt) pair as a bounding box and querying with MBRWithin, the slow "find all ancestors" nested-sets query drops to about 15 ms on a 2.4-million-row tree, versus 600 ms for the adjacency list, while descendants (300 ms vs 7 s) also favor nested sets. The adjacency list still wins for descendants up to a given level, and the author concludes nested sets (with a stored level column) is worth choosing in MySQL only if updates are rare and locking the table for minutes is acceptable, since R-Tree maintenance is slow and MyISAM locks the whole table.

Permalink

FrameWarp – jQuery plugin for displaying pages in a neat overlay | Tutorialzine

This tutorial builds FrameWarp, a small jQuery plugin that opens a page in an iframe overlay styled as a dialog rather than a lightbox. Clicking a link or button makes a polygon grow from that element toward the window center, using jQuery++ to turn `animate()` into CSS3 transitions with a JavaScript fallback. The trick is animating border widths while the height stays at 0. For same-origin pages, the plugin injects `hide` and `sendMessage` methods into the iframe so the page can close itself or message the parent, and it can cache loaded iframes for faster reopening. The post walks through the full code, including the origin-check helpers, the default settings, and example usage on a demo page.

Permalink

Postgres.app | the easiest way to run PostgreSQL on the Mac

Postgres.app's homepage presents it as a self-contained PostgreSQL server for the Mac, bundled with PostGIS, the command line tools and headers, and automatic minor updates. Setup means dragging it to Applications and clicking "Initialize", which gives a passwordless localhost server on port 5432 using your system username. The bulk of the page is a reference of connection snippets for PHP, Go, Python (Django, Flask, SQLAlchemy), Ruby (Rails and others), Java, C and Swift, along with a comparison of the graphical clients pgAdmin 4 and Postico (made by the same maintainers) and pointers to troubleshooting and GitHub issues.

Permalink

Evening Edition | The perfect commute-sized way to catch up on the day’s news

This isn't an article. It's a block of machine-generated, nonsensical sentences pairing random names with US states and Indian regions, seeded with Korean keywords for online casinos, sports betting, and social media sites. It looks like SEO spam meant to push gambling links, and it makes no argument and reports nothing. If you saved it on purpose, the original page was probably something else, so it's worth checking the source.

Permalink