Jump to content

Archived

This topic is now archived and is closed to further replies.

Baracudda

I have no idea

Recommended Posts

Is there anything wrong with this code??.. considering all links are corect that is.

I'm getting an error that reads

[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]Warning: getimagesize(http://): failed to open stream: Unknown error: 0 in /home/[b](FTP Info is here usually)[/b]/public_html/blocks/block-Whos_Online_Scroll.php on line 216[/quote]



[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]// ImageSize resizes the avatar to fit in the block.
function ImageSize($image, $limit){
if ($image == "") $image = "blank.gif";
if (eregi("http://", $image)){
$image = str_replace(" ", "%20", $image);
} else {
$image = "modules/Forums/images/avatars/" . $image;
}
$size = getimagesize($image);
If (($limit < $size["0"]) or ($limit < $size["1"])){
$tenpw = $size["0"] * 0.10;
$tenph = $size["1"] * 0.10;
while ($limit < $size["0"]){
$size["0"] = $size["0"] - $tenpw;
$size["1"] = $size["1"] - $tenph;
}
while ($limit < $size["1"]) {
$size["0"] = $size["0"] - $tenpw;
$size["1"] = $size["1"] - $tenph;
}
$return = "width=\"".$size["0"]."\" height=\"".$size["1"]."\"";
} else {
$return = $size["3"];[/quote]

I've tried everything I'm aware of.. so I'm thinking the codes just wrong... maybe even just a simple typo somewhere while editing??

HELP??.. PLEASE??

Share this post


Link to post
Share on other sites
Do you [b]really[/b] want to use a URL to access the image? Is the image local to your server? If so, just use the local path to it.

Ken

Share this post


Link to post
Share on other sites
My buddie and I set this up.. one did all the directories.. so.. I would expect them to be local.. but I'll ask him.. I guess thats the issue here.. I apreciate your information and experience!

-----

Edit*

i think i see the isue here.. thats for a member list with avatar. and the Ave is linked off server.. maybe thats the issue.. it was written for local and it's linked to a URL. Hhmmmmmmm....

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.