Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 MOD: (Jump to) 1st New Post & Last Post of Topic
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

work mule
Senior Member

USA
1358 Posts

Posted - 27 May 2001 :  05:25:18  Show Profile
JUMP TO 1ST NEW POST & LAST POST OF TOPIC

May 27, 2001
This MOD allows the forum user to jump directly to the first unread/new post or the last post of a topic. This is based upon the functionality seen on other forum products and has now been assimilated into the Snitz collective.

DEMO:
Main Board then click on the forum titled: A is for Apple
(a simple demo for a simple mod)

DOWNLOAD:
jumpto_new_and_old_posts.zip

The download file includes instructions and the two arrow graphics.

The new post (blue) arrow only appears if the last topic date is greater than the last visit date stored in the session object. The last post link is always visible.

For mySQL users, this mod will probably not work for you at this time. Sorry. If someone, who is familiar with mySQL, could take a look at this, I would appreciate it.

The topic paging and sorting mod can be found here.


"Do not go where the path may lead, go instead where there is no path and leave a trail."

-Ralph Waldo Emerson

Edited by - work mule on 28 May 2001 10:00:45

tteal
Junior Member

USA
438 Posts

Posted - 27 May 2001 :  17:21:20  Show Profile  Visit tteal's Homepage  Send tteal an AOL message  Send tteal an ICQ Message
Get this error: Microsoft VBScript runtime error '800a01a8'

Object required: 'my_Conn'

/demo/sf2000_v3sr4_paging/inc_functions.asp, line 634


Cheers,
Tim

"The famous hosting provider hosting the Famous Snitz Forums!"
Drop me an email and find out about hosting your snitz forum too!
http://www.bandwidthunlimited.net
http://www.free-guestbook.com
http://www.tealnet.com
Go to Top of Page

Flaimo
New Member

Austria
72 Posts

Posted - 27 May 2001 :  21:08:22  Show Profile  Visit Flaimo's Homepage  Send Flaimo an AOL message  Send Flaimo an ICQ Message  Send Flaimo a Yahoo! Message
couldn't test it much, but it seems to work fine on my board. thanks for the mod!

flaimo,

http://flaimo.com/famousfonts
Go to Top of Page

Freeman II
Junior Member

232 Posts

Posted - 28 May 2001 :  01:09:03  Show Profile
work mule
nice mod this is exactly what i was talking about =)

could you make the last post link visible in default.asp
like in VBB2.0

Go to Top of Page

Freeman II
Junior Member

232 Posts

Posted - 28 May 2001 :  01:33:19  Show Profile
Error Type:
Microsoft VBScript runtime (0x800A01A8)
Object required: 'my_Conn'
inc_functions.asp, line 635



Edited by - freeman ii on 28 May 2001 01:50:21
Go to Top of Page

Dan03
Starting Member

Australia
17 Posts

Posted - 28 May 2001 :  01:48:52  Show Profile  Send Dan03 an AOL message  Send Dan03 an ICQ Message
quote:

Get this error: Microsoft VBScript runtime error '800a01a8'

Object required: 'my_Conn'

/demo/sf2000_v3sr4_paging/inc_functions.asp, line 634


Cheers,
Tim



If you navigate to the correct forum and topic manually, you can bypass this error. But yes, this does occur...

And BTW - when I tested it, it didn't quite take me to the bottom on the page. I still had to scroll down...

- Dan.
_______________________________
http://www.zer03.com/
Go to Top of Page

Flaimo
New Member

Austria
72 Posts

Posted - 28 May 2001 :  10:22:33  Show Profile  Visit Flaimo's Homepage  Send Flaimo an AOL message  Send Flaimo an ICQ Message  Send Flaimo a Yahoo! Message
ok, first problmen: work on my computer with W2K and IIS5 but not on an older NT4 with IIS4.


Kompilierungsfehler in Microsoft VBScript-Fehler '800a0400'

Anweisung erwartet

/forum/topic.asp, Zeile 134

with rs
^


now, that's this code:


'##### Jump to Last Post MOD (May 27, 2001) #####
totalreplies = rs.Recordcount
Select Case request("jump")
Case "lastpost"
rs.absolutepage = maxpages
mypage = maxpages
Case "newpost"
with rs
if .recordcount <> 0 then
'set recordset filter
.filter = ("R_DATE > '" & lastDate & "'")
if .recordcount = 1 then
.movefirst
newrecpos = .absoluteposition
if ((newrecpos mod strPageSize) > 0) then
mypage = Int(Abs(newrecpos/strPageSize))+1
else
mypage = Int(Abs(newrecpos/strPageSize))
end if
end if
end if
'take out filter
.filter = ""
end with
rs.absolutepage = mypage
Case Else
rs.absolutepage = mypage
End Select
'##### Jump to Last Post MOD #####
Go to Top of Page

work mule
Senior Member

USA
1358 Posts

Posted - 28 May 2001 :  10:25:11  Show Profile
In regards to the error with the demo link, I don't know why it's doing that. Like a couple of you suggested, if you go to the main board, and then navigate down, it'll work. I modified the demo link in the original post to get people to go in that way. Thanks for letting me know.

I have the # of topics per page set low for the paging demo and the topics were short so the anchor link didn't bring it right up to the top. It's a quirky thing. I added two deeper topics to the topic titled "A popular topic - many replies" to provide a better example. If you shorten up your browser window for the demo, it'll work better.

I have some more work to do to get this on the default page. The problem is that I don't know which topic was last updated. The only thing recorded in the Forum table is the last post date. So either the topic id has to be recorded in the forum table or I have to create a page similiar to links.asp but it would have to look up the topic id for that forum. I haven't decided which is the best option.


"Do not go where the path may lead, go instead where there is no path and leave a trail."

-Ralph Waldo Emerson
Go to Top of Page

Flaimo
New Member

Austria
72 Posts

Posted - 28 May 2001 :  13:22:33  Show Profile  Visit Flaimo's Homepage  Send Flaimo an AOL message  Send Flaimo an ICQ Message  Send Flaimo a Yahoo! Message
the problem is, i can't let people go through the default.asp page because i also use the syntication mod.

http://forum.snitz.com/forum/topic.asp?TOPIC_ID=7174&FORUM_ID=25&CAT_ID=17&Topic_Title=Mod%3A++Syndication&Forum_Title=MOD+Add%2DOn+Forum+%28W%2FCode%29


that's why i can't prevent this Object required: 'my_Conn' error, that also comes up with the topic sorting mod this way.
Go to Top of Page

Freeman II
Junior Member

232 Posts

Posted - 28 May 2001 :  21:30:00  Show Profile
work mule

when i installed your mod i get this
Get this error: Microsoft VBScript runtime error '800a01a8'

Object required: 'my_Conn'

_functions.asp, line 634



Go to Top of Page

lcs78816
Junior Member

195 Posts

Posted - 29 May 2001 :  19:51:20  Show Profile
lol--
now Snitz looks so similiar to VBulletin now..

Go to Top of Page

work mule
Senior Member

USA
1358 Posts

Posted - 29 May 2001 :  20:33:34  Show Profile
quote:

ok, first problmen: work on my computer with W2K and IIS5 but not on an older NT4 with IIS4.



It's working with PWS and Win98. I didn't get the chance to test this at work with NT4 and IIS4. I wouldn't see why it wouldn't work. We've done "with xxxx" (where xxxx is an object) type of code before. That could probably be rewritten though if that was the problem, which I'm not disputing, but I can't explain the error.

--The Writer Community

"Do not go where the path may lead, go instead where there is no path and leave a trail."

-Ralph Waldo Emerson
Go to Top of Page

work mule
Senior Member

USA
1358 Posts

Posted - 29 May 2001 :  21:33:33  Show Profile
quote:

when i installed your mod i get this
Get this error: Microsoft VBScript runtime error '800a01a8'

Object required: 'my_Conn'

_functions.asp, line 634




DOH!

I totally apologize for the mistake. It's so obvious now.

Here's the problem, when I'm looking for the lastdate, sometimes the code uses the function, ReadLastHereDate, which requires the connection object, my_Conn. Well the problem is that this variable section is placed before the include for inc_top.asp where the connection object is created. So when the function is called, the connection object doesn't exist yet, thus the error.

To fix the problem, the block of code for the variables should be moved directly after the inc_top.asp include!

forum.asp - @Line 152
topic.asp - mine is @Line 152

I had totally missed this because I'm used to working on my forum code for The Writer and I have the code for the connection object outside of the inc_top.asp file.

Let me know if this fixes everyone's problem or if there's something else I'm missing here.

--The Writer Community

"Do not go where the path may lead, go instead where there is no path and leave a trail."

-Ralph Waldo Emerson
Go to Top of Page

Flaimo
New Member

Austria
72 Posts

Posted - 29 May 2001 :  23:40:27  Show Profile  Visit Flaimo's Homepage  Send Flaimo an AOL message  Send Flaimo an ICQ Message  Send Flaimo a Yahoo! Message
i still get the "with rs" error on the server of my provider. could it be that this only works with IIS5?

oh, and those arrows would also be very useful on the active.asp page
Go to Top of Page

work mule
Senior Member

USA
1358 Posts

Posted - 29 May 2001 :  23:54:22  Show Profile
quote:

i still get the "with rs" error on the server of my provider. could it be that this only works with IIS5?



I'll try this out tomorrow while I'm at work and let you know. We are using IIS4 there. I really wouldn't think so becuase I'm running this on PWS.

quote:

oh, and those arrows would also be very useful on the active.asp page



noted!

--The Writer Community

"Do not go where the path may lead, go instead where there is no path and leave a trail."

-Ralph Waldo Emerson
Go to Top of Page

e3stone
Average Member

USA
885 Posts

Posted - 10 June 2001 :  18:31:31  Show Profile  Send e3stone an AOL message
I can't get mine to position itself on the last post. The new post option works, but the "last post" option just takes you to the last page at the top. (plus the page # still says page 1) check it out on my forum: http://www.insidewaco.com/forum/forum.asp?FORUM_ID=2&CAT_ID=1 I can't figure out what's wrong. Here's my topic.asp page: http://www.insidewaco.com/forum/topic.txt

this is the link I have on forum.asp:
<!-- Jump to Last Post --><a href="topic.asp?jump=lastpost&TOPIC_ID=<% =rs("TOPIC_ID") %>&FORUM_ID=<% =Request.QueryString("FORUM_ID") %>&CAT_ID=<% =Request.QueryString("CAT_ID") %>&Topic_Title=<% =ChkString(left(rs("T_SUBJECT"), 50),"urlpath") %>&Forum_Title=<% =ChkString(Request.QueryString("FORUM_Title"),"urlpath") %>#lastpost"><img border="0" width="10" height="9" alt="Go To Last Post" src="lastpost.gif"></a>


<-- Eric -->


InsideWaco.com
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.2 seconds. Powered By: Snitz Forums 2000 Version 3.4.07