Code Amp
Forum Replies Created
-
I’ve been doing some testing with these hooks, and it seems some of them were not working.
We’ve held back our update, and will do a combined release with a bunch of new features, fixes for these hooks, and new hooks for elements too.
Look out for the next update in the next few days.
Thanks
- This reply was modified 5 years, 2 months ago by Code Amp.
For both Layouts and Templates, you can add custom classes via the admin UI by looking in the
Advancedpanel.If you want to add a class to the layout or template via code, you can use the
render_argsfilter.Hi both, so this is what we have currently in our code:
Layouts
Actions:
do_action( "custom-layouts\layout\before_render", $settings, $this->name );
do_action( "custom-layouts\layout\after_render", $settings, $this->name );Filters
$settings = apply_filters( 'custom-layouts\layout\render_args', $settings, $this->name );
$output = apply_filters( "custom-layouts\layout\render_output", $output, $this->name, $settings );Templates
Filters:
$settings = apply_filters( 'custom-layouts\template\render_args', $settings, $this->name );
$output = apply_filters( "custom-layouts\template\render_output", $output, $this->name, $settings );Actions
do_action( "custom-layouts\template\before_render", $settings, $this->name );
do_action( "custom-layouts\template\after_render", $settings, $this->name );—-
I think the actions speak for themselves… For the filters, for layouts and templates you have 2:
render_argsHere you can update $settings argument used to generate the render
render_outputThis contains the full html of what will be printed to screen, so you can manipulate this where necessary.
I think after reading both your comments, it would also be good to add the same actions/filters for individual elements?
– So we have a before/after render element action
– And we can update the args / output of each using a filtersWhat do you think?
(I am in the process of writing all this up on a new site we are building)
Hey @ashf,
We have a few hooks (we’re still building the website/docs) but maybe not for what you want to do exactly.
Can you explain a couple of things for me, and perhaps I can guide you (or add some hooks for you):
1) Where do you want to modify content?
2) What functionality are you trying to add to the tile?FYI, today/tomorrow, we’re adding support for basic custom fields and taxonomies.
Thanks
– Ross@slavallee did you manage to contact us / find the solution to your issue?
Hey @slavallee, absolutely we’re here to help.
So to understand this, you can create a template, however, when choosing it in the dropdown of a layout, the dropdown is not visible / empty?
It sounds like either a javascript error is occuring, or a something is affecting the query that gets the list of templates for the dropdown.
Can you contact us via S&F Pro support channel, linking this topic, we’ll then follow up and request access details to view the admin area?
Best
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Advanced post typeHey @jeanpoldupont – one of our next main features will be inserting ACF fields into our templates – hopefully in a month or two – after that at some point will come more query parameters 🙂
Best
Hi Lily
The excerpt should show the full excerpt (if you filled in the excerpt field in your posts), but it will show a cut down version of the full content up the number of words you set in your excerpt field.
So click on your excerpt in the template editor, and you will see the setting:
Limit Post Content length (words)– which you can set upto 100 words.Does that solve the issue? If not, if you can explain what I might be missunderstanding then I can try to advise further.
Thanks
– RossForum: Reviews
In reply to: [Custom Layouts - Post + Product grids made easy] Must have query builderThanks @onetrev !
We’ll be adding taxonomy + custom fields to the templates at some point, within the next few weeks I imagine (hope).
Later on today we’ll be releasing more query options for layouts (multiple post types + restrict by taxonomy)
Glad you’re liking so far.
– Ross
Forum: Plugins
In reply to: [Search & Filter] Did this update happen?We delayed, stalled, made some other things, and now this is finally in testing 🙂
Forum: Plugins
In reply to: [Search & Filter] Broken on Pods, order dependentHey @hrsms , we’re doing a huge plugin update (bringing our Pro admin UI to the free version) as well as many bug fixes in about a month.
Let me know if you have the same issues when the new upgrade arrives.
Thanks
Forum: Plugins
In reply to: [Search & Filter] eprecated: implode():This looks like a S&F Pro issue – we fixed this a while back – be sure you have an active license and update the plugin 🙂
Best
Forum: Plugins
In reply to: [Search & Filter] Several bugs preventing plugin from workingHi Corey
All this will be addressed in version 3 coming in about a month 🙂
Thanks
I’ve made the sample templates info more prominent now – thanks.
🙂