Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML

Tom Hill
Tom Hill
14,232 Points

How can I create a medium.com style highlight function?

Hi! I couldn't work out - or find any resources, on how to create the highlighting thing they do on medium.com

To clarify: When you highlight a selection of words in an article, a little tooltip pops up with the option to tweet or comment on the selection of words you highlighted.

I have no idea how to achieve this (and I can't work it out from the medium.com source)

Any help is appreciated!

Thanks, Tom Hill

1 Answer

James Barnett
James Barnett
39,199 Points

It's a non-trivial feature, for starters to add comments you'll need to use a backend language (like Ruby or PHP) to store the comments in database, so that other people can see them.

Tom Hill
Tom Hill
14,232 Points

Oh ok - Thank you anyway!