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.

Is there a way to display an IMGUR GIFV?

View previous topic View next topic Go down

Solved Is there a way to display an IMGUR GIFV?

Post by Liquorish on June 26th 2015, 5:28 pm

IMGUR.com used to offer embed codes for their new GIFV gif/video format, but don't offer it currently.  Their FAQ offers alternate embed scripting, but it doesn't seem to work on my forum.

Their embed script reads:  

<blockquote class="imgur-embed-pub" lang="en" data-id="{hash}"></blockquote>
<script async src="//s.imgur.com/min/embed.js" charset="utf-8"></script> 

------------------------------------------------------------------------------

The {hash} is the end of the URL from a post on Imgur. For example, for:
http://imgur.com/tPQhMPl, the embed code would be: 
 

<blockquote class="imgur-embed-pub" lang="en" data-id="tPQhMPl"></blockquote>
<script async src="//s.imgur.com/min/embed.js" charset="utf-8"></script>


Last edited by Liquorish on June 30th 2015, 6:28 pm; edited 1 time in total

Liquorish
New Member

Male Posts : 6
Reputation : 2
Language : English
Location : Hoover, Alabama and Pensacola, Florida

http://pensacoladaily.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by niquon715 on June 26th 2015, 8:07 pm

paste in the direct link they give you just take out the v

niquon715
Forumember

Posts : 83
Reputation : 10
Language : english

http://celestialfireacademy.forumotion.com/forum

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by Zzbaivong on June 26th 2015, 8:35 pm

Go to ACP >> Modules >> HTML & JAVASCRIPT >> Javascript codes management
Make sure Javascript code management is enabled then Create a new javascript.

Title * : Imgur Embed
Placement : In all the pages
Javascript Code * :
Code:
$(function () {
    var $imgur = $('a[href*="imgur.com"][href$="#embed"]');
    if ($imgur.length) {
        $imgur.each(function () {
            var $this = $(this);
            $this.replaceWith('<blockquote class="imgur-embed-pub" lang="en" data-id="' + $this.attr("href").split(/imgur\.com\/|#embed/)[1] + '"></blockquote>');
            $.getScript("//s.imgur.com/min/embed.js");
        });
    }
});

Now, you can add the url of Imgur in your post, and add #embed at end of url. Like this:

http://imgur.com/tPQhMPl#embed

http://imgur.com/a/Yl4er#embed

Zzbaivong
Forumember

Posts : 78
Reputation : 42
Language : Javascript ^^

http://devs.forumvi.com

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by Liquorish on June 27th 2015, 9:36 pm

@Zzbaivong wrote:Go to ACP >> Modules >> HTML & JAVASCRIPT >> Javascript codes management
Make sure Javascript code management is enabled then Create a new javascript.

Title * : Imgur Embed
Placement : In all the pages
Javascript Code * :
Code:
$(function () {
    var $imgur = $('a[href*="imgur.com"][href$="#embed"]');
    if ($imgur.length) {
        $imgur.each(function () {
            var $this = $(this);
            $this.replaceWith('<blockquote class="imgur-embed-pub" lang="en" data-id="' + $this.attr("href").split(/imgur\.com\/|#embed/)[1] + '"></blockquote>');
            $.getScript("//s.imgur.com/min/embed.js");
        });
    }
});

Now, you can add the url of Imgur in your post, and add #embed at end of url. Like this:

http://imgur.com/tPQhMPl#embed

http://imgur.com/a/Yl4er#embed
Using this script, I tried this using a link to just the GIFV and just a WEBM, then tried links to the gallery pages that contain only these images, and Imgur reports back with messages that the images do not exist.  I get one of two different error messages, depending on what Imgur URL I use to embed.  These images DO exist, however.

Liquorish
New Member

Male Posts : 6
Reputation : 2
Language : English
Location : Hoover, Alabama and Pensacola, Florida

http://pensacoladaily.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by SLGray on June 27th 2015, 11:28 pm

This sounds like an issue with Imgur, not Forumotion.  Have you tried contacting Imgur?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35613
Reputation : 2372
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by Liquorish on June 30th 2015, 5:10 am

@SLGray wrote:This sounds like an issue with Imgur, not Forumotion.  Have you tried contacting Imgur?
On the Imgur website and in a browser using the Imgur URLs, their images display just fine.  I'm having the problems when I try to embed an image into a post on a Forumotion Forum.

Yes, I have contacted Imgur.  Not much success with their suggestions either.

At their suggestion I did find an old unsupported Imgur embed script that works part of the time.  I guess I'll just have to use it.

It is:
<iframe class="imgur-embed" width="100%" height="480" frameborder="0" src="https://i.imgur.com/WKnQwiz.webm#embed"></iframe>

Where https://i.imgur.com/WKnQwiz.webm is the URL of the image.

I guess I'll mark the topic solved... although I'm still having trouble.  Uh, I don't see where I can do that.  Do y'all mark topics as solved? Embarassed

Liquorish
New Member

Male Posts : 6
Reputation : 2
Language : English
Location : Hoover, Alabama and Pensacola, Florida

http://pensacoladaily.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by brandon_g on June 30th 2015, 5:16 am

Edit the 1st post/topic starter to mark it solved. Very Happy


Remember to mark your topic when a solution is found.

brandon_g
Support Moderator
Support Moderator

Male Posts : 5137
Reputation : 478
Language : English
Location : USA

http://broadcastingduo.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by SLGray on June 30th 2015, 8:42 am

Are the images just images or animated images?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 35613
Reputation : 2372
Language : English
Location : United States

http://fmthemes.forumotion.com/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by APE on June 30th 2015, 9:11 pm

is this now solved as it is marked as so ?





APE
Manager
Manager

Male Posts : 8309
Reputation : 716
Language : fluent in dork / mumbojumbo & English haha
Location : STUCK IN FORUMOTIONS SERVERS HELP ME !!!!!!

http://chatworld.forumotion.co.uk/

Back to top Go down

Solved Re: Is there a way to display an IMGUR GIFV?

Post by Derri on July 5th 2015, 7:29 pm

Since there was no reply after 5 days we can assume this topic was intentionally marked solved

Topic Archived


Forum Rules : : Forumotion Staff : : Appeal A Warning : : FAQ : : Tips & Tricks : : Forgotten Password/Login Issues
You need one post to send a PM
When your topic has been solved, ensure you mark the topic solved
Never post your email in public


Derri
Administrator
Administrator

Male Posts : 8355
Reputation : 571
Language : English & Basic French
Location : Scotland, United Kingdom

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