Prime Links

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in the Customisations Database.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTICE: This forum is only for the announcement of new releases and/or updates of MODs. Any MOD support should be obtained through the Customisations Database in the support area designated for each MOD.

A direct link to support for each MOD is in the first post of the respective topic.
User avatar
primehalo
Former Team Member
Posts: 2833
Joined: Fri May 06, 2005 5:58 pm
Location: Redding, CA
Contact:

Re: Prime Links

Post by primehalo » Mon Jun 16, 2008 7:40 am

ToonArmy wrote:

Code: Select all

                 if ($remove_subdomains && is_string($remove_subdomains))
                {
                    str_replace(';', '|', $remove_subdomains);
                    str_replace('.', '\\.', $remove_subdomains);
                    $stripped_url = preg_replace('#^(http|https)://(?:' . $remove_subdomains . '\.)([^/]+)#i', '$1://$2', $url);
                }   
Dude, what on earth! The str_replace() calls assign the result to nothing. And the $remove_subdomains is not escaped before being placed in the regular expression with preg_quote().
Wow, how did I miss that?! Well, it's fixed now. Thanks for letting me know.
Ken F. Innes IV
My Extensions | My MODs | My Topics | My Site: Absolute Anime
Experience the wonder of Japanese Animation!

najamd
Registered User
Posts: 15
Joined: Sun May 11, 2008 5:29 am
Location: Toronto, Canada
Contact:

Re: Prime Links

Post by najamd » Tue Jun 17, 2008 5:33 am

Thanks for the mod!
I was wondering is there a mod that sends external links to a page like phpbb.com/link.php?id=2323 and this page sends user to the real domain. I saw it on a forum and was wondering if it was possible with phpBB3 or does this mod do it already? Reason i'm asking is because i am new to this whole forum business and in my new forum, im getting users which are just posting to get there links in, and i want to try to prevent it if possible.
Thanks in advance!,

ND

User avatar
primehalo
Former Team Member
Posts: 2833
Joined: Fri May 06, 2005 5:58 pm
Location: Redding, CA
Contact:

Re: Prime Links

Post by primehalo » Tue Jun 17, 2008 5:41 am

najamd wrote:Thanks for the mod!
I was wondering is there a mod that sends external links to a page like phpbb.com/link.php?id=2323 and this page sends user to the real domain. I saw it on a forum and was wondering if it was possible with phpBB3 or does this mod do it already? Reason i'm asking is because i am new to this whole forum business and in my new forum, im getting users which are just posting to get there links in, and i want to try to prevent it if possible.
Thanks in advance!,

ND
This like does not do exactly that, but it does give you the ability to set this up on your own since it allows you to prepend external links. So you can have it prepend something like "phpbb.com/link.php?id=2323&external_link=", and then you would have to make that page display the external link that is being passed in via the URL.
Ken F. Innes IV
My Extensions | My MODs | My Topics | My Site: Absolute Anime
Experience the wonder of Japanese Animation!

pythonjosh
Registered User
Posts: 47
Joined: Sun Dec 25, 2005 7:31 am
Location: Seattle, WA
Contact:

Re: Prime Links

Post by pythonjosh » Sun Jun 29, 2008 4:29 am

I'm having a problem with this mod. Here's my steps to repro:

Make a post with a url in it.
Edit post, notice:
" onclick="window.open(this.href);return false;
has been appended to the url.
Just click submit, and notice that string is appended to the url in the post.
Edit again and you will find:
" onclick="window.open(this.href);return false;" onclick="window.open(this.href);return false;
after the url.

Seems it will append a url whether or not it has already been appended with the string.
I'd imagine there could be a little modification to this part of includes/prime_links.php:

Code: Select all

				if ($new_target)
				{
					if (USE_TARGET_ATTRIBUTE === true)
					{
						$new_link = $this->insert_attribute('target', $new_target, $new_link, true);
					}
					else
					{
						$new_link = $this->insert_attribute('onclick', "this.target='$new_target';", $new_link, false);
					}
				}

User avatar
primehalo
Former Team Member
Posts: 2833
Joined: Fri May 06, 2005 5:58 pm
Location: Redding, CA
Contact:

Re: Prime Links

Post by primehalo » Sun Jun 29, 2008 5:21 am

I am unable to recreate your issue. Any other info you can provide?
Ken F. Innes IV
My Extensions | My MODs | My Topics | My Site: Absolute Anime
Experience the wonder of Japanese Animation!

pythonjosh
Registered User
Posts: 47
Joined: Sun Dec 25, 2005 7:31 am
Location: Seattle, WA
Contact:

Re: Prime Links

Post by pythonjosh » Sun Jun 29, 2008 5:40 am

I fixed it, may have been from a previous mod, thanks tho

Fisch.666
Registered User
Posts: 219
Joined: Sat Jul 30, 2005 10:58 am

Re: Prime Links

Post by Fisch.666 » Tue Jul 01, 2008 4:30 pm

Hi!

Thanks for this mod, works here without a problem. But i have a question:

I use this mod at my phpBB 3.0.1 board:

http://www.phpbb.com/community/viewtopi ... 0&t=561803

When i try to use the image resize function together with the http://anonym.to in the external link function and i click on the image to get the full image the prime links mod adds the http://anonym.to to the image url. Are there any chances to edit this mod so it doesn't add this external link to images?

Thanks in advance for an reply.

pythonjosh
Registered User
Posts: 47
Joined: Sun Dec 25, 2005 7:31 am
Location: Seattle, WA
Contact:

Re: Prime Links

Post by pythonjosh » Tue Jul 01, 2008 4:45 pm

I think you'd get better support by posting your issue in the thread you linked to in your post.
I notice the page in that link states that the mod is BETA! It's not officially released and approved by the PHPBB MOD team. Therefore all issues should be relayed to the creator of the MOD, not posted in threads of other MODs created by other php designers.

Fisch.666
Registered User
Posts: 219
Joined: Sat Jul 30, 2005 10:58 am

Re: Prime Links

Post by Fisch.666 » Wed Jul 02, 2008 10:37 am

Hi!

Mhhh, sorry. I thought this is a problem of prime links, because the prime links mod uses the external link for all links including images and not only urls...

pythonjosh
Registered User
Posts: 47
Joined: Sun Dec 25, 2005 7:31 am
Location: Seattle, WA
Contact:

Re: Prime Links

Post by pythonjosh » Wed Jul 02, 2008 6:29 pm

I'm sorry, I didn't understand your post correctly. Your request is to have an option to exclude image links like:

Code: Select all

[url][img][/img][/url]
correct?

User avatar
primehalo
Former Team Member
Posts: 2833
Joined: Fri May 06, 2005 5:58 pm
Location: Redding, CA
Contact:

Re: Prime Links

Post by primehalo » Wed Jul 02, 2008 8:53 pm

Fisch.666 wrote:Hi!

Thanks for this mod, works here without a problem. But i have a question:

I use this mod at my phpBB 3.0.1 board:

http://www.phpbb.com/community/viewtopi ... 0&t=561803

When i try to use the image resize function together with the http://anonym.to in the external link function and i click on the image to get the full image the prime links mod adds the http://anonym.to to the image url. Are there any chances to edit this mod so it doesn't add this external link to images?

Thanks in advance for an reply.
I remember something like this was asked before, so I just added an option to disable the parsing of image links. I'm having trouble connecting to my server, so I uploaded the new package here:
[edit: upload problem fixed, use the default download link]

To update, copy over the new includes/prime_links.php file. To set the option, open that file and you should see what you need to do. Let me know if it works, as I haven't been able to test it.
Last edited by primehalo on Thu Jul 03, 2008 9:44 am, edited 2 times in total.
Ken F. Innes IV
My Extensions | My MODs | My Topics | My Site: Absolute Anime
Experience the wonder of Japanese Animation!

Fisch.666
Registered User
Posts: 219
Joined: Sat Jul 30, 2005 10:58 am

Re: Prime Links

Post by Fisch.666 » Thu Jul 03, 2008 9:33 am

Hi!

First thanks for your reply and your help!!!.

When i use your new prime_links.php i get this error in thrads with an image file:

Code: Select all

[phpBB Debug] PHP Notice: in file /includes/prime_links.php on line 217: preg_match() [function.preg-match]: Delimiter must not be alphanumeric or backslash
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3533: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2962)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3535: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2962)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3536: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2962)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3537: Cannot modify header information - headers already sent by (output started at /includes/functions.php:2962)
and the font in this thread is bigger than normal. Other threads without images are shown correctly...

User avatar
primehalo
Former Team Member
Posts: 2833
Joined: Fri May 06, 2005 5:58 pm
Location: Redding, CA
Contact:

Re: Prime Links

Post by primehalo » Thu Jul 03, 2008 9:43 am

Oops, I forgot the delimiters. I just fixed it, so try downloading and updating again.
Ken F. Innes IV
My Extensions | My MODs | My Topics | My Site: Absolute Anime
Experience the wonder of Japanese Animation!

Fisch.666
Registered User
Posts: 219
Joined: Sat Jul 30, 2005 10:58 am

Re: Prime Links

Post by Fisch.666 » Thu Jul 03, 2008 10:27 am

Wow, thanks again! Works now without a problem!!! :D

User avatar
Kalipo
Registered User
Posts: 551
Joined: Mon Dec 08, 2003 1:47 pm

Re: Prime Links

Post by Kalipo » Thu Jul 03, 2008 5:22 pm

Fantastic MOD.

Two questions...

1. How to make both internal & external open in a new window/tab?

2. How would I add an external link image to the external links?
My MOD request: MMORPG Workshop+

Locked

Return to “[3.0.x] MOD Database Releases”