News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Merge Double Posts By Same Member

Started by ディン1031, June 11, 2005, 04:54:02 PM

Previous topic - Next topic

ディン1031

#140
hmmm which forum version?

hmmm idea... hmmm only a idea...

Search for in SplitTopic.php

// Merge the post ;)
db_query("
UPDATE {$db_prefix}messages
SET body = '{$newbody}' $oldsubject
WHERE ID_MSG = $newpostid
LIMIT 1", __FILE__, __LINE__);

replace with...

// Merge the post ;)
db_query("
UPDATE {$db_prefix}messages
SET body = '".mysql_escape_string($newbody)."' $oldsubject
WHERE ID_MSG = $newpostid
LIMIT 1", __FILE__, __LINE__);


but it's untested only a first thought to clear the problem... normal it should not happend because the msg are already preparsed from smf...

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

littleone

I'll give it a try and let you know if it works.  I am using 1.1 RC2

Thanks

littleone

#142
Well it fixed the original problem but now it puts { in front of the first post and } at the end of the second post like so:

{test
Posted on: July 10, 2006, 03:37:51 PM
------------------------------------------------------------------
test}

ディン1031

#143
Quote from: littleone on July 10, 2006, 04:39:12 PM
Well it fixed the original problem but now it puts { in front of the first post and } at the end of the second post like so:

{test
Posted on: July 10, 2006, 03:37:51 PM
------------------------------------------------------------------
test}
lol sorry i forgot something to remove xD


db_query("
UPDATE {$db_prefix}messages
SET body = '".mysql_escape_string($newbody)."' $oldsubject
WHERE ID_MSG = $newpostid
LIMIT 1", __FILE__, __LINE__);


At the evening i will test it myself, if it happen only in rc2 i will make a update :D.

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

littleone

Thanks I appreciate it.  I figured that it might have been to remove those.  But I was to afraid to screw everything up.  I have made big boo boos before.  Appreciate it ;)

LHW

I'm not sure if this is the proper place to ask this, so I apologize if I should've started a new support thread on this.

We're running SMF v1.0.7, and this mod installed perfectly...works great, by the way.  :)  We're running it with the date / time stamp enabled, and would like to customize it a little.

Right now, it looks like this:

End of first post.
Date Posted: Aug 14, 2006, 02:36:18 PM




We'd like to have it look something like this:

End of first post.



Date Posted: Aug 14, 2006, 02:36:18 PM




We'd like to add a line-break and another HR before the date / time stamp, make it bold, and change the color so it stands out more.  Can someone tell me where / what I'd need to edit to do this?

Thank you kindly!  :)


ディン1031

Quote from: Essential Knight on August 16, 2006, 04:31:34 PM
I'm not sure if this is the proper place to ask this, so I apologize if I should've started a new support thread on this.

We're running SMF v1.0.7, and this mod installed perfectly...works great, by the way.  :)  We're running it with the date / time stamp enabled, and would like to customize it a little.

Right now, it looks like this:

End of first post.
Date Posted: Aug 14, 2006, 02:36:18 PM




We'd like to have it look something like this:

End of first post.



Date Posted: Aug 14, 2006, 02:36:18 PM




We'd like to add a line-break and another HR before the date / time stamp, make it bold, and change the color so it stands out more.  Can someone tell me where / what I'd need to edit to do this?

Thank you kindly!  :)

Simple ;)

Search in the SplitTopics.php for


$newbody = $msn['0']['body'].(empty($modSettings['MergePost_NoHR']) ? (empty($modSettings['MergePost_OldTimeAdd']) ? '[br][size=1]'.$txt['search_date_posted'].': '.$msn['0']['Time'].'[/size]' : '').'[hr]' : '[br]').$msn['1']['body'];


and replace it with

$newbody = $msn['0']['body'].(empty($modSettings['MergePost_NoHR']) ? (empty($modSettings['MergePost_OldTimeAdd']) ? '[br][b][color=red][size=1]'.$txt['search_date_posted'].': '.$msn['0']['Time'].'[/size][/color][/b]' : '').'[hr]' : '[br]').$msn['1']['body'];


The change was there -> '[br][b][color=red][size=1]'.$txt['search_date_posted'].': '.$msn['0']['Time'].'[/size][/color][/b]' ... some time in the future i will add a textfeld to made a small editable way of this part... (when i got some time <<... but currently i see no light for the time...).

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

LHW

Sweet.  Thanks, chief!  It's greatly appreciated.   :D :D


pcigre



LostProphecy

i'm not sure if this has already been brought up before but is there a way of setting the mod up so that it does not merge the double postings of a particular staff group... i know that you can set it so that it doesn't merge admin posts but what about other groups?

if i say wants to have all group=3 posts not merged is there a way of doing this??
Angelus Ex Quo Nox

ディン1031

#151
Possible yes, because there is option to ignore Admin post in doubleposting hmmm i think i must look what is to change to made it workable. XD

Subs-Post.php

if(!empty($modSettings['MergePost_Automatic']) && !($user_info['is_admin'] && empty($modSettings['MergePost_AdminDoublePost']))) {

This Code is don't merge the admin posts if the Admin Double Post Option is set, nomal there you cann something like $user_info['is_mod'] to find the moderator of this board, or in_array('2', $user_info['groups']) for global mods.

Example for the Replacment

if(!empty($modSettings['MergePost_Automatic']) && !(($user_info['is_admin'] || $user_info['is_mod'] || in_array('2', $user_info['groups'])) && empty($modSettings['MergePost_AdminDoublePost']))) {

So now it would not automerge admin, mods and gmods post. As long the option enabled for not merging admin posts xD.

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

HecKel

If you want, here it is the Portuguese strings

index.portuguese.php
$txt['merge_doublepost'] = 'Posts Duplos';
$txt['merge_error_dbpo'] = 'Não tem permissões para fazer isto!';
$txt['merge_error_notf'] = 'Não foram encontrados Posts para juntar.';
$txt['merge_error_noid'] = 'O ID da Mensagem ou do Topic não foi encontrado!';
$txt['search_date_posted'] = 'Posted on';
$txt['merge_error_lenth'] = 'O post unico ultrapassou o tamanho máximo de um post!';


ModSettings.portuguese.php
$txt['MergePost_Headline'] = 'Post duplo';
$txt['MergePost_Automatic'] = 'Unir automáticamente os novos posts duplos';
$txt['MergePost_AutomaticTime'] = 'Tempo entre posts com união automática, em segundos.<font size=1>(<b>0 = sempre</b>)</font>';
$txt['MergePost_AdminDoublePost'] = 'Merge new "Admin" doubleposts';
$txt['MergePost_OldTimeAdd'] = 'Não adicionar o tempo antigo, antes da linha [hr] do novo post';
$txt['MergePost_NoHR'] = 'Não mostrar a linha de divisão nem data no novo post unido';
$txt['MergePost_IgnorePostLenth'] = 'Ignorar o tamanho máximo do post';


I think that is ok, one string I dont' understand the real meaning...

HecKel
Quote from: Eliana Tamerin on August 23, 2008, 04:10:10 PM
SMF 7 is where it gets good. That has time travel. You can go back and post before the guy who flamed you. :P

ディン1031

$txt['search_date_posted'] = 'Posted on';
This is when the old post is made, if the option is enabled to show the old post time of the post.

Bye
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

HecKel

So, I think that in Portuguese is something like this:

$txt['search_date_posted'] = 'Postado em';

But, this is my big confusion :P

$txt['MergePost_AdminDoublePost'] = 'Merge new "Admin" doubleposts';

HecKel
Quote from: Eliana Tamerin on August 23, 2008, 04:10:10 PM
SMF 7 is where it gets good. That has time travel. You can go back and post before the guy who flamed you. :P

J. Williams

I would expect that means it'll merge any administrator's posts that are double :P
Joshua Jon Williams
Back in Action.

Gobo

1.1 Final is out :D

Looking forward to the 1.1 compatible mod :D

J. Williams

Quote from: akulion on December 04, 2006, 06:05:59 AM
1.1 Final is out :D

Looking forward to the 1.1 compatible mod :D

Its been a month since activity in this thread which I assume lowers the chance of it being updated for use with 1.1 Final and above.
Joshua Jon Williams
Back in Action.

Gobo

oh i already updated it :D
http://path-to-peace.com/forum/Packages/DoublePostMerge106.zip

but keep in mind this isnt the official release by the author this is just a "make shift" thingie - works perfectly though :)

ディン1031

Package is now 1.1 Final Compatible an installable :).

Gruß
DIN1031
Support only via MOD Thread! NO PM Support!
My Forum: ayu][kult Forum
My Mods: My Small Mod Collection
My Parser: DIN1031's ModParser
Current Info: More away the next days, because i've to much work to do :x

Advertisement: