Save posts as drafts

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
Post Reply

Rating:

Excellent!
47
72%
Very Good
10
15%
Good
5
8%
Fair
1
2%
Poor
2
3%
 
Total votes: 65

anime_honeydew
Registered User
Posts: 11
Joined: Tue Sep 28, 2004 1:04 am

Post by anime_honeydew » Tue Sep 28, 2004 4:28 am

Ah! Regarding PM buttons, if you have PCP installed, you have to edit profilcp>profilcp_privmsg.php instead of privmsg.php.

sikita
Registered User
Posts: 47
Joined: Tue Jun 29, 2004 9:40 am

Post by sikita » Tue Sep 28, 2004 8:52 am

asinshesq wrote: For those of you who are using the attachment mod and the attachment mod fix for this mod llisted above, note that the original version of that fix that I posted on Saturday had a typo in it...I had incorrectly typed

Code: Select all

if ($result = 1)
rather than the correct

Code: Select all

if ($result == 1)
I edited my earlier post to fix this, but if you already implemented the fix on your board, please pick this up as well.


Thanx for your hard work and support...

sikita
Registered User
Posts: 47
Joined: Tue Jun 29, 2004 9:40 am

Post by sikita » Tue Sep 28, 2004 9:23 am

sikita wrote:
asinshesq wrote:For those of you who are using the attachment mod and the attachment mod fix for this mod llisted above, note that the original version of that fix that I posted on Saturday had a typo in it...I had incorrectly typed

Code: Select all

if ($result = 1)
rather than the correct

Code: Select all

if ($result == 1)
I edited my earlier post to fix this, but if you already implemented the fix on your board, please pick this up as well.


Thanx for your hard work and support...


Ohh... after I have made this change the attachment is lost during posting draft to regular post!

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Tue Sep 28, 2004 10:27 am

sikita wrote: ...
Ohh... after I have made this change the attachment is lost during posting draft to regular post!


I corrected myself right after the $result == 1 post at 8:30 last night. Go back to here and see the final fix, which does work:
http://www.phpbb.com/phpBB/viewtopic.ph ... 17#1256817

The difference? Instead of $result == 1, you need

Code: Select all

      $post_info = $db->sql_fetchrow($result);
      $post_attachment = $post_info['post_attachment'];
      if ($post_attachment == 1)
Meanwhile, I deleted the $result == 1 post to prevent others from doing the same thing.

sikita
Registered User
Posts: 47
Joined: Tue Jun 29, 2004 9:40 am

Post by sikita » Tue Sep 28, 2004 5:30 pm

Thanx everything seems to be fine...

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Tue Sep 28, 2004 6:22 pm

sikita wrote: Thanx everything seems to be fine...


Nice to hear...thanks for reporting back.

ycl6
Translator
Posts: 5696
Joined: Sat Feb 15, 2003 10:35 am
Location: Taiwan
Contact:

Post by ycl6 » Sun Oct 03, 2004 6:02 am

MOD Updated to version 1.0.14
See first post for Download Link

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Sun Oct 03, 2004 10:09 am

Unbelievable...I submitted this latest version just a few days ago (at most maybe a week ago) and the gang already validated it...thanks!

Version 1.0.14 (the version you will find in the first post on this thread) contains all the fixes that I have mentioned earlier in this thread, so if you use that version you don't have to make the various changes described earlier in this thread.

Enjoy.

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Mon Oct 04, 2004 7:41 pm

Sorry guys, but I found an error in the latest verson that can throw off the number of replies reported for a topic in the viewforum view if the topic has posts. Not a big deal, but it should be fixed since it can throw off pagination. Here's the fix:

Code: Select all

#
#-----[ OPEN]------------------------------------------------
#
includes/functions_admin.php

#
#-----[ FIND ]------------------------------------------------
#
				FROM " . POSTS_TABLE . "
				WHERE topic_id = $id";

#
#-----[ REPLACE WITH ]---------------------------------------- 
#
				FROM " . POSTS_TABLE . "  
				WHERE topic_id = $id
				AND post_draft = 0";
// start mod save posts as drafts (and end too)...added constraint that post_draft be 0 so that this function doesn't count drafts as posts in a topic or forum

[edit: fixed in current version]
Last edited by asinshesq on Wed Jan 12, 2005 3:06 pm, edited 1 time in total.

wGEric
Former Team Member
Posts: 8805
Joined: Sun Oct 13, 2002 3:01 am
Location: Friday
Name: Eric Faerber
Contact:

Post by wGEric » Wed Oct 06, 2004 9:49 pm

MOD Updated to version 1.0.15
See first post for Download Link

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Wed Oct 06, 2004 10:25 pm

Thanks for validating so quickly, mod team (I sent this in yesterday and they finished today!). Anyway, the link in the first post now gives you a download that covers all the changes reflected in this thread up to now.

Hope people find this as useful as I do!

Winky
Registered User
Posts: 39
Joined: Mon Sep 13, 2004 7:16 pm
Location: It

Post by Winky » Thu Oct 07, 2004 7:04 pm

:oops:
Sorry for my broken english, and my lameness


Gentleman, I installed the mod twice in my working forum(phpBB2.0.10) with a lot of mods and in a brand new phpbb installation 2.0.10 with just this gorgeous save drafts mod

seems that works perfectly, but, once I see my saved draft the first time, if for any reason I change the page, when i try to search for it againn i will find 1 result (just trying from a new user account) but it is impossible to see its link.

what i could have done wrong?


ty so much for help


ciao

have fun


Peace

Winky
Registered User
Posts: 39
Joined: Mon Sep 13, 2004 7:16 pm
Location: It

Post by Winky » Thu Oct 07, 2004 7:43 pm

.. another little question

Is it normal, when you save a draft message, than on the index, the last post counter, will tell that you were the last poster and increase it's count ? or did I something wrong?



(clicking on it will say that the message is not found)


will be possible not to show on that counter if someone posted a draft?




ty again


have fun

Andres

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Thu Oct 07, 2004 10:14 pm

Winky wrote: ...seems that works perfectly, but, once I see my saved draft the first time, if for any reason I change the page, when i try to search for it againn i will find 1 result (just trying from a new user account) but it is impossible to see its link.

what i could have done wrong?


Don't know what you did wrong, but it is NOT working correctly.

When you say you try to search for it again, do you mean that when you go back tp the index and click 'View my drafts and posts' the page does not show your draft? I just tried it again on my clean install and my modded board and it works fine on both...I can change the page and then come back by clicking the link and I always can find the draft again.

Or did you maybe mean something else?

asinshesq
Registered User
Posts: 6266
Joined: Sun Feb 22, 2004 9:34 pm
Location: NYC
Name: Alan

Post by asinshesq » Thu Oct 07, 2004 10:20 pm

Winky wrote: .. another little question

Is it normal, when you save a draft message, than on the index, the last post counter, will tell that you were the last poster and increase it's count ? or did I something wrong?
(clicking on it will say that the message is not found)
will be possible not to show on that counter if someone posted a draft?...


What last post counter do you mean? In an unmodded board I don't think there is any last post counter...do you have a mod that put a last post line in the index? If you have a mod that does that, it would need to be changed to ignore any drafts. If you find the code for the last post counter, you should be able to find the sql query where it finds the last post...in that query, you would need to add a line that says AND post_draft = 0 . If you pm me with the mod code I can probably help.

If on the other hand you mean that the last post indicated for each forum (to the right of the forum name) shows drafts, then that is not normal and it would mean that you have not followed all the steps to my mod. (My mod includes in each relevant sql for the index page the line AND post_draft = 0 in order to make sure that drafts get skipped.)

Hope this helps.

Post Reply

Return to “[2.0.x] MOD Database Releases”