Jump to content


Photo

I have no idea


  • Please log in to reply
2 replies to this topic

#1 Baracudda

Baracudda
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 17 May 2006 - 10:20 PM

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/(FTP Info is here usually)/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??

#2 kenrbnsn

kenrbnsn
  • Staff Alumni
  • Advanced Member
  • 8,235 posts
  • LocationHillsborough, NJ, USA

Posted 17 May 2006 - 11:20 PM

Do you really 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

#3 Baracudda

Baracudda
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 17 May 2006 - 11:42 PM

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....




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users