Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 07 Dec 2009, 20:37
fme fme is offline
 
Join Date: Apr 2006
Show full url links instead of shortening it?

Hi, when users post a long link the forum automatically shortens it by adding "..." for example:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


something like this will come up:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Is there an option on how I can make it show the full url link instead of it being shorten? thanks
Reply With Quote
  #2  
Old 07 Dec 2009, 20:59
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Real name: Lynne
This has been posted about before. You need to actually edit the code. Try a search for it and it should come up. Or do a search in your files for "..." and it should come up (that's how I found it).
__________________
Former vBulletin.org Staff Member

Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools -
Online vBulletin Manual
If I post some CSS and don't say where it goes, put it in the additional.css template.
I will NOT help via PM (you will be directed to post in the forums for help.)
Reply With Quote
  #3  
Old 07 Dec 2009, 21:12
fme fme is offline
 
Join Date: Apr 2006
Thanks for the reply. But i've tried searching on Vbulletin.com and Vbulletin.org for hours and of course I did the basic phrase / template search for "..." before posting this thread. I came up with nothing.

can you please direct me to the post or what to type into the search field? I might just be retarded and missing the most simplest word for this.
Reply With Quote
  #4  
Old 07 Dec 2009, 21:36
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Real name: Lynne
Search your php files for '...', not the templates/phrases. I think it will show up in some bbcode function, if I recall correctly.
__________________
Former vBulletin.org Staff Member

Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools -
Online vBulletin Manual
If I post some CSS and don't say where it goes, put it in the additional.css template.
I will NOT help via PM (you will be directed to post in the forums for help.)
Reply With Quote
  #5  
Old 18 Sep 2010, 13:15
Valter Valter is offline
 
Join Date: Aug 2005
Hi Lynne,

Are you able to do this in vB4?

I've tried to disable stripping in handle_bbcode_url function in class_bbcode.php but it does not work. postparsed table is truncated.

Any idea?

Thanks.
Reply With Quote
  #6  
Old 18 Sep 2010, 16:27
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Real name: Lynne
Yes, it works in vb4 also. I saved this blurb from another thread about it:

I believe you want to find these lines in includes/class_bbcode.php in the function handle_bbcode_url
PHP Code:
if (vbstrlen($tmp) > 55 AND $this->is_wysiwyg() == false)
{
$text = htmlspecialchars_uni(vbchop($tmp, 36) . '...' . substr($tmp, -14));
}
Line 2091-2095 in v4.0.3.

55 = number of characters before it's stripped
36 = number of characters before the (...)
14 = number of characters after the (...)
__________________
Former vBulletin.org Staff Member

Try a search before posting for help. Many users won't, and don't, help if the question has been answered several times before.
W3Schools -
Online vBulletin Manual
If I post some CSS and don't say where it goes, put it in the additional.css template.
I will NOT help via PM (you will be directed to post in the forums for help.)
Reply With Quote
  #7  
Old 02 Nov 2010, 19:35
GONUMBER6's Avatar
GONUMBER6 GONUMBER6 is offline
 
Join Date: Jan 2010
Real name: Lisa
This was very useful info, thank you as always Lynne!
Reply With Quote
  #8  
Old 19 Jan 2012, 06:08
dmm2020 dmm2020 is offline
 
Join Date: Apr 2010
Originally Posted by Lynne View Post
Yes, it works in vb4 also. I saved this blurb from another thread about it:
Glad I found this post.

I was having problems in latest version of vB 4.1.5 where I posted download links for alpha testers of my script on my forum and it initially worked for them, but when I went back to the page a day later, link would be corrupted. But when I edited the script, the full link showed in the edit mode. I commented the block of code you reference out and problem goes away for me.

Thanks.
__________________
Doug Mewis
Owner, Friends Arcade, a gaming website for people to socialize and play games with some of the best games available
http://friends-arcade.com
Reply With Quote
  #9  
Old 30 Nov 2013, 15:18
postcd postcd is offline
 
Join Date: Feb 2012
Originally Posted by Lynne View Post
Yes, it works in vb4 also. I saved this blurb from another thread about it:
I changed that number to 512

so it is:

if (vbstrlen($tmp) > 512 AND $this->is_wysiwyg() == false)
{
$text = htmlspecialchars_uni(vbchop($tmp, 36) . '...' . substr($tmp, -14));
}
But its still shortened even i tried to post new reply with long links (less than 512 chars.)
Reply With Quote
  #10  
Old 20 Aug 2014, 05:02
tini_lam tini_lam is offline
 
Join Date: Dec 2009
In FILE class_bbcode.php have 2 line need edit.

edit

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

to

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Reply With Quote
  #11  
Old 20 Aug 2014, 13:46
Paul M's Avatar
Paul M Paul M is offline
 
Join Date: Sep 2004
Real name: Paul M
Do not comment that line out. You are opening an XSS security hole by removing the htmlspecialchars call.
__________________
Former vBulletin.org Staff Member


Cable Forum
Please do not PM me about custom work - I no longer undertake any.
Note: I will not answer support questions via e-mail or PM - please use the relevant thread or forum.
Reply With Quote
  #12  
Old 20 Aug 2014, 18:48
MaXimus's Avatar
MaXimus MaXimus is offline
 
Join Date: Nov 2011
Even better, you can have the URL auto convert into the Title of the page:

http://www.vbulletin.org/forum/showthread.php?t=189658
__________________
MaxGeek Forum - #1 Site for PC supports and tweaking guides!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

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


New To Site? Need Help?

All times are GMT. The time now is 08:15.

Layout Options | Width: Wide Color: