News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Registered Links

Started by SMFHacks.com Team, May 18, 2006, 07:42:31 PM

Previous topic - Next topic

vbgamer45

It won't work on ads. But takes anything in the ouptput buffer and attempts to rewrite it.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

drfun

Is there a way i can manually uninstall this Registered Links, i tried uninstalling it using the package manager and i encountered an error during a test  uninstalling of this package.
the error was found in
Quote
Execute Modification    ./Themes/default/languages/Modifications.english.php    Test failed
1.              Replace     ./Themes/default/languages/Modifications.english.php    Test failed

is there a way i can uninstall it manually.
ECLIKS - Metaverse & AI Tech Blog

vbgamer45

That error is safe to ignore Will not affect your site. But you can later remove the text strings added to that file from reg links
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

drfun

ECLIKS - Metaverse & AI Tech Blog

Biology Forums

Did the mod author ever end up coding it where it excludes links originating from the forum's URL? :-\

vbgamer45

Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Biology Forums

#506
Quote from: vbgamer45 on August 02, 2013, 10:23:45 PM
No.

Don't mean to be rude, but for an expert coder, shouldn't this be a relatively easy task?

vbgamer45

Maybe still would take me probably an hour of work which I do not have time for.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Biology Forums

Quote from: vbgamer45 on August 04, 2013, 10:40:31 AM
Maybe still would take me probably an hour of work which I do not have time for.

I found a way around it.

find:

if ($user_info['is_guest'])
{


add:



$myurl = 'YOUR URL HERE, for example url.com';

if(strpos($message,$myurl) == false)


This should effectively show the urls if there is url.com in $message. Only problem is, it will now show all the links in that message if there are other links with different urls. Still a good compromise.


Arantor

Or not even close, in fact. You're not using strpos correctly.

strpos will return false if it wasn't found. It will return 0 if it was found at the start of the string you're testing for which using == will match to false.

The test should be !== false. Right now it's checking that url.com isn't present or it's the very start of the message.
Holder of controversial views, all of which my own.


fatyhxd41

I installed this mod but it isn't working. Still showing links to visitors.

vbgamer45

Check that it made it the code its to the SMF files
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

melwynjensen

I have uninstalled the  Registered Links mod from my website www.infomaniac.co.in being the site is new but the problem is, it still shows up the "You are not allowed to view links. Register or Login" for Guests. Why is that?

Is there any code changes necessary to come out of it? Can you please help me in this?

Hope I will get a reply soon.

vbgamer45

Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

melwynjensen

Thanks a lot vbgamer45 :) Very less code change so able to get it done!

Removing the below piece of code from Sub.php under sources folder did the trick.

      // Registered Links
      if ($user_info['is_guest'])
      {
         $message = preg_replace('#<a href="(.*?)</a>#i', $txt['no_view_links'] . "\n" . ' <a href="' . $scripturl . '?action=register">' . $txt['txt_reg_links_register'] . '</a>&nbsp;' . $txt['txt_reg_links_or'] . '&nbsp;<a href="' . $scripturl . '?action=login">' . $txt['txt_reg_links_login'] . '</a>', $message);
      }

      // End Registered Links

GamePersia

how to modify it ??...like add a image instead of the text ??

vbgamer45

Edit the code added to subs.php and modify the html it injects.
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

GamePersia

Quote from: vbgamer45 on February 07, 2014, 09:44:17 AM
Edit the code added to subs.php and modify the html it injects.
am i have to edit this :
Quote// Registered Links
      if ($user_info['is_guest'])
      {
         $message = preg_replace('#<a href="(.*?)</a>#i', $txt['no_view_links'] . "\n" . ' <a href="' . $scripturl . '?action=register">' . $txt['txt_reg_links_register'] . '</a>&nbsp;' . $txt['txt_reg_links_or'] . '&nbsp;<a href="' . $scripturl . '?action=login">' . $txt['txt_reg_links_login'] . '</a>', $message);
      }

      // End Registered Links
If yes,..then please tell in detail,..that where to add image ??

vbgamer45

That code right there yes replace with image tag  instead of
$txt['no_view_links'] . "\n" . ' <a href="' . $scripturl . '?action=register">' . $txt['txt_reg_links_register'] . '</a>&nbsp;' . $txt['txt_reg_links_or'] . '&nbsp;<a href="' . $scripturl . '?action=login">' . $txt['txt_reg_links_login'] . '</a>'
Community Suite for SMF - Grow your forum with SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com - Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

desai_amogh

Can this also block attachments and ask guests to register or login to view them ??

Advertisement: