Recent Posts

Pages: [1] 2 3 4 5 ... 10
1
Just bumping this topic to ask if there's going to be a version for phpBB3.3?

I've been running a phpBB2 site for years with a 4Images v1.7.4  gallery, and am about to update the forum to phpBB3.3 but have no way of updating the gallery to integrate with phpBB3.3.
2
Discussion & Troubleshooting / How do i replace - with space
« Last post by praveen on June 13, 2020, 07:16:51 AM »
How can I replace all instances of hyphen (-) with space?

My image names are all showing up as text1-text2-01
3
Great!! hope you can conclude this, if you need some testers pelase let me know
4
Mods & Plugins (Releases & Support) / Re: [Mod] Avatar v2.01
« Last post by Jan-Lukas on May 29, 2020, 08:44:35 PM »
 :thumbup:
5
Mods & Plugins (Releases & Support) / Re: [Mod] Avatar v2.01
« Last post by Aleksey on May 29, 2020, 01:29:32 AM »
This Mod ready for gallery 1.8 and php 7+, but need this changes:

New step 1.4.
Few lines below find:
Code: [Select]
  $site_template->register_vars(array(
    "user_name" => format_text(stripslashes($user_name), 2),

Replace with:
Code: [Select]
//-----------------------
//------ Avatar ---------
//-----------------------
  if ($config['avatar_use']){
   $images = "";
  $checked = ($user_avatar == "blank.gif" || $user_avatar == "") ? " selected" : "";
  $images .= "\n<option value=\"blank.gif\"$checked>none</option>\n";
  $dir = opendir(TEMPLATE_PATH."/avatars/users/");
  $contents = array();
  while ($contents[] = readdir($dir)){;}
  closedir($dir);
  natcasesort ($contents);
  foreach ($contents as $line){
   $filename = substr($line,0,(strlen($line)-strlen(strrchr($line,"."))));
   if ($filename == $user_info['user_id']) {
     $checked = (stristr($user_avatar, "users/")) ? " selected" : "";
     $images .= "\n<option value=\"users/$line\"$checked>".$lang['custom']."</option>\n";
   }
  }
   $dir = opendir(TEMPLATE_PATH."/avatars/");
   $contents = array();
   while ($contents[] = readdir($dir)){;}
   closedir($dir);
   natcasesort ($contents);
   $checked = "";
   foreach ($contents as $line){
      $filename = substr($line,0,(strlen($line)-strlen(strrchr($line,"."))));
      $extension = substr(strrchr($line,"."), 1);
      $checked = "";
      if ($line == $user_avatar) { $checked = " selected"; }
      if (strcasecmp($extension,"gif")==0 || strcasecmp($extension,"jpg")==0 || strcasecmp($extension,"jpeg")==0 || strcasecmp($extension,"png")==0 ){
         if ($line != "blank.gif") {
        $filename = str_replace("_", " ", $filename);
        $images .= "<option value=\"$line\"$checked>$filename</option>\n";
       }
      }
   }
  }
//----------------------
//----- End Avatar -----
//----------------------

  $site_template->register_vars(array(
   "lang_avatar" => $lang['avatar'],
   "lang_avatar_file" => $lang['avatar_file'],
   "lang_avatar_dim" => $lang['avatar_max_dim']." ".$config['avatar_width']."x".$config['avatar_height'].$lang['px'],
   "lang_avatar_select" => $lang['avatar_select'],
   "user_avatar_images" => $images,
   "user_avatar_current" => ($config['avatar_use']) ? "<img src=\"".TEMPLATE_PATH."/avatars/".(($user_avatar == "") ? "blank.gif" : $user_avatar)."\" name=\"icons\" border=\"0\" alt=\"\">" : "",
   "lang_or" => $lang['or'],
   "user_avatar_file" => $config['avatar_user_custom'],
    "user_name" => format_text(stripslashes($user_name), 2),

New step 3.6.
Find:
Code: [Select]
    //Thumbnails
    $this->accepted_extensions['thumb'] = array(

Insert above:
Code: [Select]
//Avatar
    $this->accepted_mime_types['avatar'] = array(
      "image/jpeg",
      "image/pjpeg",
      "image/gif",
      "image/x-png"
    );
    $this->accepted_extensions['avatar'] = array(
      "jpg",
      "jpeg",
      "gif",
      "png"
    );

Enjoy!  :)
6
Français / "Recherche" 4images 1.7.1
« Last post by Mi©hel on May 23, 2020, 07:12:46 PM »
Bonjour.

4 ans sans messages dans la rubrique fraçauise de 4images, je tente le coup quand même ;-)

SOUCIS 1 :

Je viens de faire quelques modifications sur mon module 4images suite à ce post :

https://www.4homepages.de/forum/index.php?topic=22668.0

Seule opération que je ne comprend pas c'est :

In .php files replace all
FROM table1 ref, table2 ref

with:
FROM (table1 ref, table2 ref)


SOUCIS 2 :
Suite à cela tout refonctionne SAUF l'outil recherche qui ne me donne aucun résultat...pas de message d'erreur

Une idée ???
MERCI ;-)

++Michel
(Lalogotheque.com/Lalogo.fr)

7
Mods & Plugins (Releases & Support) / Re: [MOD] PMv2 Tutorial Republished here
« Last post by Aleksey on May 22, 2020, 07:05:47 PM »
I fixed this MOD, and now it works for gallery 1.8 and php 7+

After install, you need to make these changes:

New correct Step 6

Open /includes/functions.php
Find:
Code: [Select]
function format_text
just comment entire function by doing this:
Add before that line:
Code: [Select]
/*
and at the end of the function find (in default 4images ver:1.8 it would be):
Code: [Select]
  $text = str_replace("\\'", "'", $text);

  return $text;
}

add after that closing bracket } add this:
Code: [Select]
*/
After Step 6.2

Open /includes/functions.php
Find:
Code: [Select]
     $text = preg_replace("/\[php\](.*?)\[\/php\]/esi", "phphighlite('\\1')", $text);
      $text = preg_replace("/\[code\](.*?)\[\/code\]/esi", "bb_code('\\1')", $text);
Replace with:
Code: [Select]
     $text = preg_replace_callback("/\[php\](.*?)\[\/php\]/si", "phphighlite", $text);
      $text = preg_replace_callback("/\[code\](.*?)\[\/code\]/si", "bb_code", $text);

Find:
Code: [Select]
    $text = preg_replace("/\[thumb=([0-9]+)(,([0-9]+)?)?(,([a-zA-Z]+))?\]/esi","thumb('\\1','\\3','\\5')",$text);
Replace with:
Code: [Select]
    $text = preg_replace_callback("/\[thumb=([0-9]+)(,([0-9]+)?)?(,([a-zA-Z]+))?\]/si","thumb",$text);

After Step 7

Open /includes/page_header.php
Find:
Code: [Select]
      if (ereg("pm.php", $self_url) && $action == "inbox") {Replace with:
Code: [Select]
      if (preg_match("/pm.php/", $self_url) && $action == "inbox") {
Find:
Code: [Select]
      }elseif (!ereg("pm.php", $self_url) || (ereg("pm.php", $self_url) && ($action == "sentbox" || $action == "outbox"))){
Replace with:
Code: [Select]
      }elseif (!preg_match("/pm.php/", $self_url) || (preg_match("/pm.php/", $self_url) && ($action == "sentbox" || $action == "outbox"))){

After Step 18

Open logout.php
Find:
Code: [Select]
if (!preg_match("/index\.php/", $url) && !preg_match("/lightbox\.php/", $url) && !preg_match("/login\.php/", $url) && !preg_match("/register\.php/", $url) && !preg_match("/member\.php/", $url)) {Replace with:
Code: [Select]
if (!preg_match("/index\.php/", $url) && !preg_match("/lightbox\.php/", $url) && !preg_match("/login\.php/", $url) && !preg_match("/register\.php/", $url) && !preg_match("/member\.php/", $url) && !preg_match("/pm\.php/", $url)) {
Download the new files attached to this message: pm.php and /includes/paging.php is archived and unarchived in your gallery.

Enjoy! :D
8
Discussion & Troubleshooting / Re: Anything Happening with 4images?
« Last post by Jan-Lukas on May 18, 2020, 10:38:49 PM »
Well, Kai was online last week. Whatever that means?
9
Mods & Plugins (Releases & Support) / [MOD] Simple smtp sending over ssl
« Last post by Aleksey on May 16, 2020, 10:27:45 PM »
This mod allows you to send emails from the 4images gallery via smtp with SSL authentication.

-----------| Changed Files |--------------------
/includes/email.php

-----------| New files |---------------------------
/includes/SendMailSmtpClass.php

-----------| Installation |-----------------------
Step 1

Download SendMailSmtpClass.php attached on this post and copy to /includes/SendMailSmtpClass.php

Step 2
Open /includes/email.php
Find:
Code: [Select]
if (!defined('ROOT_PATH')) {
  die("Security violation");
}

below insert:
Code: [Select]
require_once "SendMailSmtpClass.php"; // the plug-in class

Find:
Code: [Select]
  function send_email() {
    if ($this->use_smtp) {
      return ($this->smtp_mail($this->to, $this->subject, $this->body, $this->create_header())) ? 1 : 0;
    }
    else {
      return (mail($this->to, $this->subject, $this->body, $this->create_header())) ? 1 : 0;
    }

You can delete this function or comment on the code
Code: [Select]
/* ////////// Original function send_email //////////
    function send_email() {
    if ($this->use_smtp) {
      return ($this->smtp_mail($this->to, $this->subject, $this->body, $this->create_header())) ? 1 : 0;
    }
    else {
      return (mail($this->to, $this->subject, $this->body, $this->create_header())) ? 1 : 0;
    }
  } */

below insert:
Code: [Select]
// Mod Simple smtp ssl sending START
  function send_email() {
    global $config;
$sitename = $config['site_name'];          // the site name is taken from the gallery settings
$smtp_from = 'mygallery@gmail.com';        // sender's email and smtp login
$smtp_password = 'my_password_smtp_user';  // smtp user password
$smtp_host = 'ssl://smtp.gmail.com';       // smtp server address, do not delete the transport ssl://
$smtp_port = 465;                          // smtp port
$smtp_charset = "UTF-8";                   // encoding of email messages UTF-8 or windows-1251

$from = array( $sitename, $smtp_from);
$mailSMTP = new SendMailSmtpClass($smtp_from, $smtp_password, $smtp_host, $smtp_port, $smtp_charset);
return ($mailSMTP->send($this->to, $this->subject, $this->body, $from)) ? 1 : 0;
  }
// Mod Simple smtp ssl sending END

This is an example of settings for working with mail gmail.com
Change to your own parameters.

The "word_wrap"function also doesn't work well by default.
It inserts a break in the text of your emails in unexpected places.
To disable it find:
Code: [Select]
  var $word_wrap = 76;
Replace:
Code: [Select]
  var $word_wrap = 0;
Tested on mail servers yandex.ru, mail.ru and gmail.com, smtp.beget.com

Author SendMailSmtpClass.php - Ipatov Evgeniy admin@vk-book.ru
Article https://vk-book.ru/novaya-versiya-klassa-sendmailsmtpclass-otpravka-fajlov-cherez-smtp-s-avtorizaciej-po-protokolu-ssl-na-php/
This project on github - https://github.com/Ipatov/SendMailSmtpClass

By default, emails are sent as text, but the class supports sending in html format and even sending files.

Good luck! :)
10
Discussion & Troubleshooting / Re: Anything Happening with 4images?
« Last post by nobby on May 13, 2020, 09:28:58 PM »
Hi,

There's nothing really happening here anymore.


nobby
Pages: [1] 2 3 4 5 ... 10