Archived topic
Quick way to make a slider
10 replies · Started by iamarghya on July 4, 2022
See after 2nd post there is a 'mint premium' post slider can u just tell me what is the best way to do that I mean the slider with the post?
Hi Iamarghya,
You’ll need custom code or a third party plugin for a query that’s formatted as a Carousel.
I think a plugin like this might be something you’re looking for: https://wordpress.org/plugins/wp-carousel-free/
Hope this clarifies!
What will be more light custom code or plugins? I mean for the website. I can write code but can I add it with the snippet plugin or do I need to add it to the main theme editor?
Custom code would be lighter.
Well, you can add the script through a Hook Element. Then, PHP for the query can be added there as well. If you’re creating a shortcode, it would be better to add the PHP through Code Snippets or functions.php.
If you have GenerateBlocks already, you can just use the Query Loop Block, then just add a script and some CSS to turn it into a Carousel.
Hope this clarifies!
I am using generateblocks...Going for the pro in the future at the moment can't afford it...
So I think I don't need to write the PHP only the script to make it carousel right?
But whatever classes I will use in the script need to add to the container right?
Can you link me to good resources of scripts like this?
Yes, it would be good to place the Query Loop in a container.
Add a couple of buttons in the Container along with the Query Loop, then set them to position: absolute and position them to your preference.
Then, add a script. There might be a carousel that has a good script here: https://codepen.io/tag/carousel?
Hope this helps!
oh, button for the arrow?
Yes, for the arrows.
Got it I will update you when I will have a problem.
Alright! Hope it goes well!