 | [Solved] Keep Unread Flags mod |  |
Posted: 01/11/2007 10:51 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
I am ready to try this one but am a little confused. http://www.phpbb.com/phpBB/viewtopic.php?t=309059&start=0
Someone under it says....
Note that in the download you will find the basic mod as well as, in a 'contrib' folder, an upgrade mod that takes you from Ptirhiik's original version (1.0.0) to this one if you already have the old one installed plus a set of changed phpbb 2.0.17 files if your board is not modded and you prefer to simply install a new set of phpbb files that already have the mod installed.
I know not to use the changed files I'm modded. But am I to install the basic which is Ptirhiiks and then use the contrib file to upgrade it to the newer version? |
|
|
 |
 |
| Back to Top |
|
|
 | Re: Keep Unread Flags mod |  |
Posted: 01/12/2007 9:00 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 11:09 PM
Location: St Pete, FL
|

|
|
|
|
 |
Unless you have already installed this MOD, you only need to install the keep_unread_2-0-6.txt version using EM. Otherwise, you would find the appropriate Upgrade file stored in the Contrib folder to update your current Keep Unread Flags version up to the current version. This is not an easy MOD to install, so don't be surprised if you encounter many conflicts between the MOD script and your board code. KeeKee, I can help you through each problem that you encounter if need be...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/18/2007 7:56 PM |
|
|
|
|
|
| Caravan |
| Posts |
282 |
| Word Cnt. |
31,380 |
| BDay |
Apr 14 |
| Sign |
Aries |
| Sex |
 |
|
|
|
Joined: Nov 01, 2006
Local time: 11:09 PM
Location: Denver, PA
|

|
|
|
|
 |
I had a heck of a time with this mod. I first tried it on one of my boards that had about 35 mods already installed on it, and it was a no go. (for me at least, I should have come here for support)
When I started my new site I did this mod after only adding EM first. It went through EM ok, but we started having some major cookie issue's (I know now I probably could have taken care of those issue's with the auto cookies mod, but at the time didn't know that) and I ended up taking it off.
It was just over my head too much. I hope you have better luck! (with nightriders help I know you will) It sure is nice to have the flags working correctly. Too bad that's not a phpbb standard. |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/20/2007 5:07 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
O.K. Now that I am thourghly intimidated I will be installing this starting tonight we shall see. I'll probably be back. |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/20/2007 6:41 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
I'm baaaaaaak! I'm installing on the pasadena board
Here is the error...alot there for me.
FIND FAILED: In file [search.php] could not find:
if ( $search_id == 'newposts' )
{
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . POSTS_TABLE . "
WHERE post_time >= " . $userdata['user_lastvisit'];
}
else
{
redirect(append_sid("login.$phpEx?redirect=search.$phpEx&search_id=new posts", true));
}
$show_results = 'topics';
$sort_by = 0;
$sort_dir = 'DESC';
}
MOD script line #564 :: |
|
Last edited by KeeKee on 01/20/2007 6:54 PM; edited 1 time in total |
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/20/2007 6:53 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
It looks to me like this part is interrupting the mod...
// start mod save posts as drafts (and end mod too)...added constraint in the preceding line that post_draft be 0 so that draftws wouldn't get included
}
else
{ |
|
|
 |
 |
| Back to Top |
|
|
 | Re: Keep Unread Flags mod |  |
Posted: 01/20/2007 11:59 PM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 11:09 PM
Location: St Pete, FL
|

|
|
|
|
 |
The Save as Drafts MOD is causing the conflict. So try this:
OPEN
keep_unread_2-0-6.txt
FIND
| Code:
|
#
#-----[ FIND ]------------------------------------------------
#
if ( $search_id == 'newposts' )
{
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . POSTS_TABLE . "
WHERE post_time >= " . $userdata['user_lastvisit'];
}
else
{
redirect(append_sid("login.$phpEx?redirect=search.$phpEx&search_id=ne wposts", true));
}
$show_results = 'topics';
$sort_by = 0;
$sort_dir = 'DESC';
}
#
#-----[ REPLACE WITH ]----------------------------------------
#
if ( $search_id == 'newposts' )
{
//START MOD Keep_unread_2
$list_unreads = implode(',', array_keys(list_new_unreads($dummy, $toggle_unreads_link)));
$sql = "SELECT post_id, topic_id, forum_id, post_time
FROM " . POSTS_TABLE . "
WHERE ";//post_time >= " . $userdata['user_lastvisit'] ;
$sql .= ($list_unreads != '') ? " topic_id IN (" . $list_unreads . ")" : " topic_id=-1";
//END MOD Keep_unread_2
$show_results = 'topics';
$sort_by = 0;
$sort_dir = 'DESC';
}
|
REPLACE WITH
| Code:
|
#
#-----[ FIND ]------------------------------------------------
#
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . POSTS_TABLE . "
WHERE post_time >= " . $userdata['user_lastvisit'] . " AND post_draft = 0";
// start mod save posts as drafts (and end mod too)...added constraint in the preceding line that post_draft be 0 so that draftws wouldn't get included
}
else
{
redirect(append_sid("login.$phpEx?redirect=search.$phpEx&search_id=ne wposts", true));
}
#
#-----[ REPLACE WITH ]----------------------------------------
#
//START MOD Keep_unread_2
$list_unreads = implode(',', array_keys(list_new_unreads($dummy, $toggle_unreads_link)));
$sql = "SELECT post_id, topic_id, forum_id, post_time
FROM " . POSTS_TABLE . "
WHERE post_draft=0 AND";//post_time >= " . $userdata['user_lastvisit'] ;
$sql .= ($list_unreads != '') ? " topic_id IN (" . $list_unreads . ")" : " topic_id=-1";
//END MOD Keep_unread_2
|
Save, upload, and try again using EM...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/21/2007 2:06 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
Now....
| Code:
|
FIND FAILED: In file [search.php] could not find:
if ( $userdata['session_logged_in'] )
{
$sql = "SELECT post_id
FROM " . POSTS_TABLE . "
WHERE post_time >= " . $userdata['user_lastvisit'] . " AND post_draft = 0";
// start mod save posts as drafts (and end mod too)...added constraint in the preceding line that post_draft be 0 so that draftws wouldn't get included
}
else
{
redirect(append_sid("login.$phpEx?redirect=search.$phpEx&search_id=ne wposts", true));
}
|
|
|
|
 |
 |
| Back to Top |
|
|
 | Re: Keep Unread Flags mod |  |
Posted: 01/21/2007 3:07 PM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 11:09 PM
Location: St Pete, FL
|

|
|
|
|
 |
That problem was caused because there was an extra xpace introduced in the word newposts; i.e. ne wposts. That is now corrected...
Ok, this MOD is a mess. Since you have the Save Posts as Drafts MOD installed and since this MOD is trying to rewrite a large portion of the default code, I'm not sure how to integrate the Save Posts as Drafts with this MOD. I really don't like the way this MOD was written...
You might want to ask asinshesq and/or Merlin how to integrate this MOD to work with the Save Posts as Drafts MOD. I think Alan (asinshesq) might be willing to help...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: [Solved] Keep Unread Flags mod |  |
Posted: 01/21/2007 5:40 PM |
|
|
|
|
|
| Citation |
| Posts |
940 |
| Word Cnt. |
48,215 |
| BDay |
Mar 4 |
| Sign |
Pisces |
| Sex |
 |
|
|
|
Joined: Mar 20, 2006
Local time: 10:09 PM
|

|
|
|
|
 |
| OK, Thanks for trying I'll go look for them. |
|
|
 |
 |
| Back to Top |
|
|
 | Information |  |
|