/    Sign up×
Community /Pin to ProfileBookmark

I need help with a CSS script…

hi! ? i own an ezBoard, & i found this script i really wanna use at my board, but i can’t figure out how to put the size in. (125) i don’t know if anyone can help, but i’ve been helped before, so i figured it was worth a try. (this forum rocks!)

ok, here’s what i found…….

Personal Icon Tamer (CSS)

<< updated: 6/26/2003

Summary: Turn off / resize extra-large personal icons.

Details:

In Netscape / Mozilla browsers, personal icons wider than the limit will be resized. In Internet Explorer, they will be hidden.

HEAD: (box #1)

<style type=”text/css”>

/* PERSONAL ICON TAMER */

span.title img { max-width: PERSONAL_ICON_MAX_WIDTH; }

span.title img { width: expression(this.width > PERSONAL_ICON_MAX_WIDTH ? this.style.display = “none” : “auto”); }

/* END PERSONAL ICON TAMER */

</style>

HEAD Notes:

Change each instance of the text PERSONAL_ICON_MAX_WIDTH to your maximum allowed personal icon width.

~ when i take out the PERSONAL_ICON_MAX thingy & replace it with 125, nothing happens. ? i tried “125” & 125px but they didn’t work either.

thanks in advance!

luv, biff

to post a comment
CSS

4 Comments(s)

Copy linkTweet thisAlerts:
@biffauthorJan 04.2004 — ps....

i also have a few other CSS & javascripts in that box already. could they be messin it up? would they need to be in a certain order? ?
Copy linkTweet thisAlerts:
@toicontienJan 05.2004 — Could you post a link to some code or post all the HTML, CSS and JavaScript?

Also, the CSS max-width: does not work at all in Internet Explorer. It only works in browsers that impliment CSS properly (i.e. Mozilla, Opera 7, Firebird, Safari).

I'm not familiar with CSS expressions, so basically that means few browsers have advanced enough support for CSS to use expressions.
Copy linkTweet thisAlerts:
@biffauthorJan 05.2004 — it figures. i thought it sounded too good to be true. when i posed my question at the board of the site where i found the script, nobody replied. :p they should just take it down then! :mad:


anyhoo, thanks for answering me! y'all are so helpful here! ?
Copy linkTweet thisAlerts:
@toicontienJan 07.2004 — You could still impliment that code, just look at the site using the latest Mozilla or Opera. It might work on those browswers.

Worse comes to worse, set the width of a table cell or div containing the image and set the overflow: property to auto. Then people could have larger images and the DIV that contains the image would contain scroll bars for images over a certain width and height.

Another option is to detect the image type and size with a server-side language like PHP. I know PHP has some pretty powerfull image editing functions. Nothing like Photoshop of course, but they will suffice for your purposes none-the-less.

I know that this forum doesn't allow you to upload icons greater than a certain width and height. They do that with PHP.

You could try popping this question in the PHP forum saying that you want to be able to detect the image type and dimensions so you can block certain image types and dimensions.
×

Success!

Help @biff spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.22,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...