Member Since 1 Year Ago
180 experience to go until the next level!
In case you were wondering, you earn Laracasts experience when you:
Earned once you have completed your first Laracasts lesson.
Earned once you have earned your first 1000 experience points.
Earned when you have been with Laracasts for 1 year.
Earned when you have been with Laracasts for 2 years.
Earned when you have been with Laracasts for 3 years.
Earned when you have been with Laracasts for 4 years.
Earned when you have been with Laracasts for 5 years.
Earned when at least one Laracasts series has been fully completed.
Earned after your first post on the Laracasts forum.
Earned once 100 Laracasts lessons have been completed.
Earned once you receive your first "Best Reply" award on the Laracasts forum.
Earned if you are a paying Laracasts subscriber.
Earned if you have a lifetime subscription to Laracasts.
Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.
Earned once you have achieved 500 forum replies.
Earned once your experience points passes 100,000.
Earned once your experience points hits 10,000.
Earned once 1000 Laracasts lessons have been completed.
Earned once your "Best Reply" award count is 100 or more.
Earned once your experience points passes 1 million.
Earned once your experience points ranks in the top 50 of all Laracasts users.
Earned once your experience points ranks in the top 10 of all Laracasts users.
Replied to Cannot Execute API Call To Another Laravel Website
file_get_contents()
returns the same error. And when I open the link in browser it works fine.
Started a new Conversation Cannot Execute API Call To Another Laravel Website
Hi everyone!
Today I was trying to execute API call with Guzzle to another service. But the problem is that if I do the request locally to that service, it works fine. it should be mentioned that when the service was at Modx such error still reproduced. Currently service is replaced by Laravel app.
But when I do the request from the dev server if fails with following error:
`GET http://mysite.com/api/v1/products?codes=1` resulted in a `415 Unsupported Media Type` response:
production.ERROR: #0 /home/..../vendor/guzzlehttp/guzzle/src/Middleware.php(65): GuzzleHttp\Exception\RequestException::create(Object(GuzzleHttp\Psr7\Request), Object(GuzzleHttp\Psr7\Response))
#1 /home/..../vendor/guzzlehttp/promises/src/Promise.php(204): GuzzleHttp\Middleware::GuzzleHttp\{closure}(Object(GuzzleHttp\Psr7\Response))
#2 /home/.../vendor/guzzlehttp/promises/src/Promise.php(153): GuzzleHttp\Promise\Promise::callHandler(1, Object(GuzzleHttp\Psr7\Response), NULL)
The following response headers present:
{"responseHeaders":{"Date":["Mon, 04 Jan 2021 10:43:42 GMT"],"Content-Type":["application/octet-stream"],"Transfer-Encoding":["chunked"],"Connection":["close"],"Server":["imunify360-webshield/1.13"]},"responseProtocol":"1.1"}
Can anyone help me?
Replied to Laravel Intervention/Image: Unable To Init From Given Binary Data.
I have found the root cause of the issue. The problem is not reproduced on Stage environment. It's reproduced only in local env. The expected root cause is that there are no image formats installed locally to recognize.
Replied to Laravel Intervention/Image: Unable To Init From Given Binary Data.
file_exists
doesn't work for file provided by url
Replied to Laravel Intervention/Image: Unable To Init From Given Binary Data.
If I'm trying to use Image::make($request->file('image'))
then I get the error like Unable to read image from path (D:\...\tmp\phpD64B.tmp)
Replied to Laravel Intervention/Image: Unable To Init From Given Binary Data.
Does anybody know how to fix it?
Started a new Conversation Laravel Intervention/Image: Unable To Init From Given Binary Data.
Hi everyone! I faced with the issue when I tried to use laravel intervention/image package. I have a Service class which have method with following logic e.g.:
return Image::make($imageUrl);
And I have console command which calls the service method. The problem is that if I execute artisan custom command everything is ok. But when I try to use this service inside controller it fails with the following error:
Intervention\Image\Exception\NotReadableException
Unable to read image from binary data.
Intervention\Image\Imagick\Decoder::initFromBinary
...\mysite.local\vendor\intervention\image\src\Intervention\Image\Imagick\Decoder.php:90
$imageUrl
is equal to http://somesite.com/image.jpg
.
Can you help me with that? No idea what happens.
Started a new Conversation Resources Compilation Error.
Hi everyone! I just started to use fresh Laravel 8.x with OOTB Mix Asset Management and tailwind.
The problem has been happen when I tried to compile additional .scss resources with sass(). With .css files as I thought no any problems. Error exists in console but .scss will be compiled into css successfully.
My code:
mix
.js('resources/js/app.js', 'public/js')
.sass('resources/css/template.scss', 'public/css/template.css') // here
.postCss('resources/css/app.css', 'public/css', [
require('postcss-import'),
require('tailwindcss'),
]);
The error:
ERROR in multi ./resources/js/app.js ./resources/css/template.scss ./resources/css/app.css
Module not found: Error: Can't resolve 'd:\mypathhere\resources\css\app.scss' in 'd:\mypathhere'
@ multi ./resources/js/app.js ./resources/css/template.scss ./resources/css/app.css /js/app[1]
How to fix it? I want to use tailwind and sass(). But it can't work together.
I think the same issue here: https://stackoverflow.com/questions/60696756/tailwind-laravel-mix-module-not-found-error-cant-resolve-scss-file
Replied to How To Prioritise Routes Properly?
yep. I have chosen last option to separate inside controller method and show different views due to my catalogPath has infinite category slugs
Started a new Conversation How To Prioritise Routes Properly?
Hi everyone!
I have two routes:
But there is a problem: showCategory() always got. How to fix it?
The structure of the route the same, but how can I navigate to showProduct() instead for the second case?
Route::get('/catalog/{catalogPath}.html', [CatalogController::class, 'showCategory'])
->where('catalogPath', '[a-zA-Z0-9/_-]+')
->name('category.show');
Route::get('/catalog/{catalogPath}/{productCode}.html', [CatalogController::class, 'showProduct'])
->where('catalogPath', '[a-zA-Z0-9/_-]+')
->where('productCode', '[a-zA-Z0-9_-]+')
->name('product.show');
Started a new Conversation Composer. Could Not Scan For Classes
Hi everyone! Could anyone help me with the following issue.
OS: Windows 10. Composer: 2.0.6
After running composer install command the error below was thrown:
92 package suggestions were added by new dependencies, use `composer suggest` to see details.
Package zendframework/zend-escaper is abandoned, you should avoid using it. Use laminas/laminas-escaper instead.
Package jakub-onderka/php-console-color is abandoned, you should avoid using it. Use php-parallel-lint/php-console-color instead.
Package jakub-onderka/php-console-highlighter is abandoned, you should avoid using it. Use php-parallel-lint/php-console-highlighter instead.
Package phpunit/php-token-stream is abandoned, you should avoid using it. No replacement was suggested.
Generating optimized autoload files
[RuntimeException]
Could not scan for classes inside "D:\wamp64\www\myproject\vendor/setasign/fpdf/fpdf.php" which does not appear to be a file nor a folder
Everything worked fine on Win 7. Maybe of the reason of having cache.
Started a new Conversation General Architecture Of Web Application
Hi there!
The main question is what layers can be for Laravel true web-application?
For example, the general architecture for Java web-applications is:
But I haven't any idea is it true to have Converters/Populators with DTOs or no, etc..