Sign Up! Login: Password: New User? Forgot? Support
Top Mods!
Wowhead Search
by sonofsamedi
Digital Clock
by Wolfar15
Admin Forums
Welcome to the GuildPortal Help Community! These forums are for admin-to-admin help.
Available Forums
Forums : Voodoo Tech and Scripter's Den of Scriptniquity > Forum Image and Sig Line Image Resizing
Vollus (New Admin) 6/15/2007 10:52 AM EST : Forum Image and Sig Line Image Resizing
Vollus
Posts: 2012
Zomgawsh Poster

The members of my guild have a tendency to use sig images that are so wide that they make the site scroll to the right. I have found a solution that I thought I would share with everyone.

First copy the style information from your site, do a view source and copy everything between the style tages at the top of the doc.

Second under Advanced Style Settings / Custom StyleSheet paste the copied styles (not the style tags)
 
Third add the following to the bottom...

td.MessageBodyCell1 img {
     max-width: 525px;
     width:expression(this.width > 525 ? "525px" : this.width);
}


It should look something like this.

 .SelectedTab {
BACKGROUND-COLOR: #003300;
COLOR: #ccff00;
BORDER-WIDTH: 1px 1px 1px 1px;
BORDER-STYLE: solid;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
BORDER-COLOR: #996600;
TEXT-ALIGN: CENTER;
PADDING: 2px 2px 2px 2px;
SPACING: 0px 0px 0px 0px;
}
FORM
{
BORDER-RIGHT: medium none;
PADDING-RIGHT: 0px;
BORDER-TOP: medium none;
PADDING-LEFT: 0px;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
PADDING-BOTTOM: 0px;
MARGIN: 0px;
BORDER-LEFT: medium none;
PADDING-TOP: 0px;
BORDER-BOTTOM: medium none;
FONT-FAMILY: Verdana
}
.UnSelectedTab {
BACKGROUND-COLOR: #000000;
COLOR: #FFFFFF;
BORDER-WIDTH: 1px 1px 1px 1px;
BORDER-STYLE: solid;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
TEXT-ALIGN: CENTER;
BORDER-COLOR: #996600;
PADDING: 2px 2px 2px 2px;
SPACING: 0px 0px 0px 0px;
}
.AltGridRow{
BACKGROUND-COLOR: #1f1f1f;
COLOR: #FFFFFF;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
}
.NormGridRow{
BACKGROUND-COLOR: #;
COLOR: #FFFFFF;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
}
.ContentBox {
BACKGROUND-COLOR: #000000;
BORDER-WIDTH: 1px 1px 1px 1px;
BORDER-STYLE: solid;
PADDING-TOP: 0px;
MARGIN-TOP: 0px;
BORDER-COLOR: #996600;
}
.ForumCategoryHeader {
BACKGROUND-COLOR: #000000;
BORDER-WIDTH: 1px 1px 1px 1px;
BORDER-STYLE: solid;
BORDER-COLOR: #996600;
PADDING-LEFT: 5px;
COLOR: #FFFFFF;
PADDING-RIGHT: 5px;
PADDING-TOP: 5px;
PADDING-BOTTOM: 5px;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
}
.ForumIconCell {
BACKGROUND-COLOR: 000000;
}
.ContentBoxTitle {
 PADDING-RIGHT: 5px;
 PADDING-LEFT: 5px;
 MARGIN-TOP: 0px;
 PADDING-TOP: 0px;
 BORDER-TOP: 0px;
 BACKGROUND-COLOR: #003300;
 COLOR: #ccff00;
 FONT-SIZE: 8pt;
 FONT-FAMILY: Verdana;
}
.ContentBoxTitleNoBackground {
COLOR: #ccff00;
 MARGIN-TOP: 0px;
 PADDING-TOP: 0px;
 FONT-SIZE: 8pt;
 FONT-FAMILY: Verdana;
}
A:active
{
COLOR: #edb91b; text-decoration: none
}
A:link
{
COLOR: #edb91b; text-decoration: none
}
A:hover
{
COLOR: #edb91b; text-decoration: underline
}
A:visited
{
COLOR: #996600; text-decoration: none
}
.ContentBoxBody {
BACKGROUND-COLOR: #000000;
COLOR: #FFFFFF;
PADDING-LEFT: 5px;
PADDING-RIGHT: 5px;
FONT-SIZE: 8pt;
FONT-FAMILY: Verdana;
}
TD
{
 FONT-FAMILY: Verdana;
 FONT-SIZE: 8pt;
}
BODY {
SCROLLBAR-BASE-COLOR: #003300;
SCROLLBAR-ARROW-COLOR: #ccff00;
BACKGROUND-IMAGE: url('http://www.axiomfiles.com/Files/67172/bg1a.jpg');
BACKGROUND-COLOR: #333333;
FONT-FAMILY: Verdana;
FONT-SIZE: 8pt;
}
IMG
{
BORDER-WIDTH: 0px 0px 0px 0px;
}
HR
{
COLOR: #996600;
}
.toolTipHeader {
color: lime;
font-weight: bold;
}


#dhtmltooltip {
position: absolute;
width: 150px;
border: 1px solid white;
padding: 3px;
background-color: black;
color: white;
visibility: hidden;
z-index: 100;
}

td.MessageBodyCell1 img {
     max-width: 525px;
     width:expression(this.width > 525 ? "525px" : this.width);
}
 

Then just click enable and save.

You can change the 525 to any maximum pixel width you so desire.

The only downside is that it tends to shrink any image really small if no width is given in the img tag. But this is fixed if refreshed.

If guildportal would wrap the sig in a div with an ID we could just target the sig area but they don't.

Enjoy

--V

http://indecents.guildportal.com

TopBottom

exodusmaster (New Admin) 7/2/2011 12:11 PM EST : RE: Forum Image and Sig Line Image Resizing
exodusmaster
Posts: 49
Becoming Adept!

Hi, this is a very good Topic, and the only one i found about this problem.
I couldn't make your code works though…

So I tried this on the "CSS Additions to Standard" tab in "Custom CSS" :

.MessageBodyCell1 img{
    padding: 3px 2px 0 3px;
    max-width: 700px;
}

and it works perfectly for me.

Hope that will help ; )
TopBottom

Admins Online
There are   members online.
So-and-so has logged on!
%title%
%message%