Code Amp
Forum Replies Created
-
Apologies for the super late reply to this.
Every time I’m about to add this I hesitate and end up not adding the feature.
The thing is, we’re going to be changing a lot of the underlying code, so I can’t guarantee in the next major update, this won’t be removed… which leads me to think it’s not a smart choice to add it in right now.
I’d rather wait until we’ve restructure the plugin a little, and then add this feature in properly if that’s possible with the new architecture.
Sorry my update is not more positive right now, hopefully we can some traction on this a little further down the line.
Best
Hey @stephcerratti
I managed to figure out what this issue is 🙂
Essentially, the ACF shortcode doesn’t behave as expected when using it.
I tried the exact same shortcode (with a relationship field) in a reglar WP post, and it threw the same error… so that’s good to know the issue is not in our plugin.
It turns out the problem with relationship fields is there is not necessarily one way to display them (so I don’t think ACF has a default way to display the field)…
At least in my testing this was giving me the same issue.
Anway, I decided to make a new shortcode, which adds a simple display of relationship fields. You can find that here:
https://gist.github.com/rmorse/22982fe907988359bd10ace36ce790bf#file-acf-relationship-field-shortcode-phpYou first need to copy that to your themes functions.php file (it should be in your child theme).
The way to use this is like this:
https://snipboard.io/rmsgER.jpg
[ca_acf_relationship_field field="field_name"]If you want to customise how this looks, you’ll have to modify the first code snippet I provided (the github link).
Give that a spin and let me know if it works out for you?
Best
– Ross- This reply was modified 4 years, 7 months ago by Code Amp.
Thanks @stephcerratti
I’ll be testing compatibility with ACF again tomorrow, hopefully I can recreate your issue!
Best
Hey @cheekypoppet
I took a look at this and could not recreate – please see this gif of my experience:
https://drive.google.com/file/d/1BgOfjkpPQCNqQkQgBUgLLnocjYblkih1/view?usp=sharingI wonder if something else in your setup is causing this, or if it a specific configuration that triggers this.
Would you be able to test this on a clean (dev) install?
Best
Forum: Reviews
In reply to: [Custom Layouts - Post + Product grids made easy] Really Nice PluginHey @lazsystems
Thanks for your kind words!
We don’t support inlining multiple elements on one line within the plugin (we’re going to add it though) but I think it can be achieved with some clever CSS…
Want to open a support ticket and I’ll see if I can find something to help?
https://ww.wp.xz.cn/support/plugin/custom-layouts/Best
- This reply was modified 4 years, 7 months ago by Code Amp.
Hi Stephanie
That’s a shame, we’ve tested with other ACF shortcodes and everything seemed to work ok :/
What would be useful is to find out what the exact error is.
Would you be able to enable
WP_DEBUGandWP_DEBUG_DISPLAYon your site so we can see what the error was?
How to enable: https://codex.ww.wp.xz.cn/WP_DEBUGEssentially this requires you adding/updating two lines of code in your
wp-config.phpfile:define( 'WP_DEBUG', true ); define( 'WP_DEBUG_DISPLAY', true );Then we should see a more detailed error message instead of the one I can see in your screenshot.
Best
- This reply was modified 4 years, 7 months ago by Code Amp.
Hey @cheekypoppet !
Yeah that does sound like a bug, I will investigate today / tomorrow and add a fix if needed.
Best
Hi Stephanie
This looks like a relationship field, which we don’t support out the box with our
Custom Fieldelement.However, you can use ACF shortcodes, in our
Textblock, to display this field correctly.Do let me know if that is a viable alternative for you (and that it works!)?
Best
- This reply was modified 4 years, 7 months ago by Code Amp.
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Stop scroll to top?Hey @cheekypoppet
I’m afraid I really don’t know a way to quickly implement this feature…
The only 2 options I see require a good amount of (not very straight forward) coding…
1. First option would be to hide the pagination, and set the layout to load more results than you need (say, 10 results). Then you write some custom css / javascript, to show only the 1st 5 posts, and implement your own JS based pagination so when you click “next” it would show the next 5
2. Any other solution I think would essentially require me to build out the feature – I know how we’ll tackle it (as we have a similar feature in our other plugin), but just need to get round to the implementation – the list is pretty long at the moment, and the main priority is an update planned for early next year which changes a lot of the underlying architecture of the plugin – we need to make this change first before laying on more functionality (otherwise this double our workload for new features added before that point).
Sorry my response is not more positive right now, this will be addressed there are just a lot of other priorities ahead at the moment.
Best
Forum: Reviews
In reply to: [Custom Layouts - Post + Product grids made easy] Perfect!Thanks for the kind words @wutzelmutz !
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Product price elementGreat stuff, glad you are all setup 😀
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Product price elementHey @wutzelmutz
Glad that is working for you!
I’ve just added the ability to sort by the manual order in our beta:
https://customlayouts.com/documentation/beta/Once you install that, you need to sort by Manual order and it will respect the custom WC order 🙂
Best
PS: If you have the time, a review would be greatly appreciated (no problem if not!)
https://ww.wp.xz.cn/support/plugin/custom-layouts/reviews/- This reply was modified 4 years, 7 months ago by Code Amp.
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Feature RequestsHey again @cheekypoppet !
Thanks for your feedback too. To answer your points:
1. Yeah, we’ll be adding the option to build your pagination visually (just like with templates and layouts) – not quite sure yet on how to add this into the worflow of the plugin, but there will probably be a “pagination block” which you will be able to style / design.
2. While I have been thinking a lot about google fonts, there is another issue by doing this. If we add google fonts, and you choose to load a font that matches your theme, then the font will be loaded twice, which is really not ideal (additional requests will slow down your page, and font files are usually fairly large)…
Of course, I’m not saying we’re not going to address this, just need to do a bit more research / planning on the best way to approach this.
3. Yeah you’re right, the custom class goes on the container element (sometimes there is no container depending on various settings of the element) but it is the outermost element so you get more flexibility to control it.
If you were using the link element, with a custom class, and wanted to modify that with css, then you can use:
.customclass > a { }However, if you want to override styles our plugin has added in the css, you might need a higher specificity class:
.cl-template--id-2376 .customclass > a.cl-element-link__anchor { }You would have to replace the template ID and the customclass in the rule.
We’re hoping to make this easier.
4. Great idea, lets put that on the roadmap
5. This will be coming when we support columns / rows – part of the big update planned hopefully early next year.
6. If you don’t exclude sticky posts, you should get default WP behaviour which is to put the sticky post at the top of the list – is that no what you are seeing?
Thanks for your kind words and sharing your ideas!
Best
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Stop scroll to top?Hey @cheekypoppet
You’re right regarding the page refresh – it’s “default” behaviour for links to cause a page refresh.
The plugin you mention, from what I can see (I think it’s the one on your homepage?), loads all the results at once, which means they can load the other results quite easily (without page refresh).
Our plugin, is designed to support any number of posts (thousands even), and we cannot preload all the results (because thousands of posts would slow down your page).
That being said, there is another way to do this (using ajax to fetch the new pages) and that’s something we should put on the roadmap / todo list.
Best
Forum: Plugins
In reply to: [Custom Layouts - Post + Product grids made easy] Product price elementHey @wutzelmutz
We’re hoping to add WooCommerce specific elements in the not too distant future (like a price element, “on sale” element, etc) to make all this easier.
Btw, are you using WooCommerce or another plugin?
If you are, this should still be possible. To add a product price element you would need to do the following:
1. Add a custom field element to your template
2. For the custom field, type / find:_price
3. Set the custom field to number formatting and 2 decimal placesRegarding ordering, what kind of order would you want to do this in? And how would you define which order the products are displayed in?
Best
– Ross- This reply was modified 4 years, 7 months ago by Code Amp.