Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - SLL

Pages: [1] 2
1
Mods & Plugins (Requests & Discussions) / [req] delete inactive users
« on: January 18, 2007, 09:26:19 AM »
Something like used with most forums - delete users without any picture uploaded or comment posted. Any volunteers to create such mod?  :roll:

2
It seems I've found a possibility to use Annotation MOD on galleries running NetPBM as a main image manipulatuion tool. Now the question is: if it worth spending time rewriting MOD?

3
Mods & Plugins (Releases & Support) / [Mod] Mini-Top
« on: May 25, 2003, 10:32:40 PM »
Quote
Mini-Top MOD for 4images - Image Gallery Management System.

Version:      1.0

Author:       Silly Little Lamer (sll@dalnet.ru) and V@no (http://gallery.vano.org)

Description:

This Mod shows additional table on the first (and/or any other page) of your gallery, with the thumbnail of one winner from each category – most rated, voted, commented, viewed and downloaded.

Installation Level:    Easy
Installation Time:      5 Minutes

Files To Edit:       2

   /index.php
   /lang/english/main.php

download: http://faces.dalnet.ru/files.php?id=5&l=english

If you receive errors after installing this mod, try download package from the attachment below and replace mini_top.php from it

4
Mods & Plugins (Requests & Discussions) / too many comments...
« on: February 19, 2003, 01:43:19 PM »
is there some simple way to make paging in details.php?  this page getting too big when too many comments entered.

5
Discussion & Troubleshooting / Search Russian words
« on: February 02, 2003, 10:37:50 PM »
4images search engine doesn't work with Russian (cyrillic) words... neither in username, nor in image name. Any ideas?

6
Installation, Update & Configuration / url redirection...
« on: January 30, 2003, 09:46:39 PM »
I know, this is not 4images installation problem, but anyway  :)

Actual gallery url is: http://www.dalnet.ru/4images/
I've made an alias to this url like this: http://faces.dalnet.ru

Now, the question is - how could I automatically redirect people, coming to the first url to http://faces.dalnet.ru?

Thanks!

7
Mods & Plugins (Releases & Support) / [Mod] Image Annotation (Watermark)
« on: January 27, 2003, 04:30:46 PM »
Quote
Auto annotate images MOD for 4images - Image Gallery Management System.

Version:      1.4

Author:       Silly Little Lamer <sll@dalnet.ru>

Description:

This MOD automatically places a line of custom text, called "Annotation" on every image uploaded to the Gallery. Fully customizable: font type, size and color, shadow usage, offsets, annotation location, etc. "Batch Annotate" admin plug-in included, to annotate images, uploaded to your gallery before you installed this MOD.

Requirements:    

To use in text annotation mode: GD2+ Library compiled with Freetype support. Also works with ImageMagic, but GD still needed for some functions, which ImageMagic is missing.
For "image embedding" mode you don't need anything.

New in v.1.4

•   NetPBM support in both text and image embedding mode.
•   Media type check (applies annotation only on jpeg images); no ‘gif’ errors anymore.
[/b]

New in v.1.31

•   You can choose the annotation method now: text annotation or embedded PNG image (logo, text, etc.). Image embedding (hopefully) works with ImageMagick even if GD library is not installed on your server. CP annotation settings are now separated from the Gallery Settings. Simplified MOD installation.

New in v.1.2

•   Misc. corrections (read 4images forum), code cleanup. Problem with *nix"rename" solved (hopefully".
•   Now checking if annotation text would fit image width, skipping if not.
•   Now you can use variables in the "annotation text" setting, which will be automatically replaced during annotation:
                   %N for Site Name , %H for full Site URL (http://www.mysite.com), %U for short Site URL (www.mysite.com)  
                   %S for User Name (image uploader name), %D for current date, %T for current time, %B to insert line break into annotation text.
[EDIT by V@no]
there is a bug in annotate.php so, either use single quotes around the variables above (i.e. '%N' or '%T') or do these changes: http://www.4homepages.de/forum/index.php?topic=13719.msg68084#msg68084
[/EDIT]
[/i]

New in v.1.1

•   Now you can customize both text and shadow colors and set alpha blending (text transparency) value for your annotation (thanks to V@no). Transparency using GD2 only!

Installation Level:    Easy
Installation Time:      10 Minutes

Files To Edit:       3

   /4images/member.php
/4images/admin/settings.php
   /4images/lang/english/admin.php

Before installing this MOD! (only if you going to use it in "text annotation mode")
Run this small code below (dont' forget to adjust font path). If you see black square with white text, than your system meets all neccessary requirements.
Code: [Select]
<?php
header 
("Content-type: image/png");
$im imagecreate (18030);
$black imagecolorallocate ($im000);
$white imagecolorallocate ($im255255255);
imagettftext ($im1401021$white"/home/public_html/arial.ttf""GD Freetype test");
imagepng ($im);
imagedestroy ($im);
?>

download: http://www.4homepages.de/forum/index.php?action=dlattach;topic=13719.0;attach=4186


If you get error when run batch_annotate.php
Quote
Warning: require(./../admin/admin_global.php) [function.require]: failed to open stream: No such file or directory in admin/plugins/batch_annotate.php on line 8
Fatal error: require() [function.require]: Failed opening required './../admin/admin_global.php' (include_path='.') in admin/plugins/batch_annotate.php on line 8
Then open batch_annotate.php
Find:
$root_path = (eregi("\/plugins\/"$PHP_SELF)) ? "./../../" "./../";

Replace it with:
$root_path "./../../";

The attached package already fixed.

8
Discussion & Troubleshooting / Small correction in thumbnailer.php
« on: January 22, 2003, 09:50:40 AM »
Replace:
Code: [Select]
   show_form_header("thumbnailer.php", "createthumbnails", "form");
    echo "<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\" width=\"100%\"><tr><td class=\"tableborder\">\n<table cellpadding=\"3\" cellspacing=\"1\" border=\"0\" width=\"100%\">\n";
    echo "<tr class=\"tableseparator\">\n<td class=\"tableseparator\"><input name=allbox type=checkbox onClick=\"CheckAll();\" checked=\"checked\"></td>\n<td class=\"tableseparator\">".$lang['field_image_name']."</td>\n<td class=\"tableseparator\">".$lang['field_image_file']."</td>\n<td class=\"tableseparator\">".$lang['field_category']."</td>\n</tr>\n";
    echo $imgs;
    show_table_separator($lang['convert_options'], 4);
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\"><p class=\"rowtitle\">".$lang['convert_thumbnail_dimension']."</p></td>\n";
    echo "<td colspan=\"2\"><p><input type=\"text\" size=\"$textinput_size\" name=\"dimension\" value=\"100\"></p></td>\n</tr>\n";
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\" valign=\"top\"><p class=\"rowtitle\">".$lang['resize_proportions_desc']."</p></td>\n";
    echo "<td colspan=\"2\"><p>";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"1\" checked=\"checked\"> ".$lang['resize_proportionally']."<br />";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"2\"> ".$lang['resize_fixed_width']."<br />";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"3\"> ".$lang['resize_fixed_height']."<br />";
    echo "</p></td>\n</tr>\n";
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\"><p class=\"rowtitle\">".$lang['convert_thumbnail_quality']."</p></td>\n";
    echo "<td colspan=\"2\"><p><input type=\"text\" size=\"$textinput_size\" name=\"quality\" value=\"75\"></p></td>\n</tr>\n";
    show_form_footer($lang['create_thumbnails'], "", 4);

with:
Code: [Select]
   show_form_header("thumbnailer.php", "createthumbnails", "form");
    echo "<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\" width=\"100%\"><tr><td class=\"tableborder\">\n<table cellpadding=\"3\" cellspacing=\"1\" border=\"0\" width=\"100%\">\n";
    echo "<tr class=\"tableseparator\">\n<td class=\"tableseparator\"><input name=allbox type=checkbox onClick=\"CheckAll();\" checked=\"checked\"></td>\n<td class=\"tableseparator\">".$lang['field_image_name']."</td>\n<td class=\"tableseparator\">".$lang['field_image_file']."</td>\n<td class=\"tableseparator\">".$lang['field_category']."</td>\n</tr>\n";
    echo $imgs;
    show_table_separator($lang['convert_options'], 4);
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\"><p class=\"rowtitle\">".$lang['convert_thumbnail_dimension']."</p></td>\n";
    echo "<td colspan=\"2\"><p><input type=\"text\" size=\"$textinput_size\" name=\"dimension\" value=\"".$config['auto_thumbnail_dimension']."\"></p></td>\n</tr>\n";
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\" valign=\"top\"><p class=\"rowtitle\">".$lang['resize_proportions_desc']."</p></td>\n";
    echo "<td colspan=\"2\"><p>";
    $resize_type_1_checked = ($config['auto_thumbnail_resize_type'] == 1) ? " checked=\"checked\"" : "";
    $resize_type_2_checked = ($config['auto_thumbnail_resize_type'] == 2) ? " checked=\"checked\"" : "";
    $resize_type_3_checked = ($config['auto_thumbnail_resize_type'] == 3) ? " checked=\"checked\"" : "";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"1\"".$resize_type_1_checked."> ".$lang['resize_proportionally']."<br />";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"2\"".$resize_type_2_checked."> ".$lang['resize_fixed_width']."<br />";
    echo "<input type=\"radio\" name=\"resize_type\" value=\"3\"".$resize_type_3_checked."> ".$lang['resize_fixed_height']."<br />";
    echo "</p></td>\n</tr>\n";
    echo "<tr class=\"".get_row_bg()."\">\n<td colspan=\"2\"><p class=\"rowtitle\">".$lang['convert_thumbnail_quality']."</p></td>\n";
    echo "<td colspan=\"2\"><p><input type=\"text\" size=\"$textinput_size\" name=\"quality\" value=\"".$config['auto_thumbnail_quality']."\"></p></td>\n</tr>\n";
    show_form_footer($lang['create_thumbnails'], "", 4);

... and you have values from gallery config, not some fixed figures, as it is now.

9
Mods & Plugins (Requests & Discussions) / To Administrator & Moderator
« on: January 21, 2003, 09:16:04 AM »
I'd like to suggest to split this forum to three:

- MOD Publishing & Support
- MOD Requests & Discussions
- Language Packs & Graphics

It's really getting more and more difficult to navigate through this one forum and find necessary information here.

Also would be good to somehow formalize the form, people are publishing their MOD's, for example the way it'd done with phpBB

Regards,
SLL

10
I've made this small MOD on my users request. They were waiting for their photo validation, without knowing if it was declined. The idea and some code are from Vraxor (mail on comments MOD).
Code: [Select]
#############################################################################################
## Title: Email image validation results to the user
##        for 4images - Image Gallery Management System.
##
## Version: 1.0
## Author: Silly Little Lamer <sll@dalnet.ru>
## Description: This Mod sends the email to the users, informing them if uploaded
## image(s) were validated or declined by the Administrator of the Gallery.
##        Email being sent only to the users, which have "Receive emails from
## administrators" set "on"
##
## Installation Level: Easy
## Installation Time: 5 Minutes
##
## Files To Edit: 1
## /4images/admin/validateimages.php
##
#############################################################################################
download: http://faces.dalnet.ru/files.php?id=7&l=english

11
Mods & Plugins (Releases & Support) / [Mod] User upload limits
« on: January 15, 2003, 01:46:11 PM »
Code: [Select]
################################################################################################
## Title: User Upload Limits for 4images - Image Gallery Management System.
## Version: 1.2
## Author: Silly Little Lamer <sll@dalnet.ru>
## Description: This Mod sets limits to the number of images, that user could upload to the gallery.
## Default limit is set to all existing users during installation of this MOD, and can
## be changed later via Control Panel. Individual upload limits for every user can also
## be changed via Edit User Panel.
##
## New in v.1.2 - Daily limits + ability to check uploaded but not yet validated images.
##
##
## Installation Level: Medium
## Installation Time: 20 Minutes
##
## Files To Edit: 6
## /4images/member.php
## /4images/register.php
## /4images/admin/users.php
## /4images/admin/settings.php
## /4images/lang/english/admin.php
## /4images/lang/english/main.php
##
################################################################################################
download: http://faces.dalnet.ru/files.php?l=english
[EDIT]
updated instructions with fixes you can find attached to this post
In the original package the installation script is broken, please use the fixed version from attachment below.


[EDIT2]
more and more people reported errors when they try add a new user.
Please apply Lord Nite fix:
After mod installed find in admin/users.php:
Code: (MySQL) [Select]
($user_id, $user_level, '$user_name', '$user_password', '$user_email', $user_showemail, $user_allowemails, $user_invisible, $current_time, '$activationkey', $current_time, $current_time, 0, '$user_homepage', '$user_icq', $user_limit".$additional_value_sql.")";
Replace it with:
Code: [Select]
($user_id, $user_level, '$user_name', '$user_password', '$user_email', $user_showemail, $user_allowemails, $user_invisible, $current_time, '$activationkey', $current_time, $current_time, 0, '$user_homepage', '$user_icq', '$user_limit'".$additional_value_sql.")";

12
I've got a number of emails asking how to add static icons in the Category frame. Below is my solution:

- Create icons for each category and name them category[cat_id].gif, for example category1.gif, category2.gif, etc.
This is according to your taste, of course. I'm using 40x40 gif's like this:

- Create the image joinbottom.gif for sub-categories or use mine:

- Place them all into /templates/xxxx/images/ folder (or /templates/xxxx/images_lang/ if you are using multiple languages)

- Change your /templates/xxxx/category_bit.html as follows:

Code: [Select]
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
<td width="50" rowspan="2" align="center" valign="top">
<a href="{cat_url}"><img src="{template_lang_image_url}/category{cat_id}.gif" border="1"></a></td>
<td align="left" valign="top"><a href="{cat_url}" class="maincat">{cat_name}</a>&nbsp;({num_images})</td>
  </tr>
  <tr>
<td align="left" valign="top">{if cat_description}<span class="smalltext">{cat_description}</span><br />{endif cat_description}</td>
  </tr>
</table>
{if sub_cats}
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
<td width="50" align="center" valign="top"><img src="{template_lang_image_url}/joinbottom.gif"></td>
<td align="left" valign="top">{sub_cats}</td>
  </tr>
</table>
{endif sub_cats}

- If you do not use multiple languages, change {template_lang_image_url} to {template_image_url}

That's it! Demo at http://faces.dalnet.ru/index.php?l=english

13
Feedback & Suggestions / Simple 4images - phpBB integration
« on: January 13, 2003, 09:55:32 PM »
Maybe my thoughts are naive, but why don't you use simple way to integrate 4images - phpBB? I mean, just to synchronize username/password in both databases.

Something like this:

Login at 4images > check 4images DB > found > login successful
Login at 4images > check 4images DB > not found > check phpBB DB > found > update userinfo in 4images DB > login successful
Login at 4images > check 4images DB > not found > check phpBB DB > not found > register at 4images > update userinfo in phpBB DB

and viceversa, from phpBB side ...

I think, you understand what I mean. Unfortunately, I'm not good in PHP programming enough to do it myself. If somebody can make such MOD, it should be possible to apply it even to full 4images galleries and full phpBB boards.

14
Mods & Plugins (Releases & Support) / [Mod] Photo Of The Day
« on: January 11, 2003, 02:13:24 AM »
Quote
Photo Of The Day MOD for 4images - Image Gallery Management System.

Version:      1.2

Author:       Silly Little Lamer <sll@dalnet.ru>

Description:

This Mod shows so called "Photo Of The Day" on the first (and/or any other page) of your gallery. Depending on your settings, the first of the Top Images is selected by rating, number of votes, comments, downloads, hits and its thumbnail is shown as a "Photo Of The Day".

New in v.1.2

•   Random selection mode. (as always, bright idea by V@ano)


Installation Level:    Easy
Installation Time:      10 Minutes

Files To Edit:       4

   /includes/functions.php
   /includes/page_header.php
   /includes/constants.php
   /lang/english/main.php

[EDIT by V@no]
This mod is based on 4images v1.7 some parts of it might not work properly in newer 4images. If mod doesn't work properly for you, try these additional modifications
[/EDIT]

demo: http://faces.dalnet.ru/index.php?l=english
download: http://faces.dalnet.ru/files.php?l=english

15
This mod works fine for me, as well as phpBB Fetch Info does, but only one of these mods on the same page, alone. When I'm trying to run both mods together, on the same page, the phpBB Fetch Info doesn't work at all. I'm using different database for 4images and pbpBB.

Please advise, what could be the reason for this conflict? Thanks in advance!

Code: [Select]
<?php
#################################################################
## Mod Title&#58;   phpBB Fetch Info
## Author&#58;      Ca5ey <ca5ey@clanunity.net> Volker Rattel
#################################################################
#-----[ EXAMPLE USAGE &#93;------------------------------------------
## <?php
## define&#40;'IN_PHPBB', true&#41;;
## include&#40;'phpbb_fetch_info.php'&#41;;
## $info = phpbb_fetch_info&#40;&#41;;
## 
?>

## Total Posts: <?php echo $info['f_total_posts'&#93;; ?><br>
## Total Users: <?php echo $info['f_total_users'&#93;; ?><br>
## Newest User: <?php echo $info['newest_username'&#93;; ?><br>
## Newest User ID: <?php echo $info['newest_userid'&#93;; ?><br>
## User Online: <?php echo $info['f_user_online'&#93;; ?><br>
#################################################################
$phpbb_root_path = './phpBB2/';
$CFG['close_db'] = 1;

if (!file_exists($phpbb_root_path . 'extension.inc')) {
    die('<b>phpBB Fetch Info:</b> The $phpbb_root_path setting is wrong and DOES NOT point to your forum.');
}
include_once ($phpbb_root_path . 'extension.inc');
include_once ($phpbb_root_path . 'common.'.$phpEx);

function phpbb_fetch_info()
{

    global $db;
    $info = array();
    $info['f_total_posts']     = get_db_stat('postcount');
    $info['f_total_users']     = get_db_stat('usercount');
    $newest_user             = get_db_stat('newestuser');
    $info['newest_userid']   = $newest_user[0];
    $info['newest_username'] = $newest_user[1];

    $sql = 'SELECT
              COUNT(session_id)
            FROM
              ' . SESSIONS_TABLE . '
            WHERE
              session_time >= ' . ( time() - 300 );

    if( !($result = $db->sql_query($sql)) ) {
        message_die(GENERAL_ERROR, 'Could not obtain user/online information', '', __LINE__, __FILE__, $sql);
    }

    $f_user_online = $db->sql_fetchrow($result);
    $info['f_user_online'] = $f_user_online[0];

    if ($CFG['close_db']) {
        $db->sql_close();
    }
    return $info;

} // phpbb_fetch_info

?>


Pages: [1] 2
Post your comments here