1
FrEaKmAn
Image Resizer
  • 2006/4/14 19:47

  • FrEaKmAn

  • Just popping in

  • Posts: 57

  • Since: 2006/2/17


Hi

Is there any image resizer, like for news, downloads, forum and so on, so that it doesn't brake the table in page. I found one script which is used in phpbb:

#
#-----[ COPY ]---------------------------
#

copy resizefix.php to templates/subSilver/resizefix.php

# 
#-----[ OPEN ]------------------------------------------ 
#

subSilver/bbcode.tpl

# 
#-----[FIND]------------------------------------------ 
# 

<!-- BEGIN img --><img src="{URL}" border="0" /><!-- END img -->

# 
#-----[REPLACE WITH]------------------------------------------ 
# 

<!-- BEGIN img -->
<
script language="javascript" type="text/javascript"> 
<!-- 
function 
pointercursor(){document.body.style.cursor = "move";}
function 
unpointercursor(){document.body.style.cursor="";}
//--> 
</script>
<
img src="{URL}" border="0" onmouseout="unpointercursor();" onmouseover="if(this.width == 550) {pointercursor();}" onclick="if(this.width == 550) { window.open('templates/subSilver/resizefix.php?originalsize={URL}', '_blank' ,'scrollbars=1,toolbar=no,resizable=1,menubar=no,directories=no,status=yes'); return false; }" alt="" />
<!-- 
END img -->

# 
#-----[ OPEN ]------------------------------------------ 
#

subSilver/overall_header.tpl

# 
#-----[FIND]------------------------------------------ 
#

<!-- END switch_enable_pm_popup -->

# 
#-----[ AFTER, ADD ]------------------------------------------ 
# 

<script language="javascript" type="text/javascript"> 
<!-- 
  function 
resize_images() 
  { 
    for (
i = 0; i < document.images.length; i++) 
    { 
      while ( !
document.images[i].complete ) 
      { 
        break;
      } 
      if ( 
document.images[i].width > 550 ) 
      { 
        
document.images[i].width = 550; 
      } 
    } 
  } 
//--> 
</script>

# 
#-----[FIND]------------------------------------------ 
#

<body bgcolor="{T_BODY_BGCOLOR}" text="{T_BODY_TEXT}" link="{T_BODY_LINK}" vlink="{T_BODY_VLINK}">

# 
#-----[ IN-LINE FIND ]------------------------------------------ 
# 

vlink="{T_BODY_VLINK}"

# 
#-----[ IN-LINE AFTER, ADD ]------------------------------------------ 
#

onload="resize_images()"

# 
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------ 
# 
# EoM

Can somebody help me make this work, where can I find script for bb codes at xoops?

2
m0nty
Re: Image Resizer
  • 2006/4/14 20:37

  • m0nty

  • XOOPS is my life!

  • Posts: 3337

  • Since: 2003/10/24


check the hacks forum or search and ye shall find

https://xoops.org/modules/newbb/viewtopic.php?topic_id=44924&forum=14

3
FrEaKmAn
Re: Image Resizer
  • 2006/4/14 21:03

  • FrEaKmAn

  • Just popping in

  • Posts: 57

  • Since: 2006/2/17


Thanks, sorry I searched but somehow I couldn't find anything.

I tried it and it doesn't work, I'm using 2.2.3 version and I want to use this under pddownloads

EDIT: Sorry works, I had to update theme.html ...

Thnx again!