May 22, 2014 14:14:54 GMT -5
Yea, I'm clearly not understanding. Where am I supposed to put {foreach $[user.mini_custom_field]} in the CSS??
I'm around and round we go
Moderator
May 22, 2014 14:30:24 GMT -5
Yea, I'm clearly not understanding. Where am I supposed to put {foreach $[user.mini_custom_field]} in the CSS??
Which option are you using?
If option 2, it is already in the code you just need to alter the names:
<div class="mini_profile" style="width:200px; height:300px; border:10px solid #eeeeee; background-image: url('http://placehold.it/200x300');{foreach $[user.mini_custom_field]}{if $[user.mini_custom_field.name] == "Hover Image"}background-image: url('$[user.mini_custom_field.value]');{/if}{/foreach}background-size:cover;">
May 22, 2014 14:54:08 GMT -5
Yes, sorry, I'm using Option 2. Okay so I've made my custom fields, now what would I change (That you have marked in red) and to what? For example, my first custom field is "gender". How would I write that in? I don't know why but this code has me stumped. I'm not sure if I've just been looking at it too long or what. lol Also, do I repeat the whole code there for another custom field or where would I add in extra fields into the code?
I'm around and round we go
Moderator
May 22, 2014 15:22:19 GMT -5
Yes, sorry, I'm using Option 2. Okay so I've made my custom fields, now what would I change (That you have marked in red) and to what? For example, my first custom field is "gender". How would I write that in? I don't know why but this code has me stumped. I'm not sure if I've just been looking at it too long or what. lol Also, do I repeat the whole code there for another custom field or where would I add in extra fields into the code?
Whoops sorry, OK I hope I can clarify below...
Sometimes, a custom field is an image URL or a color, and that is when you'll have to use some CSS. In the example I showed you, the admin set the custom miniprofile field to "hover image" and the user inputs a URL of the image that they want. Then, using some CSS, the code simply takes that URL input and makes it into a background image for the mini profile.
If your custom fields are just text or options that the user enters in (no images and no colors), then you'll want to simply list them along with all of the other profile information.
You'll want to find this part of option 2 if you are just going to list the custom fields:
<!-- HERE IS AN EXAMPLE OF A LAYOUT YOU COULD USE -->
<br>
<center>
$[user.avatar]<br>
Posts: $[user.posts]<br>
Likes: $[user.likes]<br><br>
<div style="font-size:.8em;">$[user.personal_text]</div>
</center>And then add this red part:
<!-- HERE IS AN EXAMPLE OF A LAYOUT YOU COULD USE -->
<br>
<center>
$[user.avatar]<br>
Posts: $[user.posts]<br>
Likes: $[user.likes]<br><br>
<div style="font-size:.8em;">$[user.personal_text]</div>
{foreach $[user.mini_custom_field]}
$[user.mini_custom_field.name]: $[user.mini_custom_field.value]
{/foreach}
</center>That will add the
name of the mini profile field and the
value of the mini profile field next to each other.
May 22, 2014 15:47:29 GMT -5
Oh that's great! Thanks so much! One last step and I swear I'll be out of your hair! lol It's now showing up however, it's falling off the mini profile down at the bottom. It's not sitting up where say the avatar and the username is. Where do I find the area to fix that at?
I'm around and round we go
Moderator
May 22, 2014 16:16:17 GMT -5
Oh that's great! Thanks so much! One last step and I swear I'll be out of your hair! lol It's now showing up however, it's falling off the mini profile down at the bottom. It's not sitting up where say the avatar and the username is. Where do I find the area to fix that at?
It depends on where you place it, it should be located right after the avatar below Posts and Likes.
If you want it above the avatar, place the red part I showed you in the my last post right
above where it says:
<!-- THIS IS WHERE THE AVATAR AND INFORMATION IS DISPLAYED -->
May 22, 2014 21:42:05 GMT -5
See, I got that but there's this weird space between my username, the avatar and between the avatar and the Posts/Likes. Makes it longer than the height of the hover image. I can't seem to find where this extra space is at to change it.
May 22, 2014 21:43:58 GMT -5
Nevermind, I see what it's doing. Thanks so much for your help!!
Jun 29, 2014 21:20:59 GMT -5
Hey, love this code. However I noticed that it doesn't seem to work for Guests? All I get is the image in the background of the avatar. Any way to fix that?
Aug 13, 2014 13:52:23 GMT -5
Hey, love this code. However I noticed that it doesn't seem to work for Guests? All I get is the image in the background of the avatar. Any way to fix that?
Since the re-vamp, guests now have hovers as well.
Mar 8, 2015 14:28:04 GMT -5
so i'm using this code
here and I have money/shop system but since adding this code, it's not showing up.. do you know how'd i get it to the money thing to show up in the mini-profile, or what do i have to do to get it to show up?
Mar 9, 2015 16:41:30 GMT -5
so i'm using this code
here and I have money/shop system but since adding this code, it's not showing up.. do you know how'd i get it to the money thing to show up in the mini-profile, or what do i have to do to get it to show up?
You need to add the parameter for the money plugin to the MP remodel.
lmk if you're not sure how to do this.
May 1, 2015 14:32:41 GMT -5
I'm confused. Where do I put the code?? I don't know what to do, I finished all the steps in option 2, but now what do I do?
I speak fluent sarcasm. ♥
Jul 9, 2015 9:31:38 GMT -5
Hiya~ since adding this code, I haven't been able to see the custom fields I added in the mini-profiles. Is there a way to implement them into the code, or at least a way that'll allow me to see the custom fields again?
Aug 1, 2015 11:56:58 GMT -5
Thanks for the hover image. I have been looking for this.
I am using it here. I will attempt to add more info in the mini-profile. I am new, but I will try. Also thanks for the additional links; I am sure they will help.
Sept 28, 2015 15:23:43 GMT -5
Omg, i just love this one! :DDD
used it here, in my RP's forum.
Jun 7, 2016 2:20:40 GMT -5
I can't seem to change the size for Option 2. The lines are different on my code but I've tried changing it all over all to the correct size but nothing happens.
Jan 5, 2017 23:41:33 GMT -5
Is it possible to add a custom background image for the mini profile alongside the hover image?
Jun 13, 2018 11:35:33 GMT -5
Using this template
here
EDIT: where do I put the thing for that last step? All the numbers are different on my end, as to where everything is.