-
AuthorPosts
-
June 8, 2024 at 1:37 pm #1448682
Hey guys,
Is it possible to override the register-demo-import.php in a child theme to register a new custom demo?
or
what is the best approach to register / add a new custom demo?Thanks in advance Lee
June 9, 2024 at 2:04 pm #1448711Hey nivotechwd,
Thank you for your patience, from your other posts I understand that you plan on creating custom demos to sell. I recommend creating your demo and then exporting it in: WordPress ▸ Tools ▸ Export ▸ All content this will give you a .xml file, and this is the file that you can give to your customers for them to import at WordPress ▸ Tools ▸ Import this will be the easiest for your customers.
The Enfold demo uses this function to import the buit-in demos. You can not override the register-demo-import.php in a child theme.
After you create the .xml file you should note that when your customer imports the demo with this file it will call the images from your original demo url, so unless you plan on leaving this online for your customers to review, I recommend copying the images in the same structure to a online storage and then open the .xml file with VScode and change the urls to your new location, either your server or github or whatever.
I hope this makes sense.Best regards,
MikeJune 9, 2024 at 3:12 pm #1448714Hey Mike,
Thanks for your reply!I’ve exported the XML file but the WP export only includes the content, it doesn’t include Theme Settings, Fonts or Custom Icons used in the custom demo etc.
So I can’t class it as a demo. Or am I missing something?I can create docs for importing everything separately but it’s not ideal.
It’s a shame there isn’t any filter/hook for creating custom demo imports. It would be great for demo designers!
Thanks for the heads-up about image URLs!
Thanks, Lee
June 9, 2024 at 4:59 pm #1448720Hi,
You can also export the theme setting file and give it to your customer, so them the customer has only two files to import, the .xml for the demo content and images, and the theme settings file at Enfold Theme Options ▸ Import/Export ▸ Import Theme SettingsBest regards,
MikeJune 9, 2024 at 8:10 pm #1448734Thanks, Mike.
Yes, I can do that however when I import the theme settings file the settings for general styling for font selection, any font import in the Custom Font Manager and IconFont Manager icons, widgets are not loaded in the theme settings when imported.
So I can’t replicate the demo without completing quite a few steps. So it’s not really viable :((((
You don’t know if any future releases will include any demo import functionality/hooks/filters do you?
Cheers Lee
June 9, 2024 at 9:20 pm #1448743Hi,
I know that you have seen our documentation for creating the demo files, but I will post the link here again for other Mods. I have reach out to the rest of the team for recommendations, perhaps I have overlooked something.
We are all in different time zones and it is the weekend here, so it might take a day or so for some feedback, Thank you for your patience.Best regards,
MikeJune 12, 2024 at 3:30 pm #1449068Hi Mike
Thanks, yes I read the docs and I have exported the php/txt settings and XML for the demo.
and I can “manually” register a new demo import in the register-demo-import.php which is great.
but doing this manually every time is not viable especially if I want to offer these demos to customers
and importing via just XML and standard theme settings file does not import everything (Custom Font Manager and IconFont Manager icons, widgets)
does anyone have any suggestions on how to import or register a custom demo that is not manual?
June 12, 2024 at 10:24 pm #1449141 -
AuthorPosts
- You must be logged in to reply to this topic.