Previous Thread
Next Thread
Print Thread
Hop To
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
I'd like to do this, so that "spam comments" don't give them any juice. Is it possible to adjust things so this happens to posts made by users? (But perhaps NOT to those posted by admin or perhaps not to links that are posted with our own URL?)

Thanks

>>>>>

Q: How does a link change?
A: Any link that a user can create on your site automatically gets a new "nofollow" attribute. So if a blog spammer previously added a comment like

Visit my <a href="http://www.example.com/">discount pharmaceuticals</a> site.

That comment would be transformed to

Visit my <a href="http://www.example.com/" rel="nofollow">discount pharmaceuticals</a> site.

Q: What types of links should get this attribute?
A: We encourage you to use the rel="nofollow" attribute anywhere that users can add links by themselves, including within comments, trackbacks, and referrer lists. Comment areas receive the most attention, but securing every location where someone can add a link is the way to keep spammers at bay.

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
I was thinking this already happened on links...

test


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
Holy dern, it isn't!
Code
<a href="http://www.undergroundnews.com/" target="_blank">test</a>


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
Seems 7.3 does this:

Processed URL in 7.3a2
Code
<div id="body0"><a href="http://www.blah.com/"  rel="nofollow" target="_blank">haha hehe hoho?</a></div>


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Nov 2006
Posts: 3,095
Likes: 1
Carpal Tunnel
Carpal Tunnel
Joined: Nov 2006
Posts: 3,095
Likes: 1
Well not new, has been around for about 3 years at least.
Suppose we don't have it because often not as big an issue as blogs that often allow posting anonymously.

http://googleblog.blogspot.com/2005/01/preventing-comment-spam.html


Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
we (can) allow anon posting wink


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
So can we do that?

smile

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
sure, set a forum to allow guests to post wink...

as for the norel, it's built into 7.3; or you ccould hack it in on prior versions by editing the bbcode.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
When can we expect 7.3 by the way?

Thanks

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
After beta... When will you see public beta (if there is one?) after private beta... When will you see private beta? Well, the private beta will likely be rolled out here...

Want to play with an alpha? Check the beta testers sites... Mine for sake of alpha is the one I use for raw testing, which is here


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
OK.

Is it possible to adjust this on the current latest version (7.2.2)?

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
Yes, you'd edit the url bbcode (the <a href line) in the libs/ubbthreads.inc.php file


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
Gizmo
OK thanks... can you be a bit more specific so I can go in and do that.... Thank you! smile

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
It's straight forward... simple as can be... find the lines, add the rel comment, in the url tag...

You see:
Code
                // Link regexes here
                $body = preg_replace( "#\[url\](https|http|ftp)://([^\"\[\]<>]+?)\[/url]#i", '<a href="\1://\2" target="_blank">\1://\2</a>',$body );
                $body = preg_replace( "#\[url\]([^\"\[\]<>]+?)\[/url\]#i", '<a href="http://\1" target="_blank">\1</a>',$body );
                $body = preg_replace( "#\[url=(https|http|ftp)://([^\"\[\]<> ]+?)\](.+?)\[/url]#i", '<a href="\1://\2" target="_blank">\3</a>',$body);
                $body = preg_replace("#(<br />|^|\s)(http|https|ftp)://([^<\"\[\s]+)(\.|\,|\?|\)|\s)?#i", '\1<a href="\2://\3" target="_blank">\2://\3</a>\4',$body);
                $body  = preg_replace( "#(<br />|^|\s)(www\.[^<\"\[\s]+)(\.|\,|\?|\)|\s)?#i", '\1<a href="http://\2" target="_blank">http://\2</a>\3',$body );

You do:

Code
                // Link regexes here
                $body = preg_replace( "#\[url\](https|http|ftp)://([^\"\[\]<>]+?)\[/url]#i", '<a href="\1://\2" target="_blank">\1://\2</a>',$body );
                $body = preg_replace( "#\[url\]([^\"\[\]<>]+?)\[/url\]#i", '<a href="http://\1" rel="nofollow" target="_blank">\1</a>',$body );
                $body = preg_replace( "#\[url=(https|http|ftp)://([^\"\[\]<> ]+?)\](.+?)\[/url]#i", '<a href="\1://\2" rel="nofollow" target="_blank">\3</a>',$body);
                $body = preg_replace("#(<br />|^|\s)(http|https|ftp)://([^<\"\[\s]+)(\.|\,|\?|\)|\s)?#i", '\1<a href="\2://\3" rel="nofollow" target="_blank">\2://\3</a>\4',$body);
                $body  = preg_replace( "#(<br />|^|\s)(www\.[^<\"\[\s]+)(\.|\,|\?|\)|\s)?#i", '\1<a href="http://\2" rel="nofollow" target="_blank">http://\2</a>\3',$body );


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
Great thank you.

I suppose this will be for ALL links posted within any thread, right

Is it too much to think we could make it not do that for admins/moderators?

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
It's for all links, as you're editing the bbcode. as for allowing admin's to have a norel, it's not possible as the current code doesn't check for permissions...


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
OK thank you!

Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
Does it include links in islands and html we add to the page outside of the actual threads?

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
If you use the [url] BBCode to create the links, they will come out with rel no follow; if you hand code the html links, you could add this yourself manually.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
Thanks sorry I missed that. Not sure I understand the last part of the above though - could you explain that bit again? Thank you

Joined: Jun 2006
Posts: 16,299
Likes: 116
UBB.threads Developer
UBB.threads Developer
Joined: Jun 2006
Posts: 16,299
Likes: 116
ok, when you create a link:
Code
[url=http://www.gizmo-is-the-bestest.us/]Gizmo Rules[/url]

It is automatically created (by the BBCode parser) with the norel attribute.

If you allow HTML, and users insert the link:
Code
<a href="http://www.gizmo-is-the-bestest.us/">Gizmo Rules</a>
the norel attribute will not be attached as it puts the content in as specified.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Joined: Feb 2007
Posts: 678
W
old hand
old hand
W Offline
Joined: Feb 2007
Posts: 678
OK got it. Thank you!!


Link Copied to Clipboard
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
Bots
by Outdoorking - 04/13/2024 5:08 PM
Can you add html to language files?
by Baldeagle - 04/07/2024 2:41 PM
Do I need to rebuild my database?
by Baldeagle - 04/07/2024 2:58 AM
This is not a bug, but a suggestion
by Baldeagle - 04/05/2024 11:25 PM
Is UBB.threads still going?
by Aaron101 - 04/01/2022 8:18 AM
Who's Online Now
0 members (), 797 guests, and 200 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
Los Angeles
Los Angeles
by isaac, August 6
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20230217)