The form cache is pretty terrible: - Almost any time a form loads, a bunch of data (emphasis on a bunch if there are options like a country selection) gets serialized and pumped into the form cache. - It's usually optimal to move the cache outside the database, but forms break if a form cache entry disappears before the user submits the form. - After the form is submitted, the application has to load the form cache data back out, unserialize it, and compare the known, provided form against the submitted data.
Instead, it could work one of these ways, at least for POST forms: - Easy: Serialize and include the "form cache" data as a hidden field. Add one more hidden field that's an HMAC of the data and site's secret/salt, forming a signature. When the form gets submitted, validate the signature on the data. If it matches, then use the data as before. - Harder but lighter weight: Add capability tokens (mini signatures) to each option or validation requirement in a form. On submission, validate those signatures. This would remove the need to compare the submitted form against options provided.
Of course, I would roll this into Drupal or Pressflow following development in Backdrop, but I feel like this might be a nice place to start. The big upside for the casual user is more performance (no server-side tracking) with less to configure (the cache bin for forms).
Recent comments
Hi. I use the "[node:title] | [site:name]" tokens for the main image of news articles, blog posts, and similar publications. It's a quick and practical automatic ALT.
How to Improve SEO Performance in Backdrop CMS
I understand how tokens work, but not so much their practical use in image alt/text (maybe caption?) text. Could you give an example or two?
How to Improve SEO Performance in Backdrop CMS
https://backdropcms.org/project/metatag https://backdropcms.org/project/xmlsitemap https://backdropcms.org/project/imagefield_tokens These are more powerful modules, in my opinion...
How to Improve SEO Performance in Backdrop CMS