The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Link acces sign

View previous topic View next topic Go down

Link acces sign

Post by Glavee on Thu Jan 01, 2015 6:25 pm

Hi!

I recently set on my forum to let just mermbers+ to acces the links, but I wanna ask you if I can put a warning in there to let the guests know that only members can acces the links, and instead of the link, to be '(ONLY MEMBERS CAN ACCESS THE LINKS)'. It would be a way more cool if I can put an image instead of this message!

Thanks!
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Fierce Star on Thu Jan 01, 2015 7:29 pm

Hi,

Try adding this to your Javascipt Codes Management (Located at ACP -> Modules -> Javascript Codes Management -> Add):
Title: Optional
Placement: In the topics
Code:
Code:
$(function() {
  var IMGsrc = "http://illiweb.com/fa/i/smiles/icon_rr.png";
  $('span[style="color:#f00"]:contains("to see this link")').html('<img src="'+ IMGsrc  + '"/>');
});
Replace http://illiweb.com/fa/i/smiles/icon_rr.png with the URL of your image.

Fierce Star
Forumember

Male Posts : 110
Reputation : 17
Language : English
Location : United States

http://inactivesite.onlyhelpwithothersnow.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Thu Jan 01, 2015 7:58 pm

@Fierce Star wrote:Hi,

Try adding this to your Javascipt Codes Management (Located at ACP -> Modules -> Javascript Codes Management -> Add):
Title: Optional
Placement: In the topics
Code:
Code:
$(function() {
  var IMGsrc = "http://illiweb.com/fa/i/smiles/icon_rr.png";
  $('span[style="color:#f00"]:contains("to see this link")').html('<img src="'+ IMGsrc + '"/>');
});
Replace http://illiweb.com/fa/i/smiles/icon_rr.png with the URL of your image.

It doesn't work... :/
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Thu Jan 01, 2015 11:16 pm

can you give me a link to your forum that has a link on it that shows the msg?
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Thu Jan 01, 2015 11:59 pm

@_Twisted_Mods_ wrote:can you give me a link to your forum that has a link on it that shows the msg?

http://1001hacks.omgforum.net/t10-1-8-taco-client-pvp-huge-hakes-get-rekt-by-elitetaco9000

Scroll down to 'Download:' and under it is the link.
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Fierce Star on Fri Jan 02, 2015 12:17 am

For the code to work, you'll need to have set the permissions in General -> Categories and Forums -> Edit -> Permissions -> See links in the messages : (Set it to "Members").

Fierce Star
Forumember

Male Posts : 110
Reputation : 17
Language : English
Location : United States

http://inactivesite.onlyhelpwithothersnow.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Fri Jan 02, 2015 12:28 am

@Fierce Star wrote:For the code to work, you'll need to have set the permissions in General -> Categories and Forums -> Edit -> Permissions -> See links in the messages : (Set it to "Members").

I've already done this.
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Fri Jan 02, 2015 3:08 am

you can enable links for everyone and this will replace the links url and content

but if they disable javascript the links will still show .. other then that i have no idea

just create a new javascript and set placement to in topics

Code:
$(function(){
if(_userdata.session_logged_in == 0){
$('.post-entry .entry-content a').attr('href',"/forum");
$('.post-entry .entry-content a').html(' <img src="http://i55.servimg.com/u/f55/18/84/19/28/admin10.png> ');
}});
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Fri Jan 02, 2015 6:34 pm

@_Twisted_Mods_ wrote:you can enable links for everyone and this will replace the links url and content

but if they disable javascript the links will still show .. other then that i have no idea

just create a new javascript and set placement to in topics

Code:
$(function(){
if(_userdata.session_logged_in == 0){
$('.post-entry .entry-content a').attr('href',"/forum");
$('.post-entry .entry-content a').html(' <img src="http://i55.servimg.com/u/f55/18/84/19/28/admin10.png> ');
}});

Look guys, this is what I'm talking about:

avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Glavee on Sat Jan 03, 2015 9:01 pm

BUMP
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Sat Jan 03, 2015 11:59 pm

did the script not work? or u needing something else?
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Mon Jan 05, 2015 9:25 pm

It doesn't work
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Mon Jan 05, 2015 9:49 pm

you have it set to in topic and you have JavaScript on... also did you logout to see if it worked
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Wed Jan 14, 2015 4:19 pm

@_Twisted_Mods_ The images doesn't work, just the links aren't enabled for guests.
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Thu Jan 15, 2015 3:39 am

Code:
$(function(){
if(_userdata.session_logged_in == 0){
  $('.post-entry .entry-content a').attr('href',"/forum");
  $('.post-entry .entry-content a').html(' <img src="http://i55.servimg.com/u/f55/18/84/19/28/admin10.png"> ');
  }});

was missing the " at end of the image url
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Thu Jan 15, 2015 9:29 pm

@_Twisted_Mods_ Doesn't work... It still appears only the text. :/
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Glavee on Sun Jan 18, 2015 12:39 pm

Bump
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Glavee on Tue Jan 20, 2015 4:12 pm

BUMP
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by Glavee on Tue Jan 20, 2015 4:18 pm

@_Twisted_Mods_ your code works just for images, not for links.
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Tue Jan 20, 2015 7:16 pm

it should covert all links inside post to images
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by Glavee on Sun Jan 25, 2015 1:08 pm

But it doesn't... BUMP
avatar
Glavee
Forumember

Posts : 149
Reputation : 1
Language : English

http://1point.forumstech.com/

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Sun Jan 25, 2015 2:08 pm

last try

Code:
$(document).ready(function(){
if(_userdata.session_logged_in == 1){
  $('.post-entry a').attr('href',"/forum");
  $('.post-entry a').html(' <img src="http://i55.servimg.com/u/f55/18/84/19/28/admin10.png"> ');
  }});



you are running punbb on your forum correct if so.. and this does not work then its another script on your forum is causing it not to run because i tested this on my test forum on punbb
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

Re: Link acces sign

Post by _Twisted_Mods_ on Fri Feb 13, 2015 1:56 am

Has this request been completed?
avatar
_Twisted_Mods_
Helper
Helper

Male Posts : 2032
Reputation : 302
Language : English
Location : Ms

http://liquidcode.forumotion.com

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum