The Forum has been Updated
The code has been upgraded to the latest .NET core version. Please check instructions in the Community Announcements about migrating your account.
My forum has a Topic titled "Welcome New Members"
Each week I add a Reply to my welcoming message, welcoming the most recent registrants. My Reply shows at the bottom of the page, when it would be most appropriate if it showed as the very first post.
Is there a way that I could make that one Topic reverse the entry order of posts? <
Each week I add a Reply to my welcoming message, welcoming the most recent registrants. My Reply shows at the bottom of the page, when it would be most appropriate if it showed as the very first post.
Is there a way that I could make that one Topic reverse the entry order of posts? <
نوشته شده در
well my changing 309ish in topic.asp from
strSql4 = " ORDER BY R.R_DATE ASC"
to
strSql4 = " ORDER BY R.R_DATE DESC"
the first post is first an all replies are in reverse order hope this helps<
strSql4 = " ORDER BY R.R_DATE ASC"
to
strSql4 = " ORDER BY R.R_DATE DESC"
the first post is first an all replies are in reverse order hope this helps<
نوشته شده در
If you just want it for the one forum
<
Code:
strSql4 = " ORDER BY R.R_DATE "
if Forum_ID = "ForumIDHere" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
_-/Cripto9t\-_
نوشته شده در
One topic among many.
Guess that won't work, eh?
phy1729 - I'm guessing that mod would apply to every topic in every forum?
cripto9t - Would that apply to all topic in just the one forum?
<
phy1729 - I'm guessing that mod would apply to every topic in every forum?
cripto9t - Would that apply to all topic in just the one forum?
<
"5-in-1 Snitz Common Expansion Pack" - five popular mods packaged for easy install
". . .on a mote of dust, suspended in a sunbeam. . ."
HarborClassifieds Support Snitz Forums
". . .on a mote of dust, suspended in a sunbeam. . ."
HarborClassifieds Support Snitz Forums
نوشته شده در
woudl somthign liek thsi not work...code may be different butim taking the abiove code
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "TopicIDHere" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
that way you wil be looking for that specific topic and it shodlnt mess with anythign else<
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "TopicIDHere" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
that way you wil be looking for that specific topic and it shodlnt mess with anythign else<
© 1999-2010 MaD2ko0l
نوشته شده در
mine applies to the entire board
cripto9t is just one forum
MaD2ko0l is one topic
and for sake of completion for just one category replace Topic_ID with Cat_ID .
<
cripto9t is just one forum
MaD2ko0l is one topic
and for sake of completion for just one category replace Topic_ID with Cat_ID .
<
نوشته شده در
Okay. . .for just one topic this modification has been made:
--------------------------------
end if
strSql3 = strSql3 & " OR R.R_AUTHOR = " & MemberID & ")"
end if
'#### topic mod ###
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "TOPIC_ID=111" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
'### end Topic Mod ###
if strDBType = "mysql" then 'MySql specific code
if mypage > 1 then
intOffset = cLng((mypage-1) * strPageSize)
strSql5 = " LIMIT " & intOffset & ", " & strPageSize & " "
end if
---------------------------
However, it's had no effect on the topic!
<
--------------------------------
end if
strSql3 = strSql3 & " OR R.R_AUTHOR = " & MemberID & ")"
end if
'#### topic mod ###
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "TOPIC_ID=111" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
'### end Topic Mod ###
if strDBType = "mysql" then 'MySql specific code
if mypage > 1 then
intOffset = cLng((mypage-1) * strPageSize)
strSql5 = " LIMIT " & intOffset & ", " & strPageSize & " "
end if
---------------------------
However, it's had no effect on the topic!
"5-in-1 Snitz Common Expansion Pack" - five popular mods packaged for easy install
". . .on a mote of dust, suspended in a sunbeam. . ."
HarborClassifieds Support Snitz Forums
". . .on a mote of dust, suspended in a sunbeam. . ."
HarborClassifieds Support Snitz Forums
نوشته شده در
try
if Topic_ID = "111" then<
if Topic_ID = "111" then<
نوشته شده در
Now that worked!
--------------------------------
end if
strSql3 = strSql3 & " OR R.R_AUTHOR = " & MemberID & ")"
end if
'#### Reverse Topic Order Mod ###
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "111" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
'### end Reverse Topic Order ###
if strDBType = "mysql" then 'MySql specific code
if mypage > 1 then
intOffset = cLng((mypage-1) * strPageSize)
strSql5 = " LIMIT " & intOffset & ", " & strPageSize & " "
end if
---------------------------
I'll use it just for welcoming new members since it's unlikely that they will think to use the "last post first" feature. But just for curiosity's sake, what if I wanted to apply the reverse topic order mod to more than one topic?<
end if
strSql3 = strSql3 & " OR R.R_AUTHOR = " & MemberID & ")"
end if
'#### Reverse Topic Order Mod ###
strSql4 = " ORDER BY R.R_DATE "
if Topic_ID = "111" then
strSql4 = strSql4 & "DESC"
else
strSql4 = strSql4 & "ASC"
end if
'### end Reverse Topic Order ###
if strDBType = "mysql" then 'MySql specific code
if mypage > 1 then
intOffset = cLng((mypage-1) * strPageSize)
strSql5 = " LIMIT " & intOffset & ", " & strPageSize & " "
end if
---------------------------
I'll use it just for welcoming new members since it's unlikely that they will think to use the "last post first" feature. But just for curiosity's sake, what if I wanted to apply the reverse topic order mod to more than one topic?<
نوشته شده در
coul not not just add and "or" statement onto it?? somthing like this
if Topic_ID = "111" or Topic_ID = "112" then
im sure that would work as well<
if Topic_ID = "111" or Topic_ID = "112" then
im sure that would work as well<
© 1999-2010 MaD2ko0l
نوشته شده در
If you plan to have a large number of topics that will be reversed in order *plus* a large number of topics that are in normal order, you could add a field to the database that is a simple boolean. Add it to the TOPICS table. Basically have it set as false by default (normal order), then write the code for an admin/moderator to be able to check a box that will reverse the order for that topic.
That actually sounds like a fairly useful MOD.... any takers? My plate is fairly full right now.<
That actually sounds like a fairly useful MOD.... any takers? My plate is fairly full right now.<
Bill Parrott
Senior Web Programmer, University of Kansas
Co-Owner and Code Monkey, Eternal Second Designs (www.eternalsecond.com)
Personal Website (www.chimericdream.com)
Senior Web Programmer, University of Kansas
Co-Owner and Code Monkey, Eternal Second Designs (www.eternalsecond.com)
Personal Website (www.chimericdream.com)
Email Member
Message Member
Post Moderation
بارگزاری فایل
If you're having problems uploading, try choosing a smaller image.
پیشنمایش مطلب
Send Topic
Loading...