Page 8 of 11

Posted: Sat Nov 26, 2005 4:27 am
by igami
I dont need to assign different types in different forums, but thanks for the tip.

I just want it to work in my 2.018 :D I did removed the line you said to remove, but I am still seeing blanks - not sure if this is even related to that issue.

For me I can only get one topic to show the image and type name all the others are blank (no image no title). I went into sql and all of the topics show the correct type id, so I dont know why they arent displaying correctly in viewforum.

Posted: Sat Nov 26, 2005 6:00 am
by martin_uy
igami wrote: not sure if this is even related to that issue.

No, that is not related to the line I was talking about. If you don't remove the line you can't post any new topic with a specific topic type. However, those already posted are going to remain.

Not sure where is your problem. If you read this whole topic you can find some fix. It's likely your mod was not correctly installed or you didn't update the DB. If you install the 1.0.2 version you will not find major bugs.. I mean, you can use it but it still has some bugs.

Posted: Sat Nov 26, 2005 6:11 am
by igami
Yes, the sql has been updated, and Im pretty confident that I followed the instructions correctly. I just dont think it works smoothly with phpBB 2.018 ...

The MOD version I downloaded from post #1 is MOD Version : 1.0.1 ...
Where can I obtain 1.0.2 - maybe it works better?

Posted: Tue Nov 29, 2005 4:13 pm
by cklimas
Does somebody know why this mod isn't working with the ca_aphrodite skin? After I switch to that skin all page requests bekcome white (empty).

Has somebody a solution for the problem?

Regards chris.

Posted: Tue Nov 29, 2005 8:40 pm
by martin_uy
igami wrote: I just dont think it works smoothly with phpBB 2.018 ...
Yes, It works on phpbb 2.0.18 but you just have to do the change in the file I said. If you don't believe you can visit my site :lol:
igami wrote: The MOD version I downloaded from post #1 is MOD Version : 1.0.1 ...
Where can I obtain 1.0.2 - maybe it works better?
It's difficult to find version 1.0.2 but I can send it to you by mail. Just give it to me.

Code: Select all

##############################################################
## MOD History :
##
##   28-08-2004 - Version 1.0.2
##      - Fix an error when add a custom icon
##   28-08-2004 - Version 1.0.1 
##      - Replace font by span
##   21-08-2004 - Version 1.0.0 
##      - First Release
################################################################
Martin.

Posted: Wed Nov 30, 2005 1:09 am
by James78
2.0.18 compatible? At phpbbhacks.com it says this is for 2.0.10. The last one I installed wrecked my forum...

Posted: Wed Nov 30, 2005 1:51 am
by martin_uy
How many times must I say that this mod is phpBB 2.0.18 compatible? :lol: You just have to do 1 modification, remove one line as I said in another post.

Don't believe me? Ok, check http://www.uruguay.com.ru

I did other modifications just to fix some bugs, but they have nothing to do with the phpBB version. Even more, I ran this mod since I had phpBB 2.0.17 and it was 100% working. When I upgraded I corrected one line on the phpBB 2.0.18 and that was all :wink:

Posted: Thu Dec 01, 2005 6:57 am
by James78
martin_uy wrote: How many times must I say that this mod is phpBB 2.0.18 compatible? :lol: You just have to do 1 modification, remove one line as I said in another post.

Don't believe me? Ok, check http://www.uruguay.com.ru

I did other modifications just to fix some bugs, but they have nothing to do with the phpBB version. Even more, I ran this mod since I had phpBB 2.0.17 and it was 100% working. When I upgraded I corrected one line on the phpBB 2.0.18 and that was all :wink:

The sites not in English, I can't read it.

Posted: Thu Dec 01, 2005 4:44 pm
by martin_uy
James78 wrote: The sites not in English, I can't read it.
Yes I know but what matters is that you can see in the second forum the topic types working (with it's images). And the forum is 2.0.18.

Posted: Tue Jan 03, 2006 10:56 am
by Zoellner
martin_uy wrote: For example; if you want to add two topics types you will have to edit on posting.php and replace the string we are talking about with this one:

Code: Select all

$topic_type = ( in_array($topic_type, array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE, 20, 21 )) ) ? $topic_type : POST_NORMAL;
That's the only way I know how to solve this. I'm pretty sure there is another 'automatic' way; but don't worry the manual way works as it's supposed to work and have no security holes/bugs if you keep it updated with the number of the topic types you have :wink:


This is my solution for an 'automatic' way:

Code: Select all

#
#-----[ OPEN ]---------------------------------------------- 
# 

posting.php

#
#-----[ FIND ]---------------------------------------------- 
#  (This is the original line from phpbb 2.0.18!)

$topic_type = ( in_array($topic_type, array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE)) ) ? $topic_type : POST_NORMAL;

# 
#-----[ REPLACE WITH ]---------------------------------------------- 
# 

// Begin Advanced Topic Type
$all_topic_types = array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE);
$sql_tt = "SELECT * FROM ". TOPIC_ADD_TYPE_TABLE ." ORDER BY topic_type_order DESC";
$result_tt = $db->sql_query($sql_tt);
while( $add_type = $db->sql_fetchrow($result_tt) )
{
    $topic_add_type = intval( $add_type['topic_type_order'] + POST_ADD_TYPE );
 	$all_topic_types[] = $topic_add_type;
}
$topic_type = ( in_array($topic_type, $all_topic_types) ) ? $topic_type : POST_NORMAL;
// End Advanced Topic Type
If there is a better way, please let me know...

Greetings
Marc

Posted: Tue Jan 03, 2006 6:46 pm
by martin_uy
Yeap, I did something similar :)

Posted: Fri Jan 06, 2006 1:47 pm
by mfrankena
ok nice very nice mod.
After that last fix of Zoellner, it works finally. BUT it still is placing the topic on top of thread, when i selected it NOT to in the ACP.

How can i fix that ?

oh and when i select the same image to be used by different new types, it doesn't work. The first one uses the defined image, but the second new type automatically goes to the default image. In the ACP, it DOES accept the image setting, strangely enough.
Any idea?

Posted: Mon Jan 16, 2006 7:32 pm
by mfrankena
See above question
ANYONE ?????

Posted: Fri Feb 10, 2006 6:12 am
by PCGUY112887
What if I want this to work with the global announcement mod?

For the 2.0.18 update the global announcement forum said to do this line.

Code: Select all

$topic_type = ( in_array($topic_type, array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE, POST_GLOBAL_ANNOUNCE)) ) ? $topic_type : POST_NORMAL; 
You guys want me to remove it and put this for this mod.

Code: Select all

// Begin Advanced Topic Type
$all_topic_types = array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE);
$sql_tt = "SELECT * FROM ". TOPIC_ADD_TYPE_TABLE ." ORDER BY topic_type_order DESC";
$result_tt = $db->sql_query($sql_tt);
while( $add_type = $db->sql_fetchrow($result_tt) )
{
    $topic_add_type = intval( $add_type['topic_type_order'] + POST_ADD_TYPE );
    $all_topic_types[] = $topic_add_type;
}
$topic_type = ( in_array($topic_type, $all_topic_types) ) ? $topic_type : POST_NORMAL;
// End Advanced Topic Type
I can only manage to make 1 mod work at a time, and if I just put both pieces of code in then only Global Announcements works. What can I do?

Here is the link for the fix for the other mod.
http://mods.db9.dk/viewtopic.php?t=7218

Posted: Fri Feb 10, 2006 6:15 am
by PCGUY112887
Nevermind... had to just add "POST_GLOBAL_ANNOUNCE"

This is the new one for anyone else who may have my same problem with the Global Announcement Mod

Code: Select all

// Begin Advanced Topic Type
$all_topic_types = array(POST_NORMAL, POST_STICKY, POST_ANNOUNCE, POST_GLOBAL_ANNOUNCE);
$sql_tt = "SELECT * FROM ". TOPIC_ADD_TYPE_TABLE ." ORDER BY topic_type_order DESC";
$result_tt = $db->sql_query($sql_tt);
while( $add_type = $db->sql_fetchrow($result_tt) )
{
    $topic_add_type = intval( $add_type['topic_type_order'] + POST_ADD_TYPE );
    $all_topic_types[] = $topic_add_type;
}
$topic_type = ( in_array($topic_type, $all_topic_types) ) ? $topic_type : POST_NORMAL;
// End Advanced Topic Type