Skip to main content
The 2025 Developer Survey results are in. Explore insights into technology and tools, careers, community and more. View results.

PHP Collective

A collective where developers working with PHP can learn and connect about the open source scripting language.
1.5m Questions
+48
15.4k Members
+63
Contact

Pinned content

View all 3 collections

PHP admins have deemed these posts noteworthy.

Pinned
62 votes
6k views
2 minute read
How-to guide

Start learning PHP — Useful resources for beginners and advanced

Start learning PHP — Useful resources for beginners and advanced! If you're wondering where to start from learning the PHP language or needing some more knowledge to deep dive into the language, you ...
RB Projects's user avatar
Pinned
35 votes
8k views
Collection

Common Mistakes to Avoid in PHP

A list of real issues most beginners encounter when using PHP.
Sasha's user avatar
  • 101

Can you answer these questions?

View all unanswered questions

These questions still don't have an answer

1 vote
0 answers
32 views

On woocommerce search custom taxonomy doesn't work with 'relation' => 'AND' but it works with 'relation' => 'OR'

I am trying to build search for woocommerce. I am using woocommerce 9.7 and latest wordpress. And the search i want is with multiple taxonomies (categories) so I registered 2 more taxonomies on top of ...
-3 votes
0 answers
76 views

Script in Python CVE-2025-49113 Not receiving the connection

I'm currently developing an exploit script for CVE-2025-49113, a vulnerability affecting Roundcube versions 1.6.10 and earlier. This issue involves Remote Code Execution (RCE) via improper PHP object ...
0 votes
0 answers
25 views

Event subscriber not triggered — no listeners registered for product.search.criteria event?

I am developing a Shopware 6 plugin with the goal of sorting product search results by a custom field custom_product_ranking. I implemented an Event Subscriber listening to the ...
0 votes
0 answers
52 views

global scopes for get , all and paginate function in laravel

I write a trait in laravel named prioritiable and I add a global scope to the query to sort the query result based on priority value The problem is the scope add the order by SQL clause to all SELECT, ...
0 votes
0 answers
47 views

Why is my XCLASSes action for the EXT:sf_event_mgt EventController ignored?

I'm trying to add a button that allows users to subscribe to my event calender via a webcall:// link. I use type=9819 to trigger the function. I can‘t get my icalAction to work, it just gets ignored ...

Learn something new
These are the most recent articles in PHP Collective
2 votes
248 views
9 minute read
How-to guide

Quick guide to Laravel package development

Contents Introduction Types of packages Characteristics of a package The Laravel package! Components of a Laravel package Example of a Laravel package Creating your Laravel package 1- Package ...
Yousha Aleayoub's user avatar
2 votes
825 views
2 minute read
How-to guide

Properly removing API from Laravel project

Sometimes a development team may decide to remove all API functionality from a Laravel project for various reasons, such as: No longer needing any API, and shifting focus to web application with ...
Yousha Aleayoub's user avatar
10 votes
2k views
1 minute read
How-to guide

How to trim   (or non-breaking space) in PHP?

The main problem is the way trim() function works. One cannot reliably trim a substring using this function, because it takes its second argument as a collection of characters, each of which would be ...
Your Common Sense's user avatar
25 votes
57k views
3 minute read
Knowledge article

Evolution of Type Declarations in PHP

Introduction: PHP, being a dynamically typed language, traditionally allowed flexibility in variable types, providing both advantages and challenges in code maintenance and robustness. However, with ...
alkhatibdev's user avatar
62 votes
6k views
2 minute read
How-to guide

Start learning PHP — Useful resources for beginners and advanced

Start learning PHP — Useful resources for beginners and advanced! If you're wondering where to start from learning the PHP language or needing some more knowledge to deep dive into the language, you ...
RB Projects's user avatar