Weebly Tricks #84 — ClassyCountdown Timer
Add a clean countdown timer to your Weebly site, created by Marius Stanciu.
Learn how to customize and modify your Weebly site with new effects, plugins, and widgets.
Welcome to My Weebly Tricks, a resource for Weebly site owners who want to go beyond the basics. Here you'll find step-by-step guides on adding image effects, slideshows, navigation scripts, text animations, countdown timers, and more — all tailored for the Weebly platform.
Adding a custom social share buttons bar to your Weebly site gives visitors a quick way to pass a useful page to friends, colleagues or a group chat. Unlike a fixed set of native controls, your own bar can match the page design, use clear labels and show only the sharing services your readers value.
A lightweight version suits Australian sites because much of the audience arrives on a phone, whether it browses from Sydney, Melbourne or Brisbane. Place the bar below an article, beside a booking form or after a guide, and let it prepare a Facebook, LinkedIn, X, WhatsApp or email link containing the correct page title and address.
Begin with the action you want to support. A direct share bar is usually more dependable than a bundle of third-party widgets: visitors choose a network, and the new tab receives a clean link to your page. This approach also gives you control over button order, wording, colour and placement.
Choose networks according to the people behind each site. Facebook and WhatsApp suit community groups and local hospitality businesses, while LinkedIn can be valuable for consultants, exporters and professional services. X may suit news, events or organisations with an active public feed. Email remains useful for private sharing and older visitors who prefer to send a link themselves. Instagram has no dependable public form for sharing an arbitrary page address, so it works better as a traffic destination than a standard button.
Decide where the bar appears and what it should share. One bar near the end of an article is easy to find, while a compact bar after the opening section can work when readers need to recommend a guide early. Use the same placement across related pages so the interface feels familiar, and avoid putting a second copy directly below the first.
Add the code through the route available in your Weebly account. A site-wide header or footer code area lets one snippet appear on every page, while an Embed Code element on an individual page is useful for a limited trial. Check the theme editor first, since global code insertion depends on the features and plan connected to your account.
Use this self-contained example, then change the colours and labels to suit your site. It contains HTML, CSS and JavaScript, so no plugin or external icon library is required.
<style>
.mwts-share-bar {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 0.5rem;
margin: 1.5rem 0;
padding: 0.9rem 1rem;
border: 1px solid #d9dee4;
border-radius: 0.6rem;
background: #f7f8fa;
box-sizing: border-box;
}
.mwts-share-label {
margin-right: 0.25rem;
font-weight: 700;
}
.mwts-share-link {
display: inline-flex;
align-items: center;
justify-content: center;
min-height: 44px;
padding: 0.55rem 0.85rem;
border-radius: 0.35rem;
color: #ffffff;
font-weight: 600;
line-height: 1.2;
text-decoration: none;
}
.mwts-share-link:hover {
text-decoration: underline;
}
.mwts-share-link:focus-visible {
outline: 3px solid #f4b400;
outline-offset: 2px;
}
.mwts-share-link[data-share="facebook"] { background: #1877f2; }
.mwts-share-link[data-share="x"] { background: #111111; }
.mwts-share-link[data-share="linkedin"] { background: #0a66c2; }
.mwts-share-link[data-share="whatsapp"] { background: #128c7e; }
.mwts-share-link[data-share="email"] { background: #46515c; }
@media (max-width: 560px) {
.mwts-share-label {
width: 100%;
}
.mwts-share-link {
flex: 1 1 calc(50% - 0.5rem);
}
}
@media print {
.mwts-share-bar {
display: none;
}
}
</style>
<div class="mwts-share-bar"
data-share-bar
role="group"
aria-label="Share this page">
<span class="mwts-share-label">Share this page</span>
<a class="mwts-share-link" data-share="facebook" href="#">Facebook</a>
<a class="mwts-share-link" data-share="x" href="#">X</a>
<a class="mwts-share-link" data-share="linkedin" href="#">LinkedIn</a>
<a class="mwts-share-link" data-share="whatsapp" href="#">WhatsApp</a>
<a class="mwts-share-link" data-share="email" href="#">Email</a>
</div>
<script>
(function () {
const trackingKeys = [
"utm_source", "utm_medium", "utm_campaign",
"utm_term", "utm_content", "gclid", "fbclid"
];
document.querySelectorAll("[data-share-bar]").forEach(function (bar) {
const canonical = document.querySelector('link[rel="canonical"]');
const url = new URL(
canonical ? canonical.href : window.location.href
);
trackingKeys.forEach(function (key) {
url.searchParams.delete(key);
});
const titleTag = document.querySelector('meta[property="og:title"]');
const title = titleTag && titleTag.content
? titleTag.content
: document.title;
const shareUrl = encodeURIComponent(url.href);
const shareTitle = encodeURIComponent(title);
const destinations = {
facebook:
"https://www.facebook.com/sharer/sharer.php?u=" + shareUrl,
x:
"https://x.com/intent/tweet?url=" + shareUrl +
"&text=" + shareTitle,
linkedin:
"https://www.linkedin.com/sharing/share-offsite/?url=" + shareUrl,
whatsapp:
"https://wa.me/?text=" + shareTitle + "%20" + shareUrl,
email:
"mailto:?subject=" + shareTitle +
"&body=" + encodeURIComponent(url.href + "\n\n" + title)
};
bar.querySelectorAll("[data-share]").forEach(function (link) {
const network = link.getAttribute("data-share");
link.href = destinations[network];
if (network === "email") {
link.target = "_self";
} else {
link.target = "_blank";
link.rel = "noopener noreferrer";
}
});
});
})();
</script>
The JavaScript finds the canonical address when the page provides one, then uses the current address as a fallback. It removes common campaign parameters such as utm_source, gclid and fbclid, so the shared address stays tidy while the title comes from the Open Graph title or document title. Each button is generated for the page being viewed rather than for a fixed demonstration link.
If the snippet lives in site-wide code, place the bar element where you want it to appear; the script can still populate links on every page. If your plan lacks global code insertion, copy the complete block into an Embed Code element on each relevant page. Keeping the CSS and script together ensures the styling and behaviour travel with the controls.
Design the bar for thumbs first. Let the controls wrap cleanly on a narrow screen, give each button a target of at least 44 pixels high, and keep the label close enough to establish purpose. Text such as “Share this page” is clearer than a lone row of unfamiliar symbols, and visible labels remain useful when images or icons fail to load.
Colour can distinguish the networks, but colour should support the label rather than carry all the meaning. Apply sufficient contrast, retain underlines on hover, and show a clear keyboard focus ring. If you replace the text with SVG icons, give every link an accessible name and set decorative SVGs to aria-hidden="true". This keeps the bar recognisable without adding another request to an icon font.
Australian small-business audiences often arrive through a search for a local café, accommodation, event or service. A visitor in Sydney might send a restaurant menu to friends, while someone in Melbourne could forward an event guide to a group chat; a reader in Brisbane may pass a class listing to a colleague. The bar works well in these situations because it turns the current page into an immediate action without requiring a separate copy-and-paste routine.
Every external share button is a link to another service. When a visitor clicks it, that network receives the shared address and may collect information according to its own policies. The noopener and noreferrer attributes prevent the destination from accessing the Weebly tab through window.opener and limit referrer information, although using noreferrer can also remove some referral attribution from your analytics records.
Before publishing, review the privacy details that apply to your site and consider how analytics, advertising and audience tools handle visitor data. Direct buttons avoid the automatic cookies and profile creation that can occur with embedded social widgets, because the visitor chooses when to contact an external platform. They do not remove the need for a clear privacy notice or responsible data handling elsewhere on the site.
For an Australian business, privacy decisions can also carry local legal weight. Where the Privacy Act applies, organisations must handle personal information appropriately, and commercial electronic messages may fall under the Spam Act. A social bar that opens an email application does not itself subscribe anyone to a mailing list, but it should complement rather than undermine consent choices made elsewhere in your website.
A small custom bar also supports the priorities described in website speed priorities: visitors are more likely to remain when the page responds quickly, so every extra font, icon service and script should earn its place. This example makes no external request until a visitor clicks a button, which reduces the weight added to posts compared with several embedded social widgets. That advantage matters for readers on mobile data outside major cities or using an NBN connection with variable household demand.
Install it in stages. First, add the complete block to a temporary Weebly page and preview it in the browser. Check that your theme does not impose conflicting margins, colours or link styles, then move the markup into the global header or footer code area if your account permits it. Publish one ordinary article before applying the bar across the whole site, making it easier to isolate any layout or script problem.
Test on an iPhone and an Android phone, then check the main desktop browsers used by your audience. Click every destination and confirm that the title, address and preview are correct. Use keyboard navigation to reach each control, check the visible focus ring, and confirm that long labels wrap without overflowing on a small screen. Tracking parameters should be absent from the shared address unless you deliberately modify the script to retain campaign tags.
Social sharing endpoints and platform designs can change, so review the finished bar every few months. Confirm that each network still accepts the prepared URL, that Weebly has not altered the embedded markup and that the bar remains visible on new page templates. Keeping a copy of the code outside the editor also makes repairs faster if a theme update removes or disrupts the custom section.
Create a temporary Weebly page, paste the complete snippet, and replace the sample colours with your brand palette. Test one article, one landing page and one long-form post, then publish the same bar through the global code area if the placement works consistently. Choose the networks your visitors use, keep the labels readable, and launch the bar on your most useful pages so every click carries the right page, title and clean address.
Add a clean countdown timer to your Weebly site, created by Marius Stanciu.
A comparison of free and paid email accounts and the advantages of using a domain-based custom email.
Instructions on setting a free custom email address for your website within Weebly.
Configure your Weebly RSS feed so visitors can subscribe and receive email updates.
Details on a promotional offer for two months of free email hosting from Namecheap.
Subscribe for regular email updates and get access to new Weebly tips and tutorials.