Sololearn: Learn to Code
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2
You have to be More Specific. But, in generalist-terms, I assume that it's Facebook Style? So. Let's review the code that you'll need... HTML: <div class="AverageContainer"> <button id="ThumbUpSymbol" onclick="ClickLike()"> <p id="Some Other Id I Can't Think Of - Offset To The Side"> Like! </p> </button> </div> CSS: .AverageContainer { height: 50 px; width: 80 px; position: absolute; background-color: #FFF; color: #FFF; } #ThumbUpSymbol { height: 25 px; width: 25 px; position: relative; content:url("https://wikimedia.org/wikipedia/commons/thumb/up/like.svg.jpeg"); } /* Note, the address used above is for example only, and will not give an actual image or website. */ JS: function ClickLike() { alert("You Liked " + CurrentViewedImage or CurrentViewedText + "!") // Send a Query to the Web-Server Output: A 'decent-looking' facebook-cloned "Like!" button. But, meh, it'll do. ;) This was the best I could think of, I'm interested as to what others will say on this. Best wishes, Happy New Year!
1st Jan 2017, 10:45 PM
ghostwalker13
ghostwalker13 - avatar