Open jawabuu opened 5 years ago
Hi @jawabuu,
sorry, but this is not currently possible with VersionPress :-(
If I understand it correctly, there is no way to filter file names in Elementor to change it from post-ID.css
to post-name.css
or something else: https://github.com/elementor/elementor/issues/3553
VersionPress tries to ignore original IDs to simplify development workflow, but some problems appeared, see for example related issue: https://github.com/versionpress/versionpress/issues/1189
There is also a recent discussion related to tracking original IDs: https://github.com/versionpress/versionpress/issues/1420
Thank you @pavelevap. Appreciate the great work you're all doing with versionpress and your quick response. I'm looking for more of a workaround. I don't need the filenames changed, I'm thinking of an elementor schema.yml that would reference the file with the original id inspite of versionpress changing the id. I believe this is what you do with the wordpress profile image?
I understand it, but Elementor probably generates files with original IDs which is a problem for VersionPress. Even if we could handle it on database layer (with schema.yml
), for example change post-ID
to post-VPID
in database, then .css
files would be still problematic (with different IDs on different environments). Sorry, I do not see any way to bypass it for now :-(
I understand. I think the only option for such scenarios would be a versionpress that preserves post-ids. Is there a branch that I can use that does this or an issue about preserving ids that I can track? Many thanks.
Currently only this issue: https://github.com/versionpress/versionpress/issues/1420
Alright, should I close this?
Hi @jawabuu,
sorry, but this is not currently possible with VersionPress :-(
If I understand it correctly, there is no way to filter file names in Elementor to change it from
post-ID.css
topost-name.css
or something else: elementor/elementor#3553VersionPress tries to ignore original IDs to simplify development workflow, but some problems appeared, see for example related issue: versionpress/versionpress#1189
There is also a recent discussion related to tracking original IDs: versionpress/versionpress#1420
Hey @pavelevap just found out that a filter for css filenames has been implemented for elementor here https://github.com/elementor/elementor/issues/5968 Is this sufficient to solve my issue?
Please be specific when describing the issue. Also, these details will help:
I'm trying to use versionpress with elementor. In my workflow all page edits are done on dev environments and pushed to live wordpress instance. Here's a db entry in posts for a page in dev created with elementor it has id 33
Modernize Your Web Design
Te maior...
On pushing to live the id for the page is now 24
Modernize Your Web Design
Te maior...
Elementor creates css files on disk with the post-id appended i.e. wp-content/uploads/elementor/css/post-33.css which are committed by versionpress and pushed.
However on the live site since the post-id changes, the page on the live site is trying to reference wp-content/uploads/elementor/css/post-24.css which does not exist and breaks the page.
Is there a way to preserve file references for plugins?
Additional Info:
postmeta in dev post_id: 33 meta_key: _elementor_css meta_value: a:4:{s:4:"time";i:1555949618;s:5:"fonts";a:3:{i:0;s:11:"Fredoka One";i:1;s:6:"Nunito";i:2;s:7:"Poppins";}s:6:"status";s:4:"file";i:0;s:0:"";}
postmeta in live post_id: 24 meta_key: _elementor_css meta_value: a:4:{s:4:"time";i:1555949618;s:5:"fonts";a:3:{i:0;s:11:"Fredoka One";i:1;s:6:"Nunito";i:2;s:7:"Poppins";}s:6:"status";s:4:"file";i:0;s:0:"";}