Core: Load assets on specific pages only
complete
Ziggeo
It would help with speed tests if the assets are not included on pages where they are not needed.
This could be done by setting which pages are to run Ziggeo, or by setting which pages should not add Ziggeo codes.
Alternative option would be to do this check automatically.
Ziggeo
This has been added to our plugin however within a specific branch on our Github repository here: https://github.com/Ziggeo/ziggeo-wordpress-plugin/tree/lazyload
This should provide you with a zip file that has all the changes included: https://github.com/Ziggeo/ziggeo-wordpress-plugin/archive/refs/heads/lazyload.zip
The way it works:
- If you are using video comments (required or with text) that feature will not work (otherwise our system would be loaded on all pages)
- To enable it you would go into Expert Settings and all the way at the bottom, you will find "Lazy Load" option.
Once it is loaded, it will still go through some parts of our plugin to see if has to load things. If it does, special definition is created which will output the values to the page that will be used to pull in all of our codes once the page has finished loading.
This should still help with the page load times even on the pages where there is our content.
Important: Because of how our codes are loaded later on, it is possible that there are some things not working properly. This is why we will not include it into the main plugin right away. We will be adding more details to our pages soon as well :)
Ziggeo
complete
Available on lazyload branch (please see comments)
Ziggeo
This has been added to our plugin however within a specific branch on our Github repository here: https://github.com/Ziggeo/ziggeo-wordpress-plugin/tree/lazyload
This should provide you with a zip file that has all the changes included: https://github.com/Ziggeo/ziggeo-wordpress-plugin/archive/refs/heads/lazyload.zip
The way it works:
- If you are using video comments (required or with text) that feature will not work (otherwise our system would be loaded on all pages)
- To enable it you would go into Expert Settings and all the way at the bottom, you will find "Lazy Load" option.
Once it is loaded, it will still go through some parts of our plugin to see if has to load things. If it does, special definition is created which will output the values to the page that will be used to pull in all of our codes once the page has finished loading.
This should still help with the page load times even on the pages where there is our content.
Important: Because of how our codes are loaded later on, it is possible that there are some things not working properly. This is why we will not include it into the main plugin right away. We will be adding more details to our pages soon as well :)
Ziggeo
in progress
ETA: 2 Weeks
M
Michael Cyger
Ziggeo: ❤️
Ziggeo
Information for any dev that is interested in this:
While this feature does not currently exist, we had already added some hooks that can allow someone to add such a feature to their plugin or theme.
These would use hooks like:
ziggeo_assets_init_raw_post
ziggeo_assets_pre_server_load
ziggeo_assets_pre_local_load
Also following constant:
ZIGGEO_PARSED_ASSETS
You can see all about them in our assets file: https://github.com/Ziggeo/ziggeo-wordpress-plugin/blob/master/core/assets.php
Ziggeo
Additional feedback:
A. Ziggeo Code turned OFF by default
B. Ziggeo Code turned OFF on Individual pages
A)
> By default the Ziggeo code should not be included in the header or footer of any page. Or at least there should be a setting that should let a user toggle that global inclusion on/off.
B)
> This is not as good a UX experience as the above, because the user would have to go into each page individually to turn the code off. This could be difficult in a site that already has a lot of pages.
Possible implementations
> 1. Create a check box somewhere on the WP page/post editor. Clicking the checkbox then includes the Ziggeo code on the WP front end on that page.
or
> 2. Or In the Ziggeo "settings" section have a search box. Allow users to search for words in the Title of the Page or Post. Once found it populates the search box and allows the user to select that page to be "Included". If this search option is chosen I would recommend the search operate over the page Title and Slug. If multiple pages are found the search box should return all pages and let the user "arrow" down to select the correct page.