No video

ACF Blocks Post Carousel Tutorial

  Рет қаралды 4,073

Brian Coords - WordPress Dev

Brian Coords - WordPress Dev

Күн бұрын

Пікірлер: 32
@demystifyingdev
@demystifyingdev Жыл бұрын
Very helpful and very clear! Will definitely be using, but more than anything, great learning experience because I finally understand what ACF blocks are. Yes! Deeper dive(s) into ACF blocks would be great!
@BrianCoords
@BrianCoords Жыл бұрын
Sounds great! I have a few more ACF Blocks ideas on the way.
@umidjonzoxidov
@umidjonzoxidov 3 ай бұрын
Very useful, thank you!
@yasershahian3134
@yasershahian3134 6 ай бұрын
Absolutely love your videos. keep up the good work.
@xSalamz
@xSalamz Жыл бұрын
Thank you so much. I was doing it the old way by using acf_register_block_type() but I will start to do the native approach.
@tevfik7
@tevfik7 Жыл бұрын
This video is golden. Hope you make more videos.
@BrianCoords
@BrianCoords Жыл бұрын
Thanks for watching!
@faisalahammad
@faisalahammad Жыл бұрын
Thanks man 👍
@binaryfire
@binaryfire 3 ай бұрын
Great video mate - you've got a great way of explaining things. A couple of things I'd love to see: 1) How to hardcode ACF fields in the plugin instead of pulling them from the UI (so they're self-contained in the plugin). 2) How can we allow users to set their own palette colors? I'm using ACF blocks as a replacement for flexible content and don't plan on using core blocks any time soon. So would the customizer still be the best way to handle global styles for my use case? Or is there a Gutenberg equivalent that will work just as well with ACF blocks?
@BrianCoords
@BrianCoords 3 ай бұрын
Thanks! These are great ideas for future videos. 1) I'd look into ACF's "Local JSON" feature as the go-to way to store ACF files locally in your theme. www.advancedcustomfields.com/resources/local-json/ Also if you want to prevent your users from seeing the ACF admin screen, you can hide it from them: www.advancedcustomfields.com/resources/how-to-hide-acf-menu-from-clients/ 2) You can override the default colors in the ACF color picker: www.advancedcustomfields.com/resources/javascript-api/#filters-color_picker_args . I could imagine setting that up with a custom ACF options field or else pulling the color values directly from theme.json 🤔
@binaryfire
@binaryfire 3 ай бұрын
​@@BrianCoords Thanks! I've been planning to dig more into local JSON. Regarding 2 - the issue is that this theme + blocks combo will be used by multiple clients in the same industry. Which means the palette needs to be both changeable in the UI, and I want to provide some preset choices too. That's easy to do with something like Kirki but seems a lot more limited with the Gutenberg global styles panel. Unless there's a way of adding custom sections and controls to the GB global styles panel? I'm also not sure how I'd access GB global styles in ACF blocks and if they're just limited to client side things like CSS variables. Whereas getting customizer options anywhere in PHP is easy, and they can include more complex db-stored stuff like layout configs etc.
@taunado
@taunado 3 ай бұрын
Thanks. Is the new Wordpress FSE with blocks simpler to do this? Or is ACF approach still the way, if that even makes sense?
@BrianCoords
@BrianCoords 3 ай бұрын
Carousels are always hard because they're interactive - there may be some block plugins that do it, I could even imagine it coming to core one day, but for now a custom block, like an ACF Block, is the best way,
@taunado
@taunado 3 ай бұрын
@@BrianCoords Sorry I didn't explain what I mean and thanks for the reply. I mean is ASF outdated since Wordpress has introduced FSE and a complete blocks workflow? So we can develop natively without ACF? Basically is ACF becoming redundant?
@BrianCoords
@BrianCoords 3 ай бұрын
@@taunado Oh I see. No I think there's always a great use case for ACF. It gives you a UI for things like custom fields and settings pages. If you aren't interested in learning React, you can build custom blocks with it very easily. There's still a lot of reasons a developer might want to use ACF.
@taunado
@taunado 3 ай бұрын
@@BrianCoords Thanks! I've learned React, just got to learn PHP now.
@mihirvaja3728
@mihirvaja3728 8 ай бұрын
Works great for the build, but I noticed its still loading the scripts and styles on other pages even if the block is not being used, any ideas why? Have followed the tutorial exactly Edit: I should mention this is on a custom theme, not the default WordPress theme. Its the only difference I can think of but surely this isn't why?
@BrianCoords
@BrianCoords 8 ай бұрын
So there's a filter that determines whether your site will load ALL block assets or just the assets on the current page. It's typically true on block themes but not on custom themes. Take a look here and see if this helps: developer.wordpress.org/reference/hooks/should_load_separate_core_block_assets/
@thebuildreview
@thebuildreview Жыл бұрын
Hi Brian, Thanks for the video. Is it possible to display woocommerce products in your carousel? I'm also researching if ACF can handle woocommerce native fields, but can't find any useful articles on the web...
@BrianCoords
@BrianCoords Жыл бұрын
Yeah that's a great question. Since WooCommerce products appear as a custom post type, you should be able to update the post/relationship field to load the "Products" CPT instead of just posts.
@davisvilums
@davisvilums 11 ай бұрын
Hi mate, wonderful videos. How do you "auto generate" the initial plugin files?
@BrianCoords
@BrianCoords 11 ай бұрын
Thanks! If I remember correctly, I used wp-cli to generate the initial plugin for this one. Since I use LocalWP for local development, it has wp-cli built right in! I also probably deleted some of the stuff I didn't need, like the stuff for translation, the grunt file, etc. Here's a link: developer.wordpress.org/cli/commands/scaffold/plugin/
@ureckonsir8024
@ureckonsir8024 Жыл бұрын
Can you make a video on a different type of block with ACF and not so fast in pace do it so beginners can understand
@BrianCoords
@BrianCoords Жыл бұрын
I'm planning a longer series with more step-by-step basics. Let me know if there are any particular parts of ACF Blocks that you'd like me to cover
@bclaw
@bclaw 10 ай бұрын
Thank you for sharing this video. I get "No posts selected" when trying to preview. Do you have an idea where my error is?
@bclaw
@bclaw 10 ай бұрын
I downloaded your repo; everything worked, except for some minor css issues. I'm still wondering why I was getting "No posts selected"?? Maybe a naming issue somewhere...
@BrianCoords
@BrianCoords 10 ай бұрын
Hmm are you trying to get posts or are you trying to get a different post type?
@vincentagasen1368
@vincentagasen1368 6 ай бұрын
I am running on the same issue and I am not getting a different post type. Just the native one. Any idea what could be the reason? (Thanks for this video)@@BrianCoords
@vincentagasen1368
@vincentagasen1368 6 ай бұрын
Found the answer. The get_field() should reference the Field Name you entered when creating the ACF
@BrianCoords
@BrianCoords 6 ай бұрын
In your ACF field or on the front end of your site? @@vincentagasen1368
@ureckonsir8024
@ureckonsir8024 Жыл бұрын
give link of where you are coping the code bro ]
@BrianCoords
@BrianCoords Жыл бұрын
The full code is linked in the description but let me know if I'm missing anything else: github.com/bacoords/example-acf-carousel-block
Using Block Variations with the Block Bindings API
15:42
Brian Coords - WordPress Dev
Рет қаралды 1,7 М.
Easy custom blocks using InnerBlocks in Gutenberg
19:09
Brian Coords - WordPress Dev
Рет қаралды 2,8 М.
Please Help Barry Choose His Real Son
00:23
Garri Creative
Рет қаралды 22 МЛН
WHO CAN RUN FASTER?
00:23
Zhong
Рет қаралды 44 МЛН
WILL IT BURST?
00:31
Natan por Aí
Рет қаралды 9 МЛН
How to Create a Testimonial Block with ACF Blocks
59:24
WP Engine Builders
Рет қаралды 4,8 М.
Adding Custom Fields (attributes) to Core Gutenberg Blocks | WordPress
28:12
Brian Coords - WordPress Dev
Рет қаралды 5 М.
Advanced pattern building in the block editor (in 4 ways)
1:15:11
Overnight Website
Рет қаралды 3,9 М.
Custom Responsive Settings in Gutenberg Blocks
37:54
Brian Coords - WordPress Dev
Рет қаралды 7 М.
Fine tuning your site: Custom blocks with ACF
31:32
WP Engine
Рет қаралды 663
Using Core Data and Sharing Context across WordPress Blocks
35:52
Brian Coords - WordPress Dev
Рет қаралды 1,3 М.
How to create a WordPress Gutenberg Custom Block
42:09
Joshua Herbison
Рет қаралды 48 М.
Dynamic Gutenberg Blocks using the Query Loop & Advanced Custom Fields
12:36
How to Build Dynamic (PHP) Blocks in WordPress
30:57
Brian Coords - WordPress Dev
Рет қаралды 9 М.
Please Help Barry Choose His Real Son
00:23
Garri Creative
Рет қаралды 22 МЛН