Insert a link in the blog description?

I’d love to be able to add a link in the description of my blog!
I’ve tried to include some HTML but it doesn’t work.

I’ve tried a bunch of different things, but I can’t make it work.
Maybe someone has some ideas for a javascript snippet?

Should be doable via custom JavaScript. I’ll give it a try and will share the script here if I’m successful.

That actually didn’t take long at all. Here is the custom JavaScript for it:

/* Custom Description*/
const customDescriptionHTML = 'A peek into the mind of a sleep deprived <a href="https://devblog.dinobansigan.com/" target="_blank">software developer</a>, husband, dad and <a href="https://journal.dinobansigan.com/tag:GameLog" target="_blank">gamer</a>.';
const desc = document.querySelector('header').getElementsByTagName('p')[0];
if (desc) {
    desc.innerHTML = customDescriptionHTML;
}

All you need to do is change the content of the customDescriptionHTML variable to the html you want to display.

You can find a live demo of it here:

3 Likes

Ah! Fantastic @dino! Thank you so much.
Much easier than the convoluted things I was trying to do.

1 Like

You are welcome!

Thanks for helping out, @dino!

As this kind of thing is requested pretty often, and we already do it on Snap.as profiles, and there’s really no reason not to, we will support this natively soon! Basically, we’ll just add Markdown support to the Description field – more details here.

2 Likes

Happy to help. And great news on supporting it natively!

This is live now!

Markdown and basic HTML (like <a> tags) will work now.

Note: there is a 160-character limit on the description right now, so you may run into that with a lot of markup. In that case, @dino’s solution will still be the best route until we expand that.

2 Likes

Hi, markdown and HTML are not working in description line for me. I will try the javascript in the meantime.

Thanks.

As mentioned here, this only works on Write.as for now – it’ll be on WriteFreely soon: