$re = '/^\|.*\|\n\|\s*[:-]+.*\n(?:\|.*\|\n)*/m';
$str = '# Project Overview
Welcome to the project overview document. This document provides a summary of the project, including key milestones and team members.
## Key Milestones
The following table outlines the key milestones for the project:
| Milestone | Description | Due Date |
|-----------------|--------------------------------------|------------|
| Project Kickoff | Initial project meeting | 2024-06-01 |
| Phase 1 | Completion of the first development phase | 2024-07-15 |
| Testing | Start of the testing phase | 2024-08-01 |
| Launch | Official project launch | 2024-09-01 |
## Team Members
Below is a table listing the team members involved in the project:
| Name | Role | Contact Email |
|-----------------|---------------------|------------------------|
| Alice Johnson | Project Manager | alice.johnson@example.com |
| Bob Smith | Lead Developer | bob.smith@example.com |
| Carol White | QA Engineer | carol.white@example.com |
| David Brown | UX Designer | david.brown@example.com |
';
preg_match_all($re, $str, $matches, PREG_SET_ORDER, 0);
// Print the entire match result
var_dump($matches);
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for PHP, please visit: http://php.net/manual/en/ref.pcre.php