Jump to content

(tng32) Quoted Images as Links


alexp999

Recommended Posts

%7Boption%7D



File Name: (tng32) Quoted Images as Links

File Submitter: alexp999

File Submitted: 20 Aug 2011

File Category: Performance

Supported Versions: IP.Board 3.2.x



UPDATE: The IPB 3.3 version of this hook is now available (pending moderation), click here.

This is the IPB 3.2 version of this hook, for the 3.1 version, click here.

Displays quoted images as Lightbox enabled links to the original image. This saves space in your threads and means a post full of pictures is not repeated when someone quotes it.
Users can also click on the generated link and if they have javascript, a lightbox will open showing the original image.

This hook works by searching for quotes in a post, it will then strip away any BBCode images in those quotes (based on bbc_img class), replacing them with lightbox enabled urls to the original image, shortened and styled like standard BBCode urls.

This hook has been tested on an English board but has been written to hopefully work with any language and will use the alt text of the image, as the title(shown on hover) of the link. (e.g. Posted Image)


NOTE:
This hook was written for IPB 3.2
This hook is only for forum topics and IP.Content Comments
This hook only alters the DISPLAY of images quoted in posts, post data is not changed, the database remains untouched and as a result if a post is edited or quoted, the url to the quoted image will still be in %7Boption%7D tags



here to download this file

Link to comment
Share on other sites

  • 2 weeks later...
  • 7 months later...

0 queries, and it does work for IPB 3.3.x, just not IP.Content 2.3.x

There will be an update as I am rewriting a lot of the code to further improve efficiency and accuracy. And make it compatible with the global comments framework (and therefore IP.Content 2.3.x)

Link to comment
Share on other sites


0 queries, and it does work for IPB 3.3.x, just not IP.Content 2.3.x



There will be an update as I am rewriting a lot of the code to further improve efficiency and accuracy. And make it compatible with the global comments framework (and therefore IP.Content 2.3.x)




Awesome
Link to comment
Share on other sites

  • 3 weeks later...

The IPB 3.3 version of this hook has now been released (pending moderation). You can find it here:


It has been completely rewritten from the ground up to improve accuracy and effeciency, let me know if you have any problems.

Link to comment
Share on other sites

  • 1 year later...

It doesn't appear to work for me. Maybe it's because I haven't enabled it - However I do not see a place to do so under "hooks". Am I missing something? I haven't checked newer posts, however older posts still show an image in the quoted text. I have even re-cached the forum.

What version of IPB are you using?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...