[CDB] Youtube Videos Gallery

A place for Extension Authors to post and receive feedback on Extensions still in development. No Extensions within this forum should be used within a live environment!
Ideas Centre
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: Extensions Development rules

IMPORTANT FOR NEEDED EVENTS!!!
If you need an event for your extension please read this for the steps to follow to request the event(s)
User avatar
[email protected]
Registered User
Posts: 191
Joined: Sun Sep 15, 2013 11:49 am
Location: bb3.mobi
Name: Anvar Stybaev

Re: [DEV] Youtube Videos Gallery

Post by [email protected] »

Open ext/dmzx/youtubegallery/controller/youtubegallery.php
FIND

Code: Select all

		$youtube_id = getYouTubeIdFromURL($video_url);
		$jsonURL = file_get_contents("https://www.googleapis.com/youtube/v3/videos?id={$youtube_id}&key={$this->config['google_api_key']}&type=video&part=snippet");

		$json = json_decode($jsonURL);

		if(isset($json->items[0]->snippet))
		{
			$video_title = $json->items[0]->snippet->title;
		}
Replace

Code: Select all

		if ($youtube_id = getYouTubeIdFromURL($video_url))
		{
			$jsonURL = file_get_contents("https://www.googleapis.com/youtube/v3/videos?id={$youtube_id}&key={$this->config['google_api_key']}&type=video&part=snippet");

			$json = json_decode($jsonURL);

			if(isset($json->items[0]->snippet))
			{
				$video_title = $json->items[0]->snippet->title;
			}
		}
[DEV/Beta] More extensions

Hopefully Google correctly translate my text// I do not support in private messages!
playgoods
Registered User
Posts: 60
Joined: Wed Jun 16, 2010 1:05 pm

Re: [DEV] Youtube Videos Gallery

Post by playgoods »

How do you create different categories?
User avatar
_Vinny_
Style Customisations
Style Customisations
Posts: 10533
Joined: Tue Aug 11, 2009 12:45 am
Location: Brazil
Name: Marcus Vinicius

Re: [DEV] Youtube Videos Gallery

Post by _Vinny_ »

[email protected] wrote:Open ext/dmzx/youtubegallery/controller/youtubegallery.php
FIND

Code: Select all

		$youtube_id = getYouTubeIdFromURL($video_url);
		$jsonURL = file_get_contents("https://www.googleapis.com/youtube/v3/videos?id={$youtube_id}&key={$this->config['google_api_key']}&type=video&part=snippet");

		$json = json_decode($jsonURL);

		if(isset($json->items[0]->snippet))
		{
			$video_title = $json->items[0]->snippet->title;
		}
Replace

Code: Select all

		if ($youtube_id = getYouTubeIdFromURL($video_url))
		{
			$jsonURL = file_get_contents("https://www.googleapis.com/youtube/v3/videos?id={$youtube_id}&key={$this->config['google_api_key']}&type=video&part=snippet");

			$json = json_decode($jsonURL);

			if(isset($json->items[0]->snippet))
			{
				$video_title = $json->items[0]->snippet->title;
			}
		}
Why? Could you explain the reason for this change?
User avatar
Galixte de EzCom
Registered User
Posts: 1106
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.

Re: [DEV] Youtube Videos Gallery

Post by Galixte de EzCom »

playgoods wrote:How do you create different categories?
I's fixed: https://github.com/dmzx/youtubegallery/ ... 6587c9fdb3. Update from GitHub.

Create category is available in ACP, EXTENSIONS tabs, Youtube videos gallery, Categories video.
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.2.x & 3.3.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.
playgoods
Registered User
Posts: 60
Joined: Wed Jun 16, 2010 1:05 pm

Re: [DEV] Youtube Videos Gallery

Post by playgoods »

Galixte de EzCom wrote:
playgoods wrote:How do you create different categories?
I's fixed: https://github.com/dmzx/youtubegallery/ ... 6587c9fdb3. Update from GitHub.

Create category is available in ACP, EXTENSIONS tabs, Youtube videos gallery, Categories video.
I updated the files. Category section is not showing
User avatar
Galixte de EzCom
Registered User
Posts: 1106
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.

Re: [DEV] Youtube Videos Gallery

Post by Galixte de EzCom »

Uninstall the extension by deleteing data, then re-activate the extension, sorry.
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.2.x & 3.3.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.
User avatar
noth
Registered User
Posts: 2528
Joined: Fri Jan 07, 2005 7:10 pm
Location: North Surrey

Re: [DEV] Youtube Videos Gallery

Post by noth »

I have just updated from 0.1.3 to 0.1.4 and am getting this
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/pagination.php on line 139: Division by zero
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/pagination.php on line 287: Division by zero
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/pagination.php on line 287: Division by zero
[phpBB Debug] PHP Warning: in file [ROOT]/phpbb/pagination.php on line 301: Division by zero
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5277: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3903)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5277: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3903)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 5277: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3903)
in addition to that
Enable comments on videos:
This option will display the comment on video page.
pressing Submit the whole page just freezes and nothing happens and Comments are not enabled
User avatar
tamarin
Registered User
Posts: 120
Joined: Tue Feb 03, 2015 9:02 pm
Location: Germany
Name: Ed

Re: [DEV] Youtube Videos Gallery

Post by tamarin »

When I upgrade came this error:

Unable to get information about the latest version.
The requested file is not found: youtubegallery_version.json

Can you help me please?
Thx
Last edited by tamarin on Mon Nov 16, 2015 9:19 pm, edited 1 time in total.
User avatar
dmzx
Registered User
Posts: 866
Joined: Fri Sep 05, 2014 6:48 am
Location: The Netherlands

Re: [DEV] Youtube Videos Gallery

Post by dmzx »

tamarin wrote:When you upgrade came this error:

Unable to get information about the latest version.
The requested file is not found: youtubegallery_version.json

Can you help me please?
Thx
Added file now so must be ok if you check the version.
Contact me on dmzx-web.net
User avatar
tamarin
Registered User
Posts: 120
Joined: Tue Feb 03, 2015 9:02 pm
Location: Germany
Name: Ed

Re: [DEV] Youtube Videos Gallery

Post by tamarin »

dmzx wrote:
tamarin wrote:When you upgrade came this error:

Unable to get information about the latest version.
The requested file is not found: youtubegallery_version.json

Can you help me please?
Thx
Added file now so must be ok if you check the version.
dmzx, thank you so much.
But where is the file?
User avatar
Galixte de EzCom
Registered User
Posts: 1106
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.

Re: [DEV] Youtube Videos Gallery

Post by Galixte de EzCom »

Hi,

this file is hosted on GitHub: http://www.dmzx-web.net/versions/youtub ... rsion.json. You do not have in your file system on your FTP.
Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.2.x & 3.3.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.
User avatar
tamarin
Registered User
Posts: 120
Joined: Tue Feb 03, 2015 9:02 pm
Location: Germany
Name: Ed

Re: [DEV] Youtube Videos Gallery

Post by tamarin »

Galixte de EzCom wrote:Hi,

this file is hosted on GitHub: http://www.dmzx-web.net/versions/youtub ... rsion.json. You do not have in your file system on your FTP.
Where and how it is inserted?
Thank you in advance.
User avatar
Galixte de EzCom
Registered User
Posts: 1106
Joined: Mon Oct 04, 2004 11:14 pm
Location: France
Name: Raphaël M.

Re: [DEV] Youtube Videos Gallery

Post by Galixte de EzCom »

Communau EzCom
📖 « Traductions d’extensions & styles pour phpBB 3.2.x & 3.3.x ».
📋 Lists of all extensions identified for phpBB 3.1.x & 3.2.x.
📋 Lists of all styles identified for phpBB 3.1.x & 3.2.x.
Image Tu as un forum et tu veux aussi un site web ? Regarde par ici.
User avatar
tamarin
Registered User
Posts: 120
Joined: Tue Feb 03, 2015 9:02 pm
Location: Germany
Name: Ed

Re: [DEV] Youtube Videos Gallery

Post by tamarin »

Excuse me, but now I do not understand anything.
User avatar
dmzx
Registered User
Posts: 866
Joined: Fri Sep 05, 2014 6:48 am
Location: The Netherlands

Re: [DEV] Youtube Videos Gallery

Post by dmzx »

tamarin wrote:
Excuse me, but now I do not understand anything.
You don't have to anything no files needed.
Contact me on dmzx-web.net

Return to “Extensions in Development”