Replies: 1 comment 8 replies
-
Hello, Yes we should add per post/page options the core, and because of there is no ID than we can use the slug for the ID, example:
For folder we can put it in example, |
Beta Was this translation helpful? Give feedback.
8 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
For quite some time I've been thinking about starting this topic.
Current page structure, and the reasons it stays that way have been already mentioned in #718
But with new requests, and ideas adding even small things becomes problematic.
Every possible page option can't be stored in filename, and processing whole file to get the option stored in custom
<!-- tag -->
is tedious.How about moving page's options to new file attached to its parent?
For example by generating page ID, saving this ID in page name as an additional parameter, and use this ID for option's filename.
This ID could be even the page's creation date, thus we would get
this way all content stays without changes in future updates, and we get new possibilities with additional page options.
For backwards compatibility, and to prevent data loss, all tags stored in posts files should still be there.
Just to mention
<!--t title t--> <!--d description d--> <!--tag tags tag--> <!--image page type header-->
Why? If page's options file becomes corrupted, or has no data at all, htmly would still display all content just like it does now as a fallback, skipping unavailable data from options file.
I'm not sure about the data structure for options file. Probably in json format, maybe xml or a custom one, you name it.
Changing or adding new options to page wouldn't update post file (except currently existing page options like tag, category...) thus it wouldn't have impact on last modification date.
In some use cases data shown on website - like showing blog posts with featured images and excerpts - wouldn't even process the post file, because all data could be taken from options file. Like image/video/quote, excerpt, tags, category, author etcetera.
Even adding an option to pin a page as a featured post on top of the list would be available straight away, although this one option is somehow doable by using tags. But using tags as additional option for missing features creates new problems along solving others.
I asked earlier for custom options for admin panel, similar to adding new fields in the custom settings for using them in templates.
This would open possibilities to create custom page's options by page admins.
Features that were asked and would benefit from this I can imagine right now are
Any thoughts about this whole idea?
Beta Was this translation helpful? Give feedback.
All reactions