« Web, HTML, Tech Forum

does anyone know how to make it so your friends profiles appear different on your page?

like what the title says, i've seen some people do it so on their page (as an example) they all have like anime pfp's and custom names

(basically like is there a code?)


Report Topic

5 Replies

Sort Replies:

Reply by GOAT

posted

.friends-grid .pfp-fallback {
  content: url(linktoyrimage.gif); }

:3


Permalink Report Reply

Reply by BloodyBloody06

posted

Thank you!, though is there a way for each one of them to be different? when i did the code the image was the same for all of them.


Permalink Report Reply

Reply by GOAT

posted

actually yes :D


.profile .friends .person:nth-of-type(1) img {
  content: url (IMAGELINK1.JPG); }

.profile .friends .person:nth-of-type(2) img {
  content: url (IMAGELINK2.JPG); }

.profile .friends .person:nth-of-type(3) img {
  content: url (IMAGELINK3.JPG); }


fyi: nth-of-type = specifying which number in a chain of thingssss

so (1) in the above code = yr 1st fren, (2) = yr second fren and so on, so forth


more info on nth-of-type here

https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Selectors/:nth-of-type

:3


Permalink Report Reply

Reply by GOAT

posted

also i just threw up a blog post about all this :D

https://blog.spacehey.com/entry?id=1996030

xoxo


Permalink Report Reply

Reply by BloodyBloody06

posted