Age | Commit message (Collapse) | Author | Files | Lines |
|
Add a user and category filter option for the post search in the
administration area. Filter on default theme is followed later.
|
|
Catch possible PDOException on search requests with queries like "*" and
pass the exception message to the template for displaying.
|
|
Add pagination for search results in the admin and default theme.
|
|
|
|
This commit adds new Repository and Entity classes which are better
abstracted from the rest of the application. They dont know anymore
about configuration options or how to parse to HTML because this is
not the job for the ORM but for other parts of the application.
The previous commits were a preparation for this big change.
An entity now represents just a single record from a specific table
of the database – nothing more. The repositories job is it to fetch
or update records of the database and instantiate the entities.
Another problem that was solved is the high amount of database queries
that was needed before. For example, on the blogs home page first were
all 10 latest post IDs fetched from the database and then another query
was executed with "WHERE id = :id" for *each* single post?! ...
This problem is solved with the new repository classes; they now use a
single query to fetch and build the entities of the 10 latest posts.
This change also solves the problem with database queries spread across
the application and limits the exzessive use of try/catch blocks which
were used before. The new classes make the whole code much cleaner. :)
|
|
|
|
|
|
Remove all try/catch blocks where the exception handling did not differ
from the exception handler already defined by "set_exception_handler".
|
|
Remove the unnecessary PHP closing tags and ensure that *all* text files ending with a LF character.
|
|
files was removed and some missing PHP closing tags were added.
|
|
administration area. In addition, some markup within the "/*/index.php" files of the admin template was re-formatted.
|