The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Change the background in function of a profile field of the poster

View previous topic View next topic Go down

Solved Change the background in function of a profile field of the poster

Post by JonnyCode on June 5th 2013, 2:49 pm

I was looking through this tutorial and I have a few questions on how to modify it:
http://help.forumotion.com/t115828-change-the-background-in-function-of-the-gender-of-the-poster#757421

Here is my situation. I have a list on a user's account that is not view able in the topics or profiles (hidden). Is there a way I can change the background of the posts based on what is selected in this list? I cannot find the list identifier, nor do I know how to reference what one is selected.

Please tell me this can be done. If not, what would be another way I could reference a profile field that is hidden to change the background of the user's posts. I'm only looking to change the color.

EDIT: I've got that working for the most part. The thing I am having an issue with now is changing the color of the posts. How would I change the color to be like this forum? Where it is a gradient and is behind all text and images, and only for specific people?


Last edited by JonnyCode on June 11th 2013, 2:54 am; edited 1 time in total

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by JonnyCode on June 8th 2013, 5:42 pm

Bump, does anybody know? Is it possible on phpBB3? I was able to change the color of the body, but it covered the buttons and was only the amount of the text, not the post.

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by JonnyCode on June 10th 2013, 10:13 pm

Bump? Any help would be great.

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by kirk on June 10th 2013, 10:34 pm

@JonnyCode wrote: EDIT: I've got that working for the most part. The thing I am having an issue with now is changing the color of the posts. How would I change the color to be like this forum? Where it is a gradient and is behind all text and images, and only for specific people?

not sure exactly what you mean, can you post a screen shot.

other then that you do know you can use any images where the image links are in the css right. So not sure if this is what you mean or not, there dose not really seem to be many steps to the tutorial and i dint see anything about colors, but will look again.

Code:


.fa_postbody_xy{
  background: url("YOUR DIRECT IMAGE LINK HERE");
min-height: 500px;
}
 
.fa_postbody_xx {
  background: url("YOUR DIRECT IMAGE LINK HERE");
min-height: 500px;
}



kirk
Forumaster

Male Posts : 11037
Reputation : 651
Language : English,Vulcan,Klingon, Romulan,& Gorn

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by JonnyCode on June 10th 2013, 10:42 pm

I suppose a better way to describe my issues is that I am trying to change the colors of the posts based on certain things. I've got the addressing correct. But when I change the color, it covers some of the pictures and doesn't color the entire post (just the text).

You can see the example in the following picture. The "online" identifier is covered y the color and it doesn't cover the entire post, jsut the text.

What i"m looking for is to color the entire thing (Post body and post profile) the whole box.

This is the code I am using for the coloring.
Code:
.fa_postbody_xy{
background-color: #BF6;
}

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by kirk on June 10th 2013, 10:54 pm

You can try this to have color backgrounds, however i am not sure if it will correspond with the java script or not you will have to test it.

right now FFFFFF is White and 000000 is black. so try using this css instead of the one leeloo has with the images, it is the same thing i just edited the background color in in stead of background image. but like i said i am not sure if it will work with the java script or not. i will try to test it on my test forum as well.


Code:

.fa_postbody_xy{
  background-color: #FFFFFF;
min-height: 500px;
}
 
.fa_postbody_xx {
  background-color: #000000;
min-height: 500px;
}


Oh you basically did the same thing, just be sure to have the min-height: 500px; in there. and you may just have to tweak/adjust the px a little to fill it in as you need it.

or you can always add a color image in the image css code that leeloo has, if you have the exact color code >>> example #000000; Post them here and i can make a couple images of the colors.

kirk
Forumaster

Male Posts : 11037
Reputation : 651
Language : English,Vulcan,Klingon, Romulan,& Gorn

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by JonnyCode on June 10th 2013, 11:06 pm

I haven't though of using a picture for the color. That could work, I'll try that and get back here with my results. Do you know how I could affect the entire post (post profile and postbody) without the border that we see around the color?

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by kirk on June 10th 2013, 11:25 pm

what you mean the same color behind the profile and post.
well yeah you would just have to set your table rows in either the colors list or doing it with css, but it will always be that color and not the same effect that leeloo has for it only showing when posting. i will have to test a few things, your using phpbb3 okie.

kirk
Forumaster

Male Posts : 11037
Reputation : 651
Language : English,Vulcan,Klingon, Romulan,& Gorn

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by JonnyCode on June 10th 2013, 11:39 pm

Thank you for helping me Kirk. I really appreciate it.

Do you see how on your posts, the postprofile's background is different and colored? It also covers the entire post height without a border around the edge. That is what I am looking to do.

The image worked better. You can see here:

However there is still a border at the top, right and bottom and doesn't cover the entire post box.

This is the code I have here. The min-height worked for the sizing issue.
Code:
.fa_postbody_xy{ {
    background: url("http://i78.servimg.com/u/f78/16/36/21/20/untitl10.png");
     background-repeat: repeat-y;
     min-height: 500px;
}

The issue I am having now, is eliminating the border and making it the postprofile instead of postbody. I figured this would need to take place in the javascript, however when I edited it to:
Code:
$(".postprofile img[title='Male']").closest('.postprofile').prev('.postprofile').addClass("fa_postbody_xy");
Nothing happened when I tried to change the background.

EDIT:
I altered the code to be
Code:
$(".postprofile img[title='Male']").closest('.postprofile').addClass("fa_postbody_xy");
That seemed to work for grabbing the correct postprofile. However I still have the border issue.

EDIT-EDIT:
I got it working! Thank you for you help!

JonnyCode
Forumember

Male Posts : 34
Reputation : 2
Language : English

Back to top Go down

Solved Re: Change the background in function of a profile field of the poster

Post by kirk on June 11th 2013, 3:42 am

@JonnyCode wrote:
EDIT-EDIT:
I got it working! Thank you for you help!

Topic Solved & Locked

kirk
Forumaster

Male Posts : 11037
Reputation : 651
Language : English,Vulcan,Klingon, Romulan,& Gorn

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum