Recordad que para pedir soporte alguno, debéis facilitar los datos de soporte oportunos por favor, mirad aquí y leer las Normas generales del foro, esto nos servirá de ayuda para dar el mejor soporte..

Gracias.

La Administración de phpBB España.

[BETA] Easy Resize Posted Images 1.1.2

MODs en desarrollo para phpBB 3.0.x
Cerrado

0
No hay votos
 
Votos totales: 0

xoom
Ex Staff
Mensajes: 1158
Registrado: 03 Ene 2006, 09:02
Género:

[BETA] Easy Resize Posted Images 1.1.2

#1

Mensaje por xoom »

Nombre del MOD: Easy Resize Posted Images
Autor del MOD: kber < webmaster@phpbbegypt.com > (kber) http://www.phpbbegypt.com
Descripción del MOD
Este MOD reduce el tamaño de las imágenes publicadas en los mensajes. Pulsando en ella, se abre otra ventana con la imagen a tamaño real.

Instalación: Para instalar el MOD leer las instrucciones mostradas en los códigos.
Tras instalarlo limpiar el cache de plantillas.

Traducción: xoom
Versión del MOD: 1.1.2
Dificultad: Fácil
Tiempo de Instalación Aprox. 3 Minutos
Compatible con phpBB: 3.0
Tema original en phpBB: http://www.phpbb.com/community/viewtopi ... 9#p3179659
Spoiler
Estilo Prosilver

Código: Seleccionar todo

    ##############################################################
    ## MOD Title: Easy Resize Posted Images
    ## MOD Author: kber < webmaster@phpbbegypt.com > (kber) http://www.phpbbegypt.com
    ## MOD Description:  This MOD resizes images within the posts . Images resized are made
    ## clickable and ABRIRable in a popup in full-size.
    ## MOD Version: 1.1.2
    ## PHPBB versions: phpbb3 -( RC1 -> 3.0.2 )
    ## Installation Level: (Easy)
    ## Installation Time: 3 Minute
    ## Files To Edit:  styles/prosilver/template/viewtopic_body.html 
                             styles/subsilver2/template/viewtopic_body.html   
    ## Included Files:
    ## License: http://ABRIRsource.org/licenses/gpl-license.php GNU General Public License v2
    ##############################################################
    ## For security purposes, please check: http://www.phpbb.com/mods/
    ## for the latest version of this MOD. Although MODs are checked
    ## before being allowed in the MODs Database there is no guarantee
    ## that there are no security problems within the MOD. No support
    ## will be given for MODs not found within the MODs Database which
    ## can be found at http://www.phpbb.com/mods/
    ##############################################################
    ## Author Notes:
    ## Tested with phpbb3.0.0
    ##############################################################
    ## Antes de añadir este MOD a tu Foro, debes hacer un Back Up de todos los ficheros relatados en el MOD
    ##############################################################
    #
    #-----[ ABRIR ]------------------------------------------
    #
    styles/prosilver/template/viewtopic_body.html
    #
    #-----[ BUSCAR ]------------------------------------------
    #
              <!-- ELSE -->
             <strong>{L_FORUM_RULES}</strong><br />
             {FORUM_RULES}
          <!-- ENDIF -->

          <span class="corners-bottom"><span></span></span></div>
       </div>
    <!-- ENDIF -->
    #
    #-----[ A CONTINUACIÓN, AÑADIR ]------------------------------------------
    # nota : debes modificar ( 600px) por el tamaño que desees que se reduzcan las imágenes

    <script>
    window.onload = resizeimg;
    function resizeimg()
    {
       if (document.getElementsByTagName)
       {
          for (i=0; i<document.getElementsByTagName('img').length; i++)
          {
             im = document.getElementsByTagName('img')[i];
             if (im.width > 600)
             {
                im.style.width = '600px';
                eval("pop" + String(i) + " = new Function(\"pop = window.open('" + im.src + " ','fullscale','width=400,height=400,scrollbars=1,resizable=1'); pop.focus();\")");
                eval("im.onclick = pop" + String(i) + ";");
                if (document.all) im.style.cursor = 'hand';
                if (!document.all) im.style.cursor = 'pointer';
                im.title = 'Pulsa aquí para ver la imagen en su tamaño original ';
             }
          }
       }
    }

    </script>

    #
    #-----[ GUARDAR/CERRAR LOS ARCHIVOS ]------------------------------------------
    #
    # EoM 

    ## Tras instalarlo limpiar el cache de plantillas desde el acp

Spoiler
Estilo Subsilver2

Código: Seleccionar todo

    ##############################################################
    ## MOD Title: Easy Resize Posted Images
    ## MOD Author: kber < webmaster@phpbbegypt.com > (kber) http://www.phpbbegypt.com
    ## MOD Description:  This MOD resizes images within the posts . Images resized are made
    ## clickable and ABRIRable in a popup in full-size.
    ## MOD Version: 1.1.2
    ## PHPBB versions: phpbb3 -( RC1 -> 3.0.2 )
    ## Installation Level: (Easy)
    ## Installation Time: 3 Minute
    ## Files To Edit:  styles/prosilver/template/viewtopic_body.html 
                             styles/subsilver2/template/viewtopic_body.html   
    ## Included Files:
    ## License: http://ABRIRsource.org/licenses/gpl-license.php GNU General Public License v2
    ##############################################################
    ## For security purposes, please check: http://www.phpbb.com/mods/
    ## for the latest version of this MOD. Although MODs are checked
    ## before being allowed in the MODs Database there is no guarantee
    ## that there are no security problems within the MOD. No support
    ## will be given for MODs not found within the MODs Database which
    ## can be found at http://www.phpbb.com/mods/
    ##############################################################
    ## Author Notes:
    ## Tested with phpbb3.0.0
    ##############################################################
    ## Antes de añadir este MOD a tu Foro, debes hacer un Back Up de todos los ficheros relatados en el MOD
    ##############################################################
    #
    #-----[ ABRIR ]------------------------------------------
    #
    styles/subsilver2/template/viewtopic_body.html
    #
    #-----[ BUSCAR ]------------------------------------------
    #
    <!-- INCLUDE overall_header.html -->
    #
    #-----[ A CONTINUACION, AÑADIR ]------------------------------------------
    # nota : debes modificar ( 600px) por el tamaño que desees que se reduzcan las imágenes

    <script>
    window.onload = resizeimg;
    function resizeimg()
    {
       if (document.getElementsByTagName)
       {
          for (i=0; i<document.getElementsByTagName('img').length; i++)
          {
             im = document.getElementsByTagName('img')[i];
             if (im.width > 600)
             {
                im.style.width = '600px';
                eval("pop" + String(i) + " = new Function(\"pop = window.open('" + im.src + " ','fullscale','width=400,height=400,scrollbars=1,resizable=1'); pop.focus();\")");
                eval("im.onclick = pop" + String(i) + ";");
                if (document.all) im.style.cursor = 'hand';
                if (!document.all) im.style.cursor = 'pointer';
                im.title = 'Pulsa aquí para ver la imagen en su tamaño original ';
             }
          }
       }
    }

    </script>

    #
    #-----[ GUARDAR/CERRAR LOS ARCHIVOS ]------------------------------------------
    #
    # EoM 

    ## Tras instalarlo limpiar el cache de plantillas desde el acp

QUE HACER SI EL LOGO DEL FORO TAMBIEN SE REDUCE

Ma han informado que si el logo supera los 600 px, se reduce por la acción del mod, ya que no deja de ser una imagen con más píxeles de los que queremos permitir.

La solución:

Busca la línea

Código: Seleccionar todo

             if (im.width > 600)
Y cambiala por esta:

Código: Seleccionar todo

             if (im.width > 600 && im.src != "url del logo")
Modifica "url del logo" por la de la imagen de tu logo.
Última edición por ThE KuKa el 30 Ago 2008, 08:55, editado 2 veces en total.
Razón: Enlace oficial, prefijo y BBCode spoiler.
URL: http://www.lasegundaguerra.com
Plantilla usuada: Dirty Board
MODs instalados: Medals Mods, Multi Race Rank Theme
Versión de phpBB: 3.08
Servidor: De pago

Cerrado

Volver a “MODs en desarrollo”