|
An ID *should* be unique within a document. Libraries like jQuery will just grab the first element and ignore the rest if you have multiple with the same ID. If you need to attach the same behavior to multiple elements, just give them a class. An element can have multiple classes, and you need not specify styling in CSS for every class that exists.
|
# ¿ Feb 16, 2015 19:27 |
|
|
# ¿ May 3, 2024 11:57 |
|
use the focus event (onfocus() if you're inlining it) instead of the click event/onclick.
|
# ¿ Aug 10, 2017 01:30 |
|
Thermopyle posted:This is basic stuff, but it's good to be reminded about it every once in awhile: Always ask yourself whether you’re giving a stranger the ability to put hello.jpg on your webpage.
|
# ¿ Mar 2, 2018 19:36 |
|
Tei posted:The current fad is "if is HTTP is not safe" and thats magical thinking. Not everything need to be HTTPS. And not everything is a credit card form. IIRC the current push for HTTPS started when the US government decided it was permissible for ISPs to sniff your web traffic and sell the data to marketers.
|
# ¿ Jan 17, 2019 21:25 |
|
Nolgthorn posted:how is anyone able to maintain that kind of code base without cyanide? In practice you don't maintain it, you make changes by tacking more entries on the end
|
# ¿ Feb 26, 2019 21:16 |
|
Clone into a private repo, then use the original to bring the light of goatman into their lives?
|
# ¿ Mar 4, 2019 01:25 |
|
Never forget that the broken standards and non-intercompatibility were by design, so the extra costs of supporting it (or from Microsoft’s perspective, supporting non-IE browsers) were entirely intentional
|
# ¿ Oct 30, 2019 18:24 |
|
tables were frequently used in the Bad Old Days, as one of the only (or at least easiest) ways to get poo poo to line up properly, so if you're doing HTML archeology or reading old guides you're likely to encounter them used inappropriately.
|
# ¿ Dec 7, 2021 21:41 |
|
|
# ¿ May 3, 2024 11:57 |
|
Last Chance posted:What the hell is the Orion browser about? Never heard of it Kagi (paid web search company) makes it. I thought it was just supposed to be a version of Safari that can run uBlock but a surprising number of things were weird and broken when I hosed around with it for fifteen minutes a couple of months ago
|
# ¿ Apr 19, 2024 20:48 |