Html codes
184 subscribers
111 photos
15 videos
226 files
197 links
👋 Welcome to Html Codee
🚀 Here you’ll find mini tools, code snippets, and web tricks to grow fast.
🧩 Built with HTML, PHP, and smart ideas.
💌 Support: support@bestpage.x10.mx
🏁 If you don't walk today, run tomorrow.
Download Telegram
<picture> — Responsive image loading
<source> — Define media file formats
<dialog> — Create modal dialogs
<template> — Hidden HTML templates
<slot> — Insert custom content in Web Components
<main> — Marks the main content area
<mark> — Highlight text
<time> — Define a date or time
<meter> — Display scalar values (e.g. score)
<progress> — Show task progress (e.g. loading)
<output> — Display calculation results
<details> — Expandable/collapsible content
<summary> — Header for <details>
<figure> — Container for images or diagrams
<figcaption> — Caption for a <figure>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Avatar Animation</title>
<style>
body {
margin: 0;
padding: 0;
background: #0f0f0f;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
font-family: 'Segoe UI', sans-serif;
}

.coder-avatar {
position: relative;
width: 180px;
height: 180px;
border-radius: 50%;
overflow: hidden;
box-shadow: 0 0 25px rgba(0, 255, 170, 0.5);
cursor: pointer;
}

.coder-avatar img {
width: 100%;
height: 100%;
object-fit: cover;
border-radius: 50%;
z-index: 2;
position: relative;
transition: transform 0.5s ease;
}

.coder-avatar:hover img {
transform: scale(1.05);
}

.coder-avatar::before {
content: '';
position: absolute;
top: -25%;
left: -25%;
width: 150%;
height: 150%;
background: conic-gradient(
from 0deg,
#00ffcc,
#0066ff,
#00ffcc
);
animation: spin 5s linear infinite;
z-index: 0;
border-radius: 50%;
filter: blur(10px);
}

.coder-avatar::after {
content: '';
position: absolute;
top: 10px;
left: 10px;
right: 10px;
bottom: 10px;
background: #0f0f0f;
border-radius: 50%;
z-index: 1;
}

@keyframes spin {
0% {
transform: rotate(0deg);
}
100% {
transform: rotate(360deg);
}
}
</style>
</head>
<body>

<div class="coder-avatar">
<img src="https://i.pravatar.cc/300?img=12" alt="programmer">
</div>

</body>
</html>
<!DOCTYPE html>
<html>
<head>
<title>Ably Real-Time Chat</title>
<script src="https://cdn.ably.io/lib/ably.min-1.js"></script>
<style>
body {
font-family: Arial, sans-serif;
padding: 20px;
}
#messages {
border: 1px solid #ccc;
padding: 10px;
height: 300px;
overflow-y: scroll;
margin-bottom: 10px;
}
input, button {
padding: 10px;
font-size: 16px;
}
</style>
</head>
<body>
<h2>💬 Ably Real-Time Chat</h2>
<div id="messages"></div>
<input type="text" id="msgInput" placeholder="Write a message..." />
<button onclick="sendMessage()">Send</button>

<script>
const ably = new Ably.Realtime('key');
const channel = ably.channels.get('chat');

channel.subscribe('message', function(msg) {
const p = document.createElement('p');
p.textContent = msg.data;
document.getElementById('messages').appendChild(p);
document.getElementById('messages').scrollTop = document.getElementById('messages').scrollHeight;
});

function sendMessage() {
const input = document.getElementById('msgInput');
const message = input.value.trim();
if (message) {
channel.publish('message', message);
input.value = '';
}
}
</script>
</body>
</html>
New style qr code
Today's Code Tip

Add a stunning 3D glowing button to your portfolio or website with this CSS snippet:

<button class="glow-btn">Click me</button>

<style>
.glow-btn {
padding: 12px 24px;
font-size: 16px;
color: #fff;
background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
border: none;
border-radius: 12px;
box-shadow: 0 0 15px #6a11cb;
transition: all 0.3s ease;
}
.glow-btn:hover {
transform: scale(1.05);
box-shadow: 0 0 25px #2575fc, 0 0 40px #6a11cb;
}
</style>


This glowing button adds interactive and modern flair to your site.

More effects coming soon — stay tuned!

#html #css #frontend #code #development
Html codes
Photo
CodePen Blog
Chris’ Corner: Liquid Ass

First a quick heads up about… me. I have a weird itch to do “streaming”, so I’m letting myself just be a hardcore beginner and giving it a shot. The plan is just hang out with whoever shows up and make stuff and talk about front end web development and design. So:

* Me on Twitch
* CodePen on YouTube

Seems like those two platforms make the most sense for that, so here we go.

I made this super sick banner for Twitch, which you can’t even see because it’s covered by UI stuff lol. https://blog.codepen.io/wp-content/uploads/2025/06/Frame-1-1024x410.png Welp.

I suppose you knew that there’s no way I’m letting “liquid glass” slide by this week. Or should I say: https://blog.codepen.io/wp-content/uploads/2025/06/bafkreichpccmnpuyg6votcyb3vjza7b4zfpnpcbytuxhcxsesr43p6phd4.jpg Amazing.

Marie actually beat me to it doing a whole Spark issue on it last week. Obviously CodePen users are all over this design trend, as it’s an absolutely magnetic challenge in CSS. Kevin Powell did a video which happened to drop at the perfect time. Kevin is so good at these things I’m like sick with jealousy about it. Maybe my stream will level up my video teaching skills.

It’s not like CodePen is only now starting to have these glass-like effects. People have been doing it for ages. It had a particular boon when backdrop-filter: blur(2px); became a thing — that’s more like “frosted” glass — but still, Apple is doing that, too. Maybe -webkit-box-reflect will get new life on the web also? Feels related. Sebastiaan de With fortold it nearly perfectly well. 👏👏👏. Little touches like the reflective progress bar are so cool. https://blog.codepen.io/wp-content/uploads/2025/06/Mica-Video-Playback-1-1024x527.png I don’t know if Apple is actually doing this particular detail, I don’t have the new OS yet, but Sebastiaan’s idea is awesome.
Apple is actually quite serious about this, and released a video of the whole idea. Honestly I think it’s kinda awesome looking. https://blog.codepen.io/wp-content/uploads/2025/06/lg-controls-1024x662.jpeg But I did kinda 😬 about the accessibility of it. https://blog.codepen.io/wp-content/uploads/2025/06/glass-tabs-1024x486.jpg No chance the text “Nao” above is passing any contrast test. Nao way amiright?

Feels like text/background contrast has taken a hit. I haven’t seen a full throated takedown of it yet (there are some mentions though), but I imagine that’s coming. There are already settings in there to tone the effects down, I hear.

I thought out loud the other month: literally everything ships inaccessibly. And since having that thought I’ve seen a half dozen things ship that way. Certainly we’re not immune to it, but it’s good motivation to get some more accessibility testing done (we’ve done a good bit already!) on our new editor before it goes out.

Random thing before I sign off. The Oatmeal on Erasers is lovely.
🚀 Quick Tip: Animate with Ease!

Bring your web elements to life using simple CSS keyframe animations. Try this extended pulsing + shadow effect:

<div class="pulse-box">Hover me!</div>

<style>
body {
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background: #121212;
margin: 0;
font-family: Arial, sans-serif;
}

.pulse-box {
display: inline-block;
padding: 20px 40px;
background: #00bcd4;
color: white;
font-size: 24px;
font-weight: bold;
border-radius: 12px;
box-shadow: 0 0 20px rgba(0,188,212,0.4);
animation: pulse 2s ease-in-out infinite;
cursor: pointer;
transition: transform 0.2s;
}

.pulse-box:hover {
transform: scale(1.1);
box-shadow: 0 0 30px rgba(0,188,212,0.6);
}

@keyframes pulse {
0% {
transform: scale(1);
box-shadow: 0 0 20px rgba(0,188,212,0.4);
}
50% {
transform: scale(1.05);
box-shadow: 0 0 35px rgba(0,188,212,0.7);
}
100% {
transform: scale(1);
box-shadow: 0 0 20px rgba(0,188,212,0.4);
}
}
</style>


💡 This animation works beautifully for buttons, notification cards, or interactive banners.

Make your UI more dynamic and modern with just a few lines of CSS!

#css #animation #webdesign #html #frontend #uiux
🎯 Code Hack: Neon Text Effect

Give your website a retro-futuristic feel with this simple glowing neon text effect using only CSS:

<h1 class="neon-text">Neon Vibes</h1>

<style>
body {
background: #000;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}

.neon-text {
font-size: 48px;
color: #fff;
text-shadow:
0 0 5px #0ff,
0 0 10px #0ff,
0 0 20px #0ff,
0 0 40px #0ff,
0 0 80px #0ff;
font-family: 'Courier New', monospace;
animation: flicker 1.5s infinite alternate;
}

@keyframes flicker {
0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
opacity: 1;
}
20%, 24%, 55% {
opacity: 0.4;
}
}
</style>


🌟 Add a cyberpunk flair to headers, banners, or titles.

More daily UI tricks and CSS magic right here 👉 @Html_codee

#neon #css #html #frontend #design #webeffects
An ID SELECTOR in CSS file starts with
Anonymous Quiz
75%
Hashtag
25%
Period
0%
Semicolon
0%
Star
Html codes
Photo
CodePen Blog
Chris’ Corner: Modern CSS Features Coming Together

I like the term “content aware components” like Eric Bailey uses in the Piccalilli article Making content-aware components using CSS :has(), grid, and quantity queries. Does a card have a photo? Yes, do one thing, no, do another. That sort of thing. Eric has some good examples where a UI component has a bunch more “tags” than another, so the layout adjusts to accommodate them better. https://blog.codepen.io/wp-content/uploads/2025/06/Screenshot-2025-06-17-at-2.21.27 PM-960x1024.png Thanks to :has(), the idea of “quantity queries” (e.g. style an element if there are, say, 4 or more of an element) have gotten a lot easier. The way I figure it, we could do like: .card:has(.tag:nth-child(4)) {
/* apply styles to the card because there are at least 4 tags */
}

Admittedly, the logic gets a little bit more complicated if you want like “3 or less tags”, but that’s exactly what Eric covers in the article, linking up the original ideas and resources, so you’re in luck.

At CSS Day the other week, I listened to Ahmad Shadeed have a wonderful idea on stage. Imagine a layout with one item, you show it. Two items? Side by side? Three items? Maybe two on top and one on the bottom. Four? Two by Two. Five? Well! That’s getting to be a lot of items. We could break them into a carousel. All entirely in CSS. That’s wild. I’d love to build that one day. Maybe I’ll try to stream it one of these days. (Of course, as I write this Kevin Powell put out a video that verges on the idea, and it’s very clever.)

Speaking of Ahmad, he’s got a great article introducing the big improvements that the attr() function has gotten. I absolutely love how we can pluck attribute values out of HTML and actually have them be useful now. I think we’ll realize the power of that more and more. But it occurs to me here that it could factor into this quantity query situation. Say you trust your server to know and output stuff like this. So like: ... You can get your hands on 13, as an actual number not a string, in CSS now like: attr(data-cards type(<number), 2)
The number 2 above is a fallback. With a number like that, it makes me think that maybe-just-maybe, we could combine it with the newfangled if() commands in CSS (See Una’s great video) to write the same kind of “quantity query” logic.

Ya know how Sass has @mixin to repeat blocks of CSS? Native CSS doesn’t have that yet, but style queries are pretty close. I snagged this screenshot out of Kevin’s video (in CodePen, naturally): https://blog.codepen.io/wp-content/uploads/2025/06/Screenshot-2025-06-19-at-8.05.51 AM-1024x790.png See how he just flips on a --custom-property then the style query matches when that custom property is set and outputs a block of styles? That feels an awful lot like a mixin to me. Miriam has a nice homebase page for native mixins, which links to some very active discussion on it. At the pace CSS is moving I imagine we’ll have it before we know it. Just @applying a @mixin seems like a more straightforward approach than the style query approach, and more flexible as it’s likely they’ll take parameters, and possibly even slots. CSS carousels amount to a pretty hefty amount of CSS. Wouldn’t it be cool to make that into a hefty @mixin that takes parameters on what features you want? Ship it.

In other news, gap decorations are starting to be a thing and that’s wonderful. Hoping they’ll move right onto styling a grid area without needing an HTML element there, that would be just as wonderful. I’m still hesitant on making entire columns of article content into grids, but that’s a me-problem, I see others are coming around on the idea.
🌀 CSS Illusion: Hypnotic Spinner

Not your average loader — this CSS hypnotic animation is an eye-catcher you can use for loading states or just to impress your users!

<div class="hypno-loader"></div>

<style>
body {
background: #000;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}

.hypno-loader {
width: 100px;
height: 100px;
border-radius: 50%;
background: conic-gradient(#0ff, #00f, #f0f, #0ff);
animation: spin 2s linear infinite;
mask-image: radial-gradient(circle, black 40%, transparent 41%);
-webkit-mask-image: radial-gradient(circle, black 40%, transparent 41%);
}

@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>


🎨 Use it in creative portfolios, game loading pages, or as Easter eggs in your site.

More weird, wild, and useful CSS hacks daily here → @Html_codee

#css #animation #creative #html #frontend #weirdcss
🚀 What is Vibe Coding?
It’s a new way to build software — where you just say what you want, and AI helps you code it.
No boilerplate. No burnout. Just you, your idea, and a good vibe. 💻

🧠 AI Assistants You’ll Love:
Gemini · Claude 4 · Copilot · Cursor · Ghostwriter · Codeium

🎨 UI Builders That Feel Like Magic:
v0.dev · Lovable.dev · Framer AI · Locofy.ai · WebCrumbs

Dev Tools With Style:
Zed · Supabase · Ray.so · Carbon

💡 Why it's called vibe coding:
Because it’s fast, creative, visual, and fun.
You’re not just coding — you’re creating.

🧵 Try these tools, build what you love, and let the AI handle the boring parts.

Vibe coding = prompts + flow + joy.
🎉 Fun Project: Dancing Emoji Party

Bring life to your web page with this fun, animated dancing emoji effect. Pure HTML + CSS + JS = joy!

<div id="party-zone"></div>

<style>
body {
background: #111;
margin: 0;
overflow: hidden;
}

#party-zone {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}

.emoji {
position: absolute;
font-size: 2rem;
animation: float 5s linear infinite;
user-select: none;
}

@keyframes float {
0% {
transform: translateY(100vh) rotate(0deg);
opacity: 0;
}
50% {
opacity: 1;
}
100% {
transform: translateY(-10vh) rotate(720deg);
opacity: 0;
}
}
</style>

<script>
const zone = document.getElementById("party-zone");
const emojis = ["🎉", "🔥", "", "💻", "🧠", "🎵", "🚀", "👾"];

function spawnEmoji() {
const emoji = document.createElement("div");
emoji.classList.add("emoji");
emoji.textContent = emojis[Math.floor(Math.random() * emojis.length)];
emoji.style.left = Math.random() * 100 + "vw";
emoji.style.fontSize = Math.random() * 2 + 1 + "rem";
emoji.style.animationDuration = Math.random() * 3 + 3 + "s";
zone.appendChild(emoji);

setTimeout(() => emoji.remove(), 6000);
}

setInterval(spawnEmoji, 200);
</script>


🎊 Use this for celebrations, easter eggs, or just to surprise your visitors with some fun!

More creative web ideas at 👉 @Html_codee

#fun #javascript #frontend #animation #html #css #codeparty
import { useState, useEffect } from 'react';

const App = () => {
const [count, setCount] = useState(0);
const word = "strawberrrrry";

useEffect(() => {
// Count the number of 'r's in the word
const rCount = word.split('').filter(char => char === 'r').length;
setCount(rCount);
}, []);

return (
<div className="min-h-screen bg-gradient-to-br from-pink-200 via-red-100 to-purple-200 flex items-center justify-center p-4">
<div className="max-w-sm w-full">
<div className="bg-white rounded-2xl shadow-xl overflow-hidden transform transition-all hover:scale-105 duration-300">
<div className="p-6 text-center">
<div className="inline-flex items-center justify-center w-16 h-16 rounded-full bg-red-100 text-red-600 mb-4">
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor" className="w-8 h-8">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M9.663 17h4.673M12 3v1m6.364 1.636l-.707.707M21 12h-1M4 12H3m3.343-5.657l-.707-.707m2.828 9.9a5 5 0 117.072 0l-.548.547A3.374 3.374 0 0014 18.469V19a2 2 0 11-4 0v-.531c0-.895-.356-1.754-.988-2.386l-.548-.547z" />
</svg>
</div>
<h2 className="text-2xl font-bold text-gray-800 mb-2">Berry R Counter</h2>
<p className="text-gray-600 mb-4">How many "r"s are in the word "{word}"?</p>

<div className="bg-gradient-to-r from-pink-400 to-purple-400 rounded-xl p-6 mb-4 transform transition-all duration-500 hover:rotate-1">
<div className="text-5xl font-extrabold text-white">{count}</div>
<div className="text-white mt-1">R{count !== 1 ? 's' : ''} found!</div>
</div>

<button
onClick={() => window.location.reload()}
className="mt-2 px-4 py-2 bg-gradient-to-r from-purple-500 to-pink-500 text-white rounded-lg font-medium hover:from-purple-600 hover:to-pink-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-purple-500 transition-all duration-300"
>
Try Again
</button>
</div>

<div className="px-6 pb-6 pt-2 flex justify-center space-x-1">
{[...Array(word.length)].map((_, i) => (
<div
key={i}
className={`w-3 h-3 rounded-full ${
word[i] === 'r'
? 'bg-red-500 animate-bounce'
: 'bg-gray-300'
}`}
style={{ animationDelay: `${i * 100}ms` }}
></div>
))}
</div>
</div>

<p className="mt-6 text-center text-sm text-gray-500">
A cute little counter card for a berry interesting question 🍓
</p>
</div>
</div>
);
};

export default App;
🌿 Did You Know AI Images Harm the Planet?

Creating one AI image with tools like DALL·E or Midjourney can use more energy than a ChatGPT reply.

Why?

Because generating a single image activates large GPU-powered servers for several seconds, consuming significant electricity—often from fossil fuels.

🔌 Studies show:
1 AI image ≈ 5–10 times more energy than a Google search
1000 images = several kg of CO₂ emissions

How to Create Smarter, Greener AI Art:
🎯 Generate only one image — avoid unnecessary re-rolls
📏 Use smaller sizes like 512x512 when possible
🔄 Reuse or slightly edit existing images
🧠 Use AI art only when needed, not just for fun
Let’s create with purpose, not pollution.
Art can be beautiful — and responsible.

🙏Please share this post

#GreenAI #EcoPrompt #SustainableDesign #AIandClimate #SmartCreativity
1