PHP Reddit – Telegram
PHP Reddit
33 subscribers
293 photos
37 videos
24.9K links
Channel to sync with /r/PHP /r/Laravel /r/Symfony. Powered by awesome @r_channels and @reddit2telegram
Download Telegram
Temporary hosting support for 7.4

I’ve agreed to an updated (rebuild) of a web app that I built probably 5 years ago now. Unfortunately, it relies on 7.4 and the framework (CI3) doesn’t look to be compatible with 8.x

It’s hosted on Heroku, the stack for which is already EOL and from May it will no longer allow the app to be built, so anything major that goes wrong, we’re screwed.

There’s no way I’m going to be able to complete the update by May, so can anyone advise any other hosting service (ideally deployable with git etc) that will buy me a few more months of 7.4 support so I can leave the old one as is until the new is ready?

Thanks in advance

https://redd.it/1j1vdpj
@r_php
Weekly /r/Laravel Help Thread

Ask your Laravel help questions here. To improve your chances of getting an answer from the community, here are some tips:

What steps have you taken so far?
What have you tried from the documentation?
Did you provide any error messages you are getting?
Are you able to provide instructions to replicate the issue?
Did you provide a code example?
Please don't post a screenshot of your code. Use the code block in the Reddit text editor and ensure it's formatted correctly.

For more immediate support, you can ask in the official Laravel Discord.

Thanks and welcome to the r/Laravel community!

https://redd.it/1j1wz97
@r_php
🚀 Introducing Keysmith Vue – Laravel 12 + Vue Starterkit API Token Management 🔑

Hey everyone! 👋

I've just released Keysmith Vue v1.0.1, a Laravel 12 Vue Starterkit package that simplifies API token management using Laravel Sanctum. It provides pre-built Vue components for generating, managing, and revoking API keys— based on the Laravel breeze implementation 🎉

🔑 Key Features:
API Token Generation & Management with Laravel Sanctum
Pre-built Vue 3 Components
Flexible Installation – Choose between Page or Settings templates
Customizable Permissions via config/keysmith.php
Secure Light and Dark Modes


I plan on releasing React and Livewire versions in the near future


You can take a look at the package and documentation here https://github.com/Blaspsoft/keysmith-vue



https://redd.it/1j21omj
@r_php
Reminder: if you prefer to develop on Homestead, it's still maintained as a fork!

Some people don't like the new development solutions offered by Laravel, such as Herd (which, let's not forget, it's not an official Laravel product).

Luckily, the good old Laravel Homestead is still maintained by the original author, just under a new fork.

Switching is easy, as the developer says:

>You should be able to destroy your laravel/homestead VM, copy your Homestead.yaml into the forked repo, and spin up a fresh instance from there. If not please come back and open an issue and let me know what went wrong.

GitHub repo: https://github.com/svpernova09/homestead

If you, like me, prefer to develop on a Homestead machine, show your support to the developer and don't forget to star the repo!

https://redd.it/1j21sbw
@r_php
Interface typehinting on phpstan

I have a question regarding interface type hinting on strict mode. I have an interface that several classes implements and each class return different types and I'm forced to make it mixed to make phpstan happy:

Interface:

/**

* Get the wrapper content.

*

* @ return array<mixed, mixed> The content.

*/

public function getContent(): array;


How do I go about explicitly typing return type of the implementing classes while having generalized return type to my interface? Or should I just get rid of the interface itself and have more control to the specific classes that implement the method?

https://redd.it/1j27osl
@r_php
Weekly Ask Anything Thread

Feel free to ask any questions you think may not warrant a post. Asking for help here is also fine.

https://redd.it/1j2aaaa
@r_php
Weekly help thread

Hey there!

This subreddit isn't meant for help threads, though there's one exception to the rule: in this thread you can ask anything you want PHP related, someone will probably be able to help you out!

https://redd.it/1j2cwpc
@r_php
Did they add breeze back to laravel installer? or does my laravel installer have a bug?

I have decided to try laravel 12. So I updated the laravel/installer to latest version 5.13.0. I run laravel new command and I see same prompts like in laravel 11. Asked me if I want to use breeze or jetstream or none. Then which breeze stack etc.

I do not see the new prompt screens shown on documentation.

After installing and running npm install. I can visit the default breeze react starter site without any issue. Laravel v12, inertia v2, react v18. Not react v19, no shadcn.

Anyone having similar issue?

I even removed and installed laravel/installer package just to be sure.

https://redd.it/1j2dttp
@r_php
My Laravel Packages

Hi everyone. I have created 2 packages for Laravel that may be useful to some of you.

1. Laravel Livewire CRUD

This package provides a comprehensive solution for CRUD operations within your Laravel applications, offering a streamlined and reusable approach for managing data. Whether you're working with Laravel controllers or Livewire components, this package allows you to:

Simplify common CRUD operations (create, read, update, delete) by abstracting and consolidating logic and reducing boilerplate code.
Enhance productivity by providing out-of-the-box methods for storing, updating, and deleting records.
Integrate seamlessly with both Laravel and Livewire, making it easy to use in traditional controllers or real-time components.
Ensure consistency across your application with standardized CRUD methods for various models.
Support bulk actions, enabling efficient mass deletion or updates of records.
Reduce development time by leveraging reusable methods for model interactions, validation and error handling.


https://github.com/milenmk/laravel-livewire-crud

2. Laravel locations

Add Countries, Cities, Areas, Languages and Currencies models to your Laravel application

https://github.com/milenmk/laravel-locations

https://redd.it/1j2ej86
@r_php
Bugsnag alternative for local installation

I’m looking for an alternative for bugsnag for local installation. I hate ELK stack, and I couldn’t connect it to all of the apps properly. It is such a headache. I’m looking for something similar to bugsnag where I composer require the package and voila. And it has to be on premise

https://redd.it/1j2eg1g
@r_php
How do you discover new/changed features in the framework?

I think it's great that Laravel is focusing on attracting new developers. And the documentation \*is\* pretty good. In fact I think it's worth reading from start to finish at least once every couple of years. But my question is this: How am I supposed to stay informed about new or changed framework features after that? Here are some comments/observations in no particular order. Because it's definitely \*not\* a rant /s.

* The upgrade notes for new major versions only tell you about breaking changes, and most new additions aren't breaking. That's how it should be. It just means you can't "Just read the upgrade notes" to get an overview of what has changed.
* New features are usually including in the weekly releases, which \*do\* have something that resembles release notes, but it's just an auto generated list of commit messages that usually don't explain a whole lot about what they actually do. And the lack of conventional commit messages make it harder to find what's relevant. I'm not arguing that it should be beautiful prose, and I don't mind diving into the source to see the details - I just don't want to review the entire diff every week because it's impossible to spot which commits are relevant.
* I browse Laravel News at least once a week. IMO this is probably the best source of information about new features for people like me who don't use twitter/mastodon/bluesky/whatever people are using this week. But it's kind of hit or miss. And their community "Links" section don't seem to be moderated at all. The [What's New in Laravel 12 : Latest Features and Updates](https://www.bacancytechnology.com/blog/laravel-12-features-updates) blog post looks like what I need (it even has a star, whatever that means), but it's just AI hallucinations and word salad from start to finish. About what you'd expect from a Google search, but this is supposedly the "official" Laravel news site (check the "News" footer link on laravel.com).

I hope some of you can enlighten me. Especially if it doesn't involve "just follow these 25 people on these 4 social media sites".

https://redd.it/1j2k7sc
@r_php
Xdebug Helper Chrome Extension alternative?

The recent Chrome update that prevents things like uBlockOrigin from working also seems to have taken out the old Xdebug Helper extension as well. I've never really thought about how else to approach activating Xdebug from the browser, other than [annoyingly\] having to append the full query param string whenever I want to use it. Is there some alternative I'm not thinking of? There's a handful of Chrome extensions that purport to do the same as the original that seem to be active still, but very few installs and reviews, so I'm iffy on trusting those.

How are you using Xdebug from the browser?

https://redd.it/1j2jp63
@r_php
Who offers affordable Wordpress hosting with CI/CD with zero-downtime dep

I got a simple site im setting up and I want to be able to push an update to my github repo that has my theme and plugins. I saw render.com but it doesnt offer zero-downtime for deployments if you have a persistent disk....meaning what if I upload images like for blog post...they wont stay so.....Now im confused on how to even do CI/CD where I can have a realistic WordPress site, using Github, and not have downtime when I push updates.

https://redd.it/1j2ndqg
@r_php
Model attributes are easy to discover

I saw a post a few days ago where everyone was asked what they could have in Laravel if they got their wish. So many people talked about the models having attributes and stuff that they couldn't just see that in their code.

I'm not saying that you'll get intellisense or other ide helpers, but model:show is awesome and has been around for a while.

Here's a tutorial so that you can access this info super fast in vs code.

https://www.openfunctioncomputers.com/blog/quick-access-to-laravel-model-info-in-vs-code

https://redd.it/1j2u7bf
@r_php