Welcome to the E-Blah Community!
We would like to welcome you to our community and invite you to register an account or login.
Being a registered member is important, as it gives you several advantages over the normal Guest status. After registering you will be able to download files and images, post messages, and access member-only portions of the forum - just to name a few. Registration is quick and simple, and only takes about a minute of your time.

E-Blah Community    Technical Support    Forum Support  ›  Problem applying background to messages
Users Browsing Forum
iCONICA and 5 Guests

Problem applying background to messages  This thread currently has 202 views. Print
1 Pages 1 Recommend Thread
Apollo
May 4, 2008, 7:00pm Report to Moderator Report to Moderator

E-Blah Member
Posts: 200
Posts Per Day: 0.18
Time Online: 1 days 22 hours 25 minutes
I've applied a background image to the message text area defined by .postbody

.postbody {
     background  : #0000ff url("http://www.secretscotland.org.uk/pub/images/entrybg.png") 0px 0px repeat-x;
}

While it appeared to work, the application has proven to be inconsistent, and I can't see an obvious reason.

Basically, the background appears as desired only on the first massage posted in a thread, and covers the whole area where the message text can appear, regardless of its height as determined by avatar and other info to the left of the message.

On the second, and subsequent messages, instead of covering the whole message area, the background image is applied only for the height occupied by the text of the message. The image stops at bottom of the text, and only the plain background of the message area appears below.

This thread provides a sample of the behaviour, and I wondered if there was a fix, or if I should just forget it, and the image can't be applied using the current layout...

http://www.secretscotland.org.uk/forum/m-1204146640/
Logged Offline
Site Site Private Message Private message
pcmantinker
May 8, 2008, 2:32pm Report to Moderator Report to Moderator

It's not what is seen that matters, it's character
Forum Support Team
Posts: 385
Gender: Male
Posts Per Day: 0.60
Reputation: 100.00%
Reputation Score: +7 / -0
Time Online: 2 days 20 hours 29 minutes
Location: Covington, LA
Age: 17
I see that you have a gradient background. I have one on my forum as well. What you need to do is where it says:
Code
.postbody {
     background  : #0000ff url("http://www.secretscotland.org.uk/pub/images/entrybg.png") 0px 0px repeat-x;
}

modify to:
Code
.postbody {
     background  : #finalgradientcolor url("http://www.secretscotland.org.uk/pub/images/entrybg.png") 0px 0px repeat-x;
}

You need to find the hex value of the final color in your background gradient and put that in where it says "#finalgradientcolor" so that it will be something like "#fff089".



Even if your idea seems whack, stick with it and make it happen.
IGA: International Gamers' Alliance: http://www.iga-home.net/
Blah-Themes.com http://www.blah-themes.com/
A website devoted to theme development for E-Blah based forums.

For it is by grace you have been saved, through faith—and this not from yourselves, it is the gift of God—[Eph 2:8]
Logged Offline
Site Site Private Message Private message AIM AIM YIM YIM Windows Live Messenger WLM Skype Skype Reply: 1 - 6
Apollo
May 9, 2008, 4:44pm Report to Moderator Report to Moderator

E-Blah Member
Posts: 200
Posts Per Day: 0.18
Time Online: 1 days 22 hours 25 minutes
Thanks for the try... but it missed the detail of the problem

As you note, we share a shaded background, but this is styled in the body, which appears behind the forum at all times. Applying the background images, and then defining the final gradient colour so that it runs on from the bottom of the image work fine there, exactly as expected.

The problem appeared when I tried to do the same trick when styling .postbody which shows the problem described in my first post above (so I won't repeat).

Unlike the application of the method to body, where the colour is applied as well as the images, and therefore can be seen when you scroll past the bottom of the image, when the method is applied to .postbody then the application of the image and colour seems to follow and 'OR' rule, and apply the image, if there is an image specified or available, OR it applies the colour as a default if the image is not specified or available.

What it refuses to do is apply BOTH, and allow the colour to appear after the image ends.

The odd thing, as noted in my initial message, is that it does work on the first message area at the top of the thread shown on every page, but all the rest below that just show the backgound image for however far the text last.

Hard to explain - looking at the actual effect in the sample thread I linked in the first message is probably easier.
Logged Offline
Site Site Private Message Private message Reply: 2 - 6
Martin
May 11, 2008, 12:14am Report to Moderator Report to Moderator

I love E-Blah
10 Series Support Team
Posts: 4,414
Gender: Male
Posts Per Day: 3.39
Reputation: 98.54%
Reputation Score: +203 / -3
Time Online: 35 days 2 hours 13 minutes
Location: UK
Age: 49
You need to change MessageDisplay.pl, look for:

Code
<td class="win2 vtop" style="height: 100%">


and change win2 to postbody



Martin's Reputation: Increase
Logged Online
Site Site Private Message Private message Reply: 3 - 6
Apollo
May 14, 2008, 6:25pm Report to Moderator Report to Moderator

E-Blah Member
Posts: 200
Posts Per Day: 0.18
Time Online: 1 days 22 hours 25 minutes
Ah, I see where I was going wrong as it were, and what help a little more knowledge of the core can do for you.

I did play around with win2 at an earlier stage, but that doesn't really look at all good when used in this way.

A pity that using this would break my rule of not tampering with core code - since all such transgressions (might) evaporate come the next upgrade.

Thanks for the tip though, as it saves me spending ages fiddling and wondering
Logged Offline
Site Site Private Message Private message Reply: 4 - 6
Martin
May 15, 2008, 10:27am Report to Moderator Report to Moderator

I love E-Blah
10 Series Support Team
Posts: 4,414
Gender: Male
Posts Per Day: 3.39
Reputation: 98.54%
Reputation Score: +203 / -3
Time Online: 35 days 2 hours 13 minutes
Location: UK
Age: 49
You should do what you had before and change your template.css

Code
.postbody {
     background  : #ffffff url("http://www.secretscotland.org.uk/pub/images/entrybg.png") 0px 0px repeat-x;
}


( ffffff should be changed to your preferred final gradient colour. )

Then just change MessageDisplay.pl as per post above.

I've tested it here: http://www.opportunitynowhere.co.uk/cgi-bin/forum/Blah.pl?m-1208734149/  and it does what you want it to do.



Martin's Reputation: Increase
Logged Online
Site Site Private Message Private message Reply: 5 - 6
pcmantinker
May 15, 2008, 4:03pm Report to Moderator Report to Moderator

It's not what is seen that matters, it's character
Forum Support Team
Posts: 385
Gender: Male
Posts Per Day: 0.60
Reputation: 100.00%
Reputation Score: +7 / -0
Time Online: 2 days 20 hours 29 minutes
Location: Covington, LA
Age: 17
That's similar to what I said before, I just didn't understand the entire problem. I hope you get it working.



Even if your idea seems whack, stick with it and make it happen.
IGA: International Gamers' Alliance: http://www.iga-home.net/
Blah-Themes.com http://www.blah-themes.com/
A website devoted to theme development for E-Blah based forums.

For it is by grace you have been saved, through faith—and this not from yourselves, it is the gift of God—[Eph 2:8]
Logged Offline
Site Site Private Message Private message AIM AIM YIM YIM Windows Live Messenger WLM Skype Skype Reply: 6 - 6
1 Pages 1 Recommend Thread
Print

E-Blah Community    Technical Support    Forum Support  ›  Problem applying background to messages

Thread Tags