Hi,
If I read the documentation, I've the impression that a Youtube api key is required.
But in mine opinion it is only required if you want to import a youtube url for obtaining a thumbnail, title, etc. Correct?
If we want to import, we must have a Google api key with the correct youtube services.
After viewing the 'Obtaining a developer key for the YouTube Data Api' video, I've several questions/remarks.
- the video is somewhat outdated... :-)
- The Freebase service is not existing anymore. Not needed anymore?
- In the video there are speaking about a simple readonly API Access with API key and an OAuth 2.0 Client ID if we want to for example uploads etc. In the video the presenter is creating a OAuth 2.0 client.
See the following video how to obtain YouTube API key. When you get the API key, go to Phoca Gallery administration - into Options (tab General Settings) and paste this API key here. Save the options.
I conclude from the help that Phoca only uses the simple API Access. But why then in the video how to create a OAuth client?
I've tested the import with only simple API access and remarked two things:
- when importing a youtube url, a popup is presented where we must give the wanted youtube url and a category so that the generated thumbnail file will be saved in the correct phocagallery folder. After clicking on Past loaded data, the category is not saved and the thumbnail file is saved in the root phocagallery folder. A bug?
- Normally my Google API key is protected by HTTP referrers (web sites), a recommendation of Google.
I had to set the protection on None to get it working with phoca gallery.
The other software on my website, who is using the same Google api key, is working without any problem with the configured HTTP referrers, so what is blocking phoca? Tried to work with this log explorer from Google, to see the incomming requests, but no luck, a beast of a user interface :-(
A clue how to debug this?
Phoca Gallery Component Joomla 4 and use of Youtube
-
- Phoca Newbie
- Posts: 3
- Joined: 04 Nov 2022, 00:16
- Jan
- Phoca Hero
- Posts: 48714
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Phoca Gallery Component Joomla 4 and use of Youtube
Hi, yes YouTube is only required, when you want to automatically import the information about the video.
- Importing: Testing now, no problem there.


When you select the category, the category folder will be added to the image path (the category itself needs to be selected for the image) The category select box is here because of location path on the server not because of the category itself.
HTTP referrers - hmmm, really hard to say what can be wrong there with the HTTP referres
Do you get the same problem when you restrict it e.g. to IP?
Jan
- Importing: Testing now, no problem there.


When you select the category, the category folder will be added to the image path (the category itself needs to be selected for the image) The category select box is here because of location path on the server not because of the category itself.
HTTP referrers - hmmm, really hard to say what can be wrong there with the HTTP referres

Jan
If you find Phoca extensions useful, please support the project