Comments (27)
i Had same issue, any solution?
from youtube.
Can you please show me your code?
from youtube.
and this is the response when i try to upload..
Google_Service_Exception not found
from youtube.
public function store(Request $request)
{
//
$video = Youtube::upload($request->file('video')->getPathName(), [
'title' => $request->input('title'),
'description' => $request->input('description')
]));
return "Video uploaded successfully. Video ID is ". $video->getVideoId();
}
from youtube.
One more thing I want to ask I am using using https on live server So when I am using https://your_domain/youtube/auth I am getting "Error 400: redirect_uri_mismatch"
from youtube.
@Ali07 @Jhilik11 preferably your controllers please.
from youtube.
@joedawson am i missing something?
from youtube.
from youtube.
Can you paste your controllers here?
from youtube.
class VideoController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Http\Response|\Illuminate\View\View
*/
public function index()
{
//
return view('video');
}
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function create()
{
//
}
/**
* Store a newly created resource in storage.
*
* @param \Illuminate\Http\Request $request
* @return string
*/
public function store(Request $request)
{
//
$video = Youtube::upload($request->file('video')->getPathName(), [
'title' => $request->input('title'),
'description' => $request->input('description')
]);
return "Video uploaded successfully. Video ID is ". $video->getVideoId();
}
/**
* Display the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function show($id)
{
//
}
/**
* Show the form for editing the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function edit($id)
{
//
}
/**
* Update the specified resource in storage.
*
* @param \Illuminate\Http\Request $request
* @param int $id
* @return \Illuminate\Http\Response
*/
public function update(Request $request, $id)
{
//
}
/**
* Remove the specified resource from storage.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function destroy($id)
{
//
}
}
from youtube.
@Jhilik11 The full controller please!
from youtube.
Everything from <?php onwards
from youtube.
``<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Youtube;
class VideoController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Contracts\Foundation\Application|\Illuminate\Contracts\View\Factory|\Illuminate\Http\Response|\Illuminate\View\View
*/
public function index()
{
//
return view('video');
}
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function create()
{
//
}
/**
* Store a newly created resource in storage.
*
* @param \Illuminate\Http\Request $request
* @return string
*/
public function store(Request $request)
{
//
$video = Youtube::upload($request->file('video')->getPathName(), [
'title' => $request->input('title'),
'description' => $request->input('description')
]);
return "Video uploaded successfully. Video ID is ". $video->getVideoId();
}
/**
* Display the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function show($id)
{
//
}
/**
* Show the form for editing the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function edit($id)
{
//
}
/**
* Update the specified resource in storage.
*
* @param \Illuminate\Http\Request $request
* @param int $id
* @return \Illuminate\Http\Response
*/
public function update(Request $request, $id)
{
//
}
/**
* Remove the specified resource from storage.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function destroy($id)
{
//
}
}
from youtube.
@Jhilik11 have you also registered the alias in config/app.php
?
'aliases' => [
...
'Youtube' => Dawson\Youtube\Facades\Youtube::class,
],
from youtube.
Yes
from youtube.
Yes
Does running composer dump-autoload
resolve your issue?
from youtube.
I tried still not working
from youtube.
What version of the package are you using?
from youtube.
"dawson/youtube": "^5.0",
from youtube.
I have the same problem with Laravel 8. Worked with Laravel 7
from youtube.
This error happens when executing this line of code: $status = $media->nextChunk($chunk);
from youtube.
This is not related to the package. It works after updating my dependencies:
....
- Updating google/apiclient-services (v0.147 => v0.148): Downloading (100%)
- Updating guzzlehttp/promises (v1.3.1 => 1.4.0): Downloading (100%)
- Updating guzzlehttp/psr7 (1.6.1 => 1.7.0): Downloading (100%)
- Updating laravel/framework (v8.6.0 => v8.7.1): Downloading (100%)
- Updating guzzlehttp/guzzle (7.1.0 => 7.1.1): Downloading (100%)
....
Probably something bogus with the previous version of some guzzle related packages (or guzzlehttp/guzzle itself)
from youtube.
can I see your dependencies? i still get the error.. @topclaudy
from youtube.
@Ali07 I listed the related dependencies in my previous post
from youtube.
@Jhilik11 @Ali07 are either of you still experiencing an issue after updating your packages?
from youtube.
yes
from youtube.
@joedawson i'm good, i think the problem from the API, took sometime to get the data... thank you..
from youtube.
Related Issues (20)
- quotaExceeded - Exception returns error 500 HOT 4
- Undefined index: created HOT 1
- Re-authenticate HOT 1
- Playlist HOT 1
- 1MB chunk hardcoded should be moved to config HOT 1
- Upload with public parameter got blocked (private) on youtube HOT 1
- While uploading unlisted video it got uploaded as private HOT 2
- Add support to Laravel 8 HOT 1
- how can i make a playlist and push video to it ? HOT 1
- Add possibility to set embeddable status attribute
- How can I Share private youtube videos automatically? HOT 1
- Can't delete a youtube video
- call_user_func_array() expects parameter 1 to be a valid callback, class 'Google\Client' does not have a method 'getVideoInfo'
- PHP 8 and/or 8.1 support? HOT 2
- filesize(): stat failed error HOT 1
- Laravel 9 compatibility HOT 1
- Videos locked in private mode
- Why attaching thumbnail image is I got permissions error ?
- Suggestion: Option to adding videos to a youtube playlist id
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from youtube.