StealThis .dev
Pages Medium

Ticketing — Checkout

A bold event-ticketing checkout page with a live order summary, seat-tier legend, quantity steppers, and a perforated ticket motif. Apply a promo code for instant discounts, watch the service-fee and facility-charge breakdown recalculate, and race a ten-minute seat-hold countdown. Inline-validated attendee and payment forms format card details as you type, and placing the order reveals an animated success ticket with a generated QR placeholder. Vanilla HTML, CSS, and JavaScript only.

Open in Lab
html css vanilla-js
Targets: JS HTML

Code

Checkout

A high-contrast checkout for the fictional Neon Pulse Festival. A sticky order summary anchors the page with a photographic gradient hero, a low-stock badge, a live event countdown, and a color-coded seat-tier legend. Each order line has a quantity stepper that updates its subtotal, and the totals panel breaks the price into subtotal, optional discount, an 8% service fee, and a flat facility charge — all separated by dashed perforation lines that echo a real ticket stub.

The promo box accepts codes like PULSE15, EARLYBIRD, and FANCLUB, applying a percentage or flat discount and rerunning the math instantly. The attendee and payment fields validate inline on blur, auto-format the card number and expiry as you type, and surface clear error messages. A ten-minute seat-hold timer counts down in the header and turns red in the final minute.

Placing a valid order shows a brief processing state, then an animated success ticket with an order reference, a generated QR placeholder, and the amount paid. Toast notifications confirm each action. Everything runs on vanilla JavaScript with no frameworks or build step.

Illustrative UI only — fictional events, not a real ticketing service.