Dynamic page loading#3732
Draft
partydragen wants to merge 1 commit into
Draft
Conversation
supercrafter100
requested changes
Jun 4, 2026
Comment on lines
+112
to
+117
| foreach ($all_pages as $page_route => $page) { | ||
| $regex = preg_replace( | ||
| '/\{([a-zA-Z0-9_]+)\}/', | ||
| '(?P<$1>[^/]+)', | ||
| $page_route | ||
| ); |
Member
There was a problem hiding this comment.
Maybe explain through a comment here what this code does instead of letting users guess
Comment on lines
+124
to
+126
| if (!is_int($key)) { | ||
| $route_params[$key] = $value; | ||
| } |
Member
There was a problem hiding this comment.
Mention why this is_int is needed, this is a side effect of the regex constructed earlier and the named parameters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add dynamic page loading, Allows to eaiser create friendly urls and having ids in path
such as
/community/{id}
/community/{id}/edit
/community/{id}/edit/members
current old behavior does not allow this ^^ other than smashing it all into same page, now we can properly split it all into own files