Question on the structure of the slider in WP?

Hi all. Make up maketick - learning. I have on the main page slider. Nothing special with no mind, but the layout...

<ul class="slides">
 <li class="slide1">
 <div class="flex_caption1">
 <p class="title1 captionDelay2 FromTop">Creative</p>
 <p class="title2 captionDelay4 FromTop">White</p>
 <p class="title3 captionDelay6 FromTop">Templates</p>
 <p class="title4 captionDelay7 FromBottom">The template is suitable for any company and the direction that appreciates style, purity and quality of the web site.</p>
</div>
 <a class="slide_btn FromRight" href="javascript:void(0);">Read More</a>
</li>
 <li class="slide2">
 <div class="flex_caption1">
 <p class="title1 captionDelay6 FromLeft">Responsive</p>
 <p class="title2 captionDelay4 FromLeft">Design</p>
 <p class="title3 captionDelay2 FromLeft">Theme</p>
 <p class="title4 captionDelay7 FromLeft">The template is suitable for any company and the direction that appreciates style, purity and quality of the web site.</p>
</div>
 <a class="slide_btn FromRight" href="javascript:void(0);">Read More</a>
</li>
 <li class="slide3">
 <div class="flex_caption1">
 <p class="title1 captionDelay1 FromBottom">Amazing</p>
 <p class="title2 captionDelay2 FromBottom">Video</p>
 <p class="title3 captionDelay3 FromBottom">Background</p>
 <p class="title4 captionDelay5 FromBottom">The template is suitable for any company and the direction that appreciates style, purity and quality of the web site.</p>
</div>
 <a class="slide_btn FromRight" href="javascript:void(0);">Read More</a>
</li>
 </ul>


To begin, I will make it with custom record types since there is a button READ ME is logical that she should lead on the cuckoo then a page or post.

The problem here is this:
<p class="title1 captionDelay2 FromTop">Creative</p>
 <p class="title2 captionDelay4 FromTop">White</p>
 <p class="title3 captionDelay6 FromTop">Templates</p>


In the slider it is a single line: Amazing Background Video

I'll use the plugin ' options tree. I will create only one field in which the text will fit on one line Amazing Video Background, and then use the explode will split into an array at spaces and determine how the elements of the array echo $item[0] echo $item[1] echo $item[2]

I correctly think?
June 14th 19 at 18:02
1 answer
June 14th 19 at 18:04
Solution
Too tricky and options of the Wordpress is not in the business. If you need a second slider to do it again in the option you will shove? But if the slider on another page? Right to do all this using custom fields. The ACF plugin or library Carbon Fields. Create a comprehensive set of fields for the page Slider and in it describe what you need. The contents of Kupchina and write in HTML. And remember - you do on Wordpress to make it easier for you, and make it easier for the customer to change something, not messing around in the code and not understanding with your inventions.
So I need for each word to make a single field? Yes, no question if it was correct. I wrote above that I'm using the options tree. There are metaboxes. Thanks for the reply - bruce_Schroeder commented on June 14th 19 at 18:07
why create a field of type https://www.advancedcustomfields.com/resources/wys... and cast the whole markup in your caption. - Baylee_Kulas commented on June 14th 19 at 18:10
OK thank you. Actually, I liked the Carbon Fields. Now he is studying. I understand it's free. ACF have not yet watched, but it is also partly free. I would like a plugin make sure you have all the necessary functions. Suddenly something you need and pay for it.

The truth is I have little experience. For this it is difficult to speculate about all that. - bruce_Schroeder commented on June 14th 19 at 18:13
Carbon is very steep and it is placed as a dependency via Composer directly in the theme folder. Can be supplied as a plugin, but the Wordpress directory like the old version. Get familiar with Composer and put in the subject, sooner or later, still need to add some library in your theme. - Baylee_Kulas commented on June 14th 19 at 18:16
with Composer I'm almost done, but I have failed to make the autoloading of classes. Along the way, I just rivet a blog with php + OOP. all exactly understand. Thanks for the tips - bruce_Schroeder commented on June 14th 19 at 18:19
if you enter in the subject and want to work with WP on a professional level, write me at vs@zorca.org will figure something out. Good developers we need. - Baylee_Kulas commented on June 14th 19 at 18:22

Find more questions by tags PHPWordPress