Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Local links to titles Details »»
Local links to titles
Version: 1.00, by JohnWoo JohnWoo is offline
Developer Last Online: Apr 2014 Show Printable Version Email this Page

Version: 3.0.0 Rating:
Released: 09-03-2004 Last Update: Never Installs: 9
 
No support by the author.

Hello!

Not sure again - may be something like it exist already, but I was not able to find
That small hack adds only one feature. Links to local board posts, threads and forums will appear on that threads and post titles. For example link text for
https://vborg.vbsupport.ru/showthrea...2&goto=newpost
will be turned to "Fulltext boolean search v.2.2 for vB" and on https://vborg.vbsupport.ru/forumdisplay.php?f=32 - to "Code Modifications vB3".
But please be careful - it adds additional DB request for each local link on page.

Fixes:
v 1.1

- fixed links to multiply pages threads with pp= in url

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 09-05-2004, 11:45 AM
CarCdr CarCdr is offline
 
Join Date: Apr 2004
Posts: 242
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

John,

A few comments from only reading the code.

* The implementation should never return an error message instead of a link. If I post a link and you find that I do not have access or you could not find the post, the code should fall through to behave as it would without this mod -- i.e., just leave the link alone.

* Are you replacing all instances of "forumid", "threadid", and "postid" with "f", "t", and "p"?
This would mangle a mod with those strings anywhere else in the URL, like "/my_mod_forumid.php?p=1234".

* Access to a thread/post should be CANVIEWOTHERS if one is not the author.

* You seem to be checking a URL for "p=" first and then overwriting the results if "t=" is found in the same URL. Perhaps you are missing an 'else'.

* You could think about using the post title (p=1234 case) when it is set (i.e., not the thread title).

* "showpost.php" case would be useful and is very similar to "showthread.php" case.



Also, this may give you some other ideas:
https://vborg.vbsupport.ru/showthread.php?t=68398

Cheers
Reply With Quote
  #13  
Old 09-05-2004, 01:29 PM
JohnWoo's Avatar
JohnWoo JohnWoo is offline
 
Join Date: Jan 2002
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Completely agree with everything - it was just fast "weekend idea" and far from perfect
May be except "post title" - i still think that thread title will always give better description for link.
I'll make and upload v1.2 as soon as I'll have free time again But one question - sorry
I never was vb3 administrator and have no working vb3 near, so can you please give example url with both "p=" and "t=" variables?
Reply With Quote
  #14  
Old 09-05-2004, 01:54 PM
CarCdr CarCdr is offline
 
Join Date: Apr 2004
Posts: 242
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

t= and p= in same URL
I was mistaken. Although they can both appear in a showthread URL, the t= will override.

Nevertheless, you likely still need an else between the t= and p= code.

Also, I would guess that most people likely want local links to open in the same window. A config option would be a good idea here.
Reply With Quote
  #15  
Old 09-05-2004, 06:37 PM
ChurchMedia's Avatar
ChurchMedia ChurchMedia is offline
 
Join Date: Dec 2002
Location: Las Cruces, NM
Posts: 473
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Sorry . I found another bug. When parsing a URL to a member user, it creates a link like: member.php?u=1234 and drops out the name of the user. You can see an example here: http://www.churchmedia.net/community...ead.php?t=5100

Edit: I uninstalled the hack and resaved the post above and it fixed it, so it doesn't show the problem anymore. Just try this in a post and see what you get:
Code:
[ url=http://www.churchmedia.net/community/forum/member.php?u=1]Tim Eason[/url ]

(spaces in url so it won't parse in this post)
Maybe you need some definition for u=xxxx?

Also, I agree that you should make the url just show up as-is instead of giving a "post not found" error. That would take care of potential problems.

Great concept
Reply With Quote
  #16  
Old 09-06-2004, 07:42 AM
JohnWoo's Avatar
JohnWoo JohnWoo is offline
 
Join Date: Jan 2002
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i'll add everything and fix exerything tomorrow
sorry - too busy today...
Reply With Quote
  #17  
Old 09-06-2004, 10:10 AM
Phalynx Phalynx is offline
 
Join Date: Feb 2004
Location: Erlangen, Germany
Posts: 2,747
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great!
Reply With Quote
  #18  
Old 09-06-2004, 12:09 PM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Good idea. How's the server load affected for those using this on a busy site?
Reply With Quote
  #19  
Old 12-06-2004, 11:28 AM
cinq's Avatar
cinq cinq is offline
 
Join Date: Oct 2002
Posts: 1,398
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

what happens when someone uses the
Code:
[url =link]text[ /url] tags instead ?
Reply With Quote
  #20  
Old 12-09-2004, 05:06 PM
robertuss robertuss is offline
 
Join Date: Aug 2003
Posts: 11
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How about rewriting a posted text when a user inserts a reply?
I mean really change a http://www.blabla....-Textpart into a valid vbCodelike:{url=http://www.blablabl]Thread name[/url] and store that in the users post in the text.

This would easy the load for larger boards (no on-the-fly checks necessary).
Reply With Quote
  #21  
Old 12-28-2004, 03:08 PM
Sebastian's Avatar
Sebastian Sebastian is offline
 
Join Date: Oct 2002
Location: America
Posts: 488
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this hack has more bugs than windows 95,98,2000 and xp combined.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:39 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07734 seconds
  • Memory Usage 2,304KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete