DBS File For Important Topics Mod
[ALTER]
TOPICS
ADD#T_FLAG#int#NULL#
[END]Originally posted by Jezmeister
Also you might want to note that it's not MySql friendly asis, I'll have a go at installing it later - looks good!
Originally posted by modifichiccidon't know if anyone would want to 'mark' topic that are archived ? (i.e. 'old' )<
Don't forget to update A_TOPICS and admin_forums also, to let archive functions working...
Originally posted by Jezmeister
Also you might want to note that it's not MySql friendly asis, I'll have a go at installing it later - looks good!
if strDBType = "mysql" then
strITop2 = "select * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
strITop2 = strITop2 & " LIMIT 10 "
else
strITop2 = "select top 10 * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
end if
Set strITop = my_Conn.Execute(strITop2)
Originally posted by JezmeisterThat's what the TopSQL funcion from inc_func_common.asp is for...
AAAAAHH!!! Not MySQL-friendly? =)
What would cause problems? Can anyone do the required changes to make it work with MySQL?
well the specific thing I noticed was that you used "TOP" in your query - MySql doesn't support that... eg if you added this into inc_header.asp instead you could call the code from any part of the site:Code:if strDBType = "mysql" then
strITop2 = "select * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
strITop2 = strITop2 & " LIMIT 10 "
else
strITop2 = "select top 10 * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
end if
Set strITop = my_Conn.Execute(strITop2)
if strDBType = "mysql" then
strITop2 = "select * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
strITop2 = strITop2 & " LIMIT 10 "
else
strITop2 = "select top 10 * from " & strTablePrefix & "topics where t_flag >0 order by t_flag desc"
end if
Set strITop = my_Conn.Execute(strITop2)strITop2 = "SELECT FROM " & strTablePrefix & "TOPIC WHERE T_FLAG > 0 ORDER BY T_FLAG DESC"
strITop2 = TopSQL(strITop,10)
Set strITop = my_Conn.Execute(strITop2)Originally posted by OneWayMule
That's what the TopSQL funcion from inc_func_common.asp is for...[/code]