Auto slideshow for my post slider in php

Hi I have this php code for creating a slider with my posts, I want it to auto slideshow for atleast 2 secs intervals or so. below is the code I manage to have but it is not automatically moving to next slide.

<?php         $  slider_query = array(         'post_type' => 'slider',         'posts_per_page' => -1);          $  slider_posts = new WP_Query( $  slider_query );         if ($  slider_posts->have_posts()):         while ( $  slider_posts->have_posts() ) : $  slider_posts->the_post(); ?> 

//my html code for slider images and text here //

<?php         endwhile;         endif;          wp_reset_postdata(); ?> 

Hope someone can help me.

Auto-move (scroll) product thumbnails on product page image slider

I’ve got a problem with the product image slider on the product page. I used flex to display thumbnails in one row. There are 5 thumbnails in a row. Images move correctly using direction arrows. How to set up auto-scroll to the next thumbnail in a row? Now it moves (main image changing) but 5 thumbnails in a row are still static. I set overflow-x to auto, so you can see there are the next images in a row.

Basic code:

div.product div.images .flex-control-thumbs {     display:flex;     flex-wrap: nowrap;     overflow-x: auto;     margin: 0 50px; }  div.product div.images .flex-control-thumbs li {     display: flex;     overflow-x: visible;     flex: 1 0 20%; } 

My test site – you can see how it works: https://fewbirds.tastewp.com/produkt/test-product/

Slider with ticks

I am not happy with the "Labeled" appearance of the slider in Animate or Manipulate. Instead, I wish ticks with multiple of pi under the slider.

Animate[Plot[Sin[x + phi], {x, 0, 2 Pi}], {phi, 0, 2 Pi,  Appearance -> "Labeled"}] 

What would be the best way to do it? Ideally it should look like this:

Text

I do not think the solution given in https://mathematica.stackexchange.com/a/8264 is practical or even elegant. Following this logic of adding an additional axis I cannot make it look the way I want and, in general, it seems highly "artificial".

Revolution Slider – Hide a layer forever at the end of first loop

Is it possible to hide a layer once and forever in Revolution Slider? I’d like to show a logo only at the beginning of the slider (when you first load that page) and then hide it once and forever, keeping the rest of the slider go in loop as usual… I can’t find a “Play Once” option for layer animations anywhere…

How to include a slider only in the home?

I tried to include this one slider with a plugin called metaslider in the singular file.php, I am new to wordpress, they could guide me where the fault is because by placing the plugin if it shows it but it is published on all pages and I just want it in the home What would be the correct sentence and in what file? If you could help me I thank you very much.

How to create a product details slider on post?

I am using WordPress. I have to display the product details slider on each post with different details.

For example, I have apple post and I have to add a product slider so my slider details are

Product_title   price  desc  link        image iPhone x       $  650   xyz   textt.com   1.jpg iPhone 7       $  550   abc   textt.com   2.jpg iPhone 6s      $  450   pqr   textt.com   3.jpg 

These details will not display on another post.

What I am thinking there are two options

1) Create custom post type and add information then create a shortcode and add shortcode to the post.

2) Create the Gutenberg block and add details.

I need to know which is the best and easy? Till now I am not using any plugin. I have created a 30 post.

I am trying to add below fields and once the user clicks on add more then the same filed will display again and can add next details.

enter image description here

Below is the code for the above fields. I refer this link https://jeremyhixon.com/tool/wordpress-meta-box-generator/ to generate the fields.

Note: add more button is not working.

function product_details_get_meta( $  value ) {     global $  post;      $  field = get_post_meta( $  post->ID, $  value, true );     if ( ! empty( $  field ) ) {         return is_array( $  field ) ? stripslashes_deep( $  field ) : stripslashes( wp_kses_decode_entities( $  field ) );     } else {         return false;     } }  function product_details_add_meta_box() {     add_meta_box(         'product_details-product-details',         __( 'Product details', 'product_details' ),         'product_details_html',         'productslider',         'normal',         'default'     ); } add_action( 'add_meta_boxes', 'product_details_add_meta_box' );  function product_details_html( $  post) {     wp_nonce_field( '_product_details_nonce', 'product_details_nonce' ); ?>      <p>         <label for="product_details_product_title"><?php _e( 'Product title', 'product_details' ); ?></label><br>         <input type="text" name="product_details_product_title" id="product_details_product_title" value="<?php echo product_details_get_meta( 'product_details_product_title' ); ?>">     </p>    <p>         <label for="product_details_product_price"><?php _e( 'Product price', 'product_details' ); ?></label><br>         <input type="text" name="product_details_product_price" id="product_details_product_price" value="<?php echo product_details_get_meta( 'product_details_product_price' ); ?>">     </p>    <p>         <label for="product_details_product_description"><?php _e( 'Product description', 'product_details' ); ?></label><br>         <textarea name="product_details_product_description" id="product_details_product_description" ><?php echo product_details_get_meta( 'product_details_product_description' ); ?></textarea>      </p>    <p>         <label for="product_details_product_link"><?php _e( 'Product link', 'product_details' ); ?></label><br>         <input type="text" name="product_details_product_link" id="product_details_product_link" value="<?php echo product_details_get_meta( 'product_details_product_link' ); ?>">     </p>     <p>         <label for="product_details_product_img"><?php _e( 'Product image', 'product_details' ); ?></label><br>         <input type="file" name="product_details_product_img" id="product_details_product_img" value="<?php echo product_details_get_meta( 'product_details_product_img' ); ?>">     </p>      <p>         <input type="submit" name="product_details_submit" id="product_details_submit" value="Add More">     </p>  <?php }  function product_details_save( $  post_id ) {     if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;     if ( ! isset( $  _POST['product_details_nonce'] ) || ! wp_verify_nonce( $  _POST['product_details_nonce'], '_product_details_nonce' ) ) return;     if ( ! current_user_can( 'edit_post', $  post_id ) ) return;      if ( isset( $  _POST['product_details_product_title'] ) )         update_post_meta( $  post_id, 'product_details_product_title', esc_attr( $  _POST['product_details_product_title'] ) );     if ( isset( $  _POST['product_details_product_price'] ) )         update_post_meta( $  post_id, 'product_details_product_price', esc_attr( $  _POST['product_details_product_price'] ) );     if ( isset( $  _POST['product_details_product_description'] ) )         update_post_meta( $  post_id, 'product_details_product_description', esc_attr( $  _POST['product_details_product_description'] ) );     if ( isset( $  _POST['product_details_product_link'] ) )         update_post_meta( $  post_id, 'product_details_product_link', esc_attr( $  _POST['product_details_product_link'] ) ); } add_action( 'save_post', 'product_details_save' ); 

Best way to determine today and tomorrow in a slider

I want people to be able to tell how much they have worked during their shift and this seems like a perfect solution. There is just one problem. They can also work till the next day (ie: from the 5th 20:00 to 6th 04:00). The labels within the slider (9:00 and 18:00) are not a must and I don’t think 00:00 till 48:00 would look visually appealing.

What would be the best way to do this keeping the obviousness for the user? Should I even use a slider for this?

enter image description here

¿Como desaparecer slider 3 segundos despues de dejar de usarse?

Tengo un Slider dentro de un AnimatedOpacity

AnimatedOpacity(   opacity: _showSlider ? 1.0 :0.0,   duration: Duration(milliseconds: 500),   child: Container(     color: Colors.white,     child: Slider(       activeColor: Colors.red,       label: 'Tamaño $  _valorSlider',       divisions: 5,       value: _valorSlider,       min: 10.0,       max: 28.0,       onChanged: (valor) {         print(valor);         Timer(Duration(seconds: 3), (){           setState(() {             print('OnChange');             _secons +=3;             // _showSlider = false;           });           });         setState(() {           _valorSlider = valor;         });       },     ),   ), ), 

El cual se muestra al presionar un IconButton el cual ejecuta lo siguiente

onPressed: (){   Timer(Duration(seconds: _secons), () {     setState(() {       print('optionSBar');       _showSlider = false;      });   });   setState(() {     _showSlider = true;   }); }, 

Desaparece 10s después de que no se utiliza ya que _secons=10, intente lo siguiente para que si se esta usando siga visible y desaparezca 3s después de que se utilizo por ultima ves

onChanged: (valor) {   print(valor);   Timer(Duration(seconds: 3), (){     setState(() {       print('OnChange');       _secons +=3;       // _showSlider = false;     });     });   setState(() {     _valorSlider = valor;   }); }, 

Claramente lo anterior no funciona ya que su tiempo se incrementa por cada cambio que sucede en el Slider