• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Deeper Scenery

Further up and further in

  • Home
  • Blog
  • Code
  • Tutorials
  • Privacy Policy
You are here: Home / Ideas / OOP form library

Ideas · Published: August 29, 2018 · Modified: August 29, 2018

OOP form library

This is just a small idea. For more information, see this blog post.

There are a lot of libraries out there for generating HTML forms using PHP. So far, however, I haven’t found one that meets both of these things:

  • Simple, OOP usage.
  • Flexible enough rendering that I can use it anywhere, but especially within a WordPress plugin.

A bonus option would be a library that can be included potentially multiple times (like CMB2) without conflicts.

I really like Symfony Forms, but it seems like there’s either a strong coupling to using the Twig templating engine, or a lot of work to roll your own engine.

I also like Carbon Fields, but the downside is that it currently isn’t usable on the frontend. It’s also very strongly coupled to WordPress objects.

CMB2 is a really great library, and one of the best choices in my opinion for anything related to meta boxes in WordPress. It can even do frontend display with some advanced usage (which I’ve written about before). But it’s also integrated tightly to WordPress, and is set up to be more procedural than I would like for the scenario I’m looking at.

If anyone has suggestions, feel free to let me know 🙂

Filed Under: Ideas Tagged With: forms, oop

Previous Post: « Link a GitHub repo with WordPress
Next Post: Manually Running Shortcodes »

Reader Interactions

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Primary Sidebar

Subscribe to jeremypry.com

Enter your email address to subscribe to this site and receive notifications of new posts by email.

  • Home
  • Blog
  • Code
  • Ideas
  • Tutorial
  • Gifts
  • Privacy Policy

Copyright © 2025 · JPry Showcase Pro on Genesis Framework · WordPress · Log in