Author Topic: Embed Instagram BBCode v2.0  (Read 3482 times)

dougiefresh

  • Adminstrator
  • Expert Member
  • *****
  • Posts: 261
Embed Instagram BBCode v2.0
« on: Jun 06, 2015, 08:16:02 AM »

EMBED INSTAGRAM BBCODE v2.0
By Dougiefresh -> Link to Mod


Introduction
This modification adds a BBCode to view Instagram videos and pictures.

The BBCode takes these forms:
Code: [Select]
[instagram]{instagram ID}[/instagram]
[instagram width=x height=y]{instagram ID}[/instagram]
where {instagram ID} is the 21wUvaPwwB part of the https://instagram.com/p/21wUvaPwwB URL, and x and y are parameters supporting both pixel and percentages for width and height (respectively).

Admin Settings
Under Admin => Modification Settings, there are some new options:
o Default width of embedded Instagram video
o Default height of embedded Instagram video
o Include Instagram link beneath?

Compatibility Notes
This mod was tested on SMF 2.0.15, but should work on SMF 2.1 Beta 2, as well as SMF 2.0 and up.  SMF 1.x is not and will not be supported.

This mod should be installed after Tapatalk mod, if you want to use it with Tapatalk.

Changelog
The changelog has been removed and can be seen at XPtsp.com.

License
Quote
Copyright (c) 2015 - 2018, Douglas Orend
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
« Last Edit: Jan 09, 2016, 10:15:12 AM by dougiefresh »

dougiefresh

  • Adminstrator
  • Expert Member
  • *****
  • Posts: 261
Re: Embed Instagram BBCode v1.17
« Reply #1 on: Jun 06, 2015, 08:16:58 AM »

Below are some preview images of what the mod looks like when being used

Download Mod


FileName: Embed_Instagram_BBCode_v2.0.zip
Size: 12 kb (11,847 bytes)
MD5: 6d1205779db1d09439765895ea10b65a
Built: Mar 15, 2018, 06:47:50 PM
Downloaded 56 times

Changelog

Uploaded v2.0 - March 15th, 2018
o Added height and captioned to bbcode without requiring width.
o Added ability to use percentages in width and height.
o Adjusted HTML building code to add appropriate CSS width and height styling.
o Added option to include Instagram link below embedded Instagram post.

Uploaded v1.24 - March 4th, 2018
o Fixed an issue that prevents BBC manager from showing bbcodes.

Uploaded v1.23 - December 15th, 2017
o Added Spanish Latin translation, courtsey of Rock Lee!

Uploaded v1.22 - December 8th, 2017
o Added URL embedding support for Tapatalk mod.

Uploaded v1.21 - December 25th, 2016
o Fixed the embed code so that the Instagram post shows up in forum posts again.

Uploaded v1.20 - October 3rd, 2016
o Removed some leftover debugging code for signatures.

Uploaded v1.19 - May 13th, 2016
o Added captions to the displayed embedded Instagram post.
o Reverted CSS file "padding-bottom" property from 112% to 100%.

Uploaded v1.18 - March 7th, 2016
o Modified auto-embed code so that Instagram URLs in signature are embedded as [url]{link}[/url].

Uploaded v1.17 - January 4th, 2016
o Fixed bbcode validation code so that more Instagram post IDs are properly recognized.

Uploaded v1.16 - January 1st, 2016
o Added Spanish (ES) language translation to the mod.  Thanks, d3vcho!
o Fixed issue where "/?taken-by={username}" at end of URL was not properly auto-embedded.

Uploaded v1.15 - December 28th, 2015
o Fixed errors produced when calling BBCode_Instagram_Embed.

Uploaded v1.14 - November 30th, 2015
o Modified auto-embed function for use as a hook with SMF 2.1.

Uploaded v1.13 - November 15th, 2015
o Modified validation pattern to recognize URLs without the "/p" part as valid.
o Modified auto-embed regex pattern to require the "http" or "https" part of the URL.

Uploaded v1.12 - October 17th, 2015
o Fixed auto-embedding code so that it embeds the URL if no tags are around it.

Uploaded v1.11 - October 2nd, 2015
o Rewrote auto-embedding code to deal with line-breaks and duplicate closing brackets.

Uploaded v1.10 - September 21st, 2015
o Fixed auto-embedding issue where URLs inside code tags where auto-linked.

Uploaded v1.9 - Septmber 6th, 2015
o Fixed issue where BBCodes list was completely empty because of mod... (shrug)

Uploaded v1.8 - August 27th, 2015
o Added ability to auto-embed Instagram URLs to the mod.
o Adjusted CSS file "padding-bottom" property from 100% to 112% to show entire embed.

Uploaded v1.7 - August 15th, 2015
o Fixed issue where 10 character Instagram post ID wasn't displayed properly.
o Fixed CSS issue where instagram post was partly displayed within the specified area.

Uploaded v1.6 - August 12th, 2015
o Added settings to allow admin to set default size of the Instagram video.
o Altered code to use new default size settings when width and/or height isn't specified.

Uploaded v1.5 - August 8th, 2015
o Removed support for SMF 2.1 Beta 1
o Added support for SMF 2.1 Beta 2

Uploaded v1.4 - August 8th, 2015
o Added bbcode form where "frameborder" is the only parameter taken.
o Added additional URL validation to make sure bbcode isn't misused.
o Modified parameters so that height parameter is now optional.

Uploaded v1.3 - August 7th, 2015
o Added responsiveness to the Instagram iframe code.
o Replaced Instagram bbcode button images with one supplied by 420Connect.co.uk

Uploaded v1.2 - July 27th, 2015
o Replaced Instagram bbcode button images with better quality ones.

Uploaded v1.1 - June 29th, 2015
o Fixed errors when nothing was placed between the tags.
o Modified code so that nothing is output when nothing is placed between the tags.
o Modified code to allow full path to the Instagram post instead of just the post ID.

Uploaded v1.0 - June 5th, 2015
o Initial Public Release

« Last Edit: Oct 29, 2016, 07:57:14 PM by dougiefresh »