• [MOD] Last comments v1.2.0 4 0 5 1
Currently:  

Author Topic: [MOD] Last comments v1.2.0  (Read 235594 times)

0 Members and 1 Guest are viewing this topic.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [MOD] Last comments v1
« Reply #75 on: December 24, 2005, 07:38:43 PM »
Ok, can you confirm/deny if replacing in index.php
Code: [Select]
$sql = "SELECT c.image_id, c.comment_id, c.user_id as comment_user_id, c.user_name as guest_user_name, c.comment_headline, c.comment_text, c.comment_date, i.cat_id, i.user_id, i.image_name, i.image_media_file, i.image_thumb_file".get_user_table_field(", u.", "user_name").get_user_table_field(", s.", "user_name")." as comment_user_namewith:
Code: [Select]
$sql = "SELECT c.image_id, c.comment_id, c.user_id as comment_user_id, c.user_name as guest_user_name, c.comment_headline, c.comment_text, c.comment_date, i.cat_id, i.user_id, i.image_name, i.image_media_file, i.image_thumb_file".get_user_table_field(", u.", "user_name")." as user_name".get_user_table_field(", s.", "user_name")." as comment_user_namewould fix it.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline pht3k

  • Pre-Newbie
  • Posts: 8
    • View Profile
Re: [MOD] Last comments v1
« Reply #76 on: December 24, 2005, 10:37:59 PM »
yessssssss

it'S working !!!!

its my first present for christmas this year :)
thanks a lot. 

Have nice hollidays !!!
pht3k



Offline Zyga

  • Jr. Member
  • **
  • Posts: 87
    • View Profile
Re: [MOD] Last comments v1
« Reply #77 on: December 27, 2005, 10:51:17 PM »
what with comments like

"yeaaaaaaaaaaaaaaaaaaaaahhhhhhh...... "

can i wrap it ?

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [MOD] Last comments v1
« Reply #78 on: December 28, 2005, 01:31:50 AM »
what with comments like

"yeaaaaaaaaaaaaaaaaaaaaahhhhhhh...... "

can i wrap it ?
mmm...actualy this mod is using word wrap settings from your 4images settings...
if you want make it independent from the rest of the comments, replace $config['wordwrap_comments'] with the number of characters per line you wish in these two lines from Step 1
Code: [Select]
    "comment_headline" => format_text($row['comment_headline'], 0, $config['wordwrap_comments'], $config['bb_comments'], 0, 1),
    "comment_text" => format_text($text, $config['html_comments'], $config['wordwrap_comments'], $config['bb_comments'], $config['bb_img_comments'], 1, 0),
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Zyga

  • Jr. Member
  • **
  • Posts: 87
    • View Profile
Re: [MOD] Last comments v1
« Reply #79 on: December 28, 2005, 05:22:56 PM »
THX !
Its what I need.  :)

Offline chip

  • Newbie
  • *
  • Posts: 33
    • View Profile
    • pixelmall.de
Re: [MOD] Last comments v1
« Reply #80 on: January 15, 2006, 10:32:16 PM »
Hi everyone,

Thanks V@no for this one  :).


I have a problem with not logged in visitors. My entire "last comments box" shows up for visitors only on one condition, if I give all the right to view image details in the category settings of ACP.

I actually don't want to give visitors the right to view image details, but still want to display the last comments with thumbs on my home.html page.

So my question: is the mod supposed to work like this (not showing up for visitors without the right to look at details), or did I miss something in the installation?


Thanks.

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [MOD] Last comments v1
« Reply #81 on: January 15, 2006, 10:44:52 PM »
Yes, it supposed to work like that, because if you think about it, how guest would possible read the comments if they have no access to the image?
but surely you can change that by removing this code in red:
Quote
        WHERE i.image_active = 1 AND i.image_allow_comments = 1 AND i.cat_id NOT IN (".get_auth_cat_sql('auth_readcomment', 'NOTIN').") AND i.cat_id NOT IN (".get_auth_cat_sql('auth_viewcat', 'NOTIN').") AND i.cat_id NOT IN (".get_auth_cat_sql('auth_viewimage', 'NOTIN').")
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline chip

  • Newbie
  • *
  • Posts: 33
    • View Profile
    • pixelmall.de
Re: [MOD] Last comments v1
« Reply #82 on: January 16, 2006, 01:31:33 AM »
again, thanks V@no


I'll remove the code you recommended, because if visitors can view details there is no advantage of registering at my site.


Offline anderitor

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: [MOD] Last comments v1
« Reply #83 on: February 22, 2006, 09:40:09 PM »
When I install this mode, I get an error:

Parse error: parse error, unexpected '<' in /usr/export/www/vhosts/funnetwork/hosting/kl102/Bilder/images/includes/template.php(101) : eval()'d code on line 99

What can I do?

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [MOD] Last comments v1
« Reply #84 on: February 23, 2006, 12:59:16 AM »
Restore backups and try again.
Make sure you upload .php and .html files in ACSII mode and not in BINARY
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

Offline Nasser

  • Full Member
  • ***
  • Posts: 105
    • View Profile
Re: [MOD] Last comments v1
« Reply #85 on: April 18, 2006, 07:11:09 PM »
is there is an option that says to the member you have XX comments on your images since last visit ?

Offline IWS_steffen

  • Full Member
  • ***
  • Posts: 128
    • View Profile
    • Kreuzfahrtschiffe gestern und heute
Re: [MOD] Last comments v1
« Reply #86 on: April 18, 2006, 09:21:00 PM »
thanks V@no

thank you very much!!!

I got this now

Steffen

Offline live@ct

  • Sr. Member
  • ****
  • Posts: 348
    • View Profile
Re: [MOD] Last comments v1
« Reply #87 on: May 10, 2006, 04:08:36 AM »
how can I integrate this script to cut the last comments in a numbers of characters

I found this code

Code: [Select]
function limit_string($cadena,$limite)
{
    $cadena=explode('<rup> ',wordwrap( $cadena, $limite,'<rup>'));
    return $cadena[0]."...";
}

$cadena="Este es un texto de prueba para ver el funcionamiento de la funcion
de cortar el texto sin cortar las palabras";

echo limit_string($cadena,50);
Existen 10 tipos de personas, los que entienden el codigo binario y los que no.

Offline Buspilotin

  • Newbie
  • *
  • Posts: 24
    • View Profile
    • http://www.buspilotin.de
Re: [MOD] Last comments v1
« Reply #88 on: June 04, 2006, 05:37:00 PM »
very good mod, thankyou!!!!
Nicht überall wo Neoplan drauf steht ist auch Neoplan drinn!

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: [MOD] Last comments v1
« Reply #89 on: June 04, 2006, 08:15:08 PM »
@live@act:
look in the code from Step 1:
Code: [Select]
$text_len = 200; //max lenght of the text to show (bbcode and html are counted too)
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)

 

Post your comments here