Our website uses cookies to personalise content, keep contents in your shopping cart and as part of the checkout experience.
Your personal information you provide will be transfered and stored as encrypted data.
You have the ability to update and remove your personal information.
You consent to our cookies if you continue to use this website.
Allow cookies for
Necessary Cookies Necessary Cookies cannot be unchecked, because they are necessary for our website to function properly. They store your language, currency, shopping cart and login credentials.
Analytics Cookies We use google.com analytics and bing.com to monitor site usage and page statistics to help us improve our website. You may turn this on or off using the tick boxes above.
Marketing Cookies Marketing Cookies do track personal data. Google and Bing monitor your page views and purchases for use in advertising and re-marketing on other websites. You may turn this on or off using the tick boxes above.
Social Cookies These 3rd Party Cookies do track personal data. This allows Facebook, Twitter and Pinterest integration. eg. shows the Facebook 'LIKE' button. They will however be able to view what you do on our website. You may turn this on or off using the tick boxes above.
simian110% MONKEY EVERY TIME ALL THE TIME JUST CANT STOP THE MONKEY 3,149 posts Location: London
Posted: can i link to the most recent post in a thread?
eg. a link that when people click on it will take them to the most recently posted reply in a particular thread. Rather than a link to the reply that is currently the most recent, but then won't be after someone else posts another one after it. Er. Yeah. That mostly made sense.
First helpful answer will WIN this fantabulous hug --->
"Switching between different kinds of chuu chuu sometimes gives this "urgh wtf?" effect because it's giving people the phi phenomenon."
Fire_MooseSILVER Member Elusive and Bearded 3,597 posts Location: Scottsdale, AZ, USA
Posted: No.
i actually dont know but assume no, i just wanted to hug a monkey
O.B.E.S.E.
Owned by Mynci!
RicheeBRONZE Member HOP librarian 1,841 posts Location: Prague, Czech. Republic
Posted: When you link a thread, but not the whole URL,
only to "..number=245252". Than the link will
jump to the first post of the thread.
hug for free,
:R
POI THEO(R)IST
simian110% MONKEY EVERY TIME ALL THE TIME JUST CANT STOP THE MONKEY 3,149 posts Location: London
Posted: but thats the first post - i want to go to the last post
"Switching between different kinds of chuu chuu sometimes gives this "urgh wtf?" effect because it's giving people the phi phenomenon."
UCOFSILVER Member 15,417 posts Location: South Wales
Posted: [Old link] (cept that will link to your post, rather than this one)
Well.. actually.. I dont know.
Im not sure how you find the post number out to link to it anyway.. Perhaps ask Dom to do some typing perhaps?
RicheeBRONZE Member HOP librarian 1,841 posts Location: Prague, Czech. Republic
Posted: Check yer PM.
light,
:R
POI THEO(R)IST
pkBRONZE Member Lambretta Fanatic 4,998 posts Location: United Kingdom
Posted: IMHO this is possible... as I will try to explain my reasons.
The site uses a SQL database... this is OK and can support quite large forums as we well know over the years and all thanks to Dom's input there in helping Malcolm getting it up and running.
A post is entered in to the database under a "post table" and that then references to a "tread table", also in that data there is the "poster", "date", "time" etcetera to link that post to what ever forum and thread it has to belong to.
So if:
forum = 34
Thread = 23798
Post = 2332484
That could be any thing!.
When a thread is made it creates a new reference in the SQL DB, so if 2345 was the last a new one would be 2346... the same goes for a POST, the post reference number will be entered in sequential form.
if ( isset($HTTP_GET_VARS['move']) && 'next' == $HTTP_GET_VARS['move'] ) {
$sql = 'SELECT t.topic_id, t.topic_title, t.topic_time, t.topic_status, t.topic_sticky, t.topic_last_post_id, f.forum_id, f.forum_name, f.forum_access, f.forum_type, f.allow_html, f.allow_sig, f.posts_per_page, f.hot_threshold, f.topics_per_page FROM '.$xoopsDB->prefix('forum_topics').' t LEFT JOIN '.$xoopsDB->prefix('forum_forums').' f ON f.forum_id = t.forum_id WHERE t.topic_time > '.$topic_time.' AND t.forum_id = '.$forum.' ORDER BY t.topic_time ASC LIMIT 1';
$sql = 'SELECT t.topic_id, t.topic_title, t.topic_time, t.topic_status, t.topic_sticky, t.topic_last_post_id, f.forum_id, f.forum_name, f.forum_access, f.forum_type, f.allow_html, f.allow_sig, f.posts_per_page, f.hot_threshold, f.topics_per_page FROM '.$xoopsDB->prefix('forum_topics').' t LEFT JOIN '.$xoopsDB->prefix('forum_forums').' f ON f.forum_id = t.forum_id WHERE t.topic_time < '.$topic_time.' AND t.forum_id = '.$forum.' ORDER BY t.topic_time DESC LIMIT 1';
} else {
$sql = 'SELECT t.topic_id, t.topic_title, t.topic_time, t.topic_status, t.topic_sticky, t.topic_last_post_id, f.forum_id, f.forum_name, f.forum_access, f.forum_type, f.allow_html, f.allow_sig, f.posts_per_page, f.hot_threshold, f.topics_per_page FROM '.$xoopsDB->prefix('forum_topics').' t LEFT JOIN '.$xoopsDB->prefix('forum_forums').' f ON f.forum_id = t.forum_id WHERE t.topic_id = '.$topic_id.' AND t.forum_id = '.$forum;
As you can see from the PHP as it calls to Fetch the last posts in the forums, you could easily look at the PHP coding for the forum here and call the last posts in the same way from another site.
Another way that you could do it is by displaying a site from within one of your websites modules if you have a Content Management System, I know that Joomla comes with such a module as standard, so you could always talk with Mech about those features... as in my opinion that would be the more simpler way of doing things, thus keeping your users on your site and not linking directly to another and loosing your users to that site.
Yet another way you could do this is via RSS Feeds and display those from your site as latest news items.
As I do not understand what you are doing I can only advise the above, I hope that in some way this helps and that I win some miraculous prize too .
Hugs my friend
pkBRONZE Member Lambretta Fanatic 4,998 posts Location: United Kingdom
Posted: That code will do you no good unless your using Xoops CMS.
I forgot to mention that you'd have to use a wildcard type code to get the latest post! as say topic 3456 has the last post number as 21213 there is no chance really that the next reply will be 21214... plus I don't know how to access the HoP DB from another site to do this, you'd have to speak with Dom on that one.
Similar Topics
Using the keywords [link post] we found the following existing topics.