I can’t see your site. However, based on the code you added, you could try something like this:
css:
.owl-controls .owl-pagination .owl-page span{
height: 50px;
width:50px;
background-size: cover;
background-position: center;}
JS:
$('.owl-controls .owl-pagination .owl-page').each(function(index, value){
$(this).children('span').css('background-image', "url('"+$('.owl-carousel .owl-wrapper .item').eq(index).find('img').attr('src')+"')");
});
Here is a working example:
http://codepen.io/BertoMejia/pen/LRLRBg
Related Posts:
- How to use SRCSET with get_the_post_thumbnail()?
- How to display recent posts on home page with custom HTML
- Use wp_get_recent_posts with search term
- Load a page into a div with Ajax
- Converting HTML Template to WordPress Theme
- Recent Posts slider, using WP_Query(), loads duplicate sliders
- Recent Posts Not Showing Only On A Specific Category Page [closed]
- Syntax error when I try to insert my loop into an unordered list? [closed]
- How to retrieve the data from the sever and displaying it in a page?
- How do I get the content excerpt of the recent post?
- Getting posts to exclude from array
- Get all posts as an array ID => Name
- Custom post type permalinks do not appear using the link functions
- Using php inside javascript [closed]
- Toolbar Hidden in a Virtual Page
- Search.php gets metadata from first post
- Search AJAX Filters – Multiple Query Loops Into One Loop (Optimization)
- Displaying images outside the content
- PHP inside echo HTML
- Trying to get pagination working on WP_Query() post grid
- Collapsible menu on post sidebar only expands and does not collapse
- Add Text Area To Child Theme’s Home Page
- WooCommerce – Print Processing orders [closed]
- Variable ++ in query loop
- Font Awesome Icons as squares [closed]
- How to determine if WP_DEBUG is enabled? [duplicate]
- Get author full name
- Is it possible to get a theme customizer setting from wp.customize using jquery?
- One button to change all settings in theme customizer?
- How to use copy() function and paste file in /wp-content/themes directory
- Multiple pages on one with different HTML
- Show different Customizer Settings on Page-Tamplates
- Add custom HTML to posts page
- I think emoji are killing my WordPress site… How can I debug?
- Custom Logo URL | Help me print the URL of the custom logo I inserted into my theme
- Sorting Posts | Alphabetical Order
- How to only show page id as body class?
- Why is this Ajax not working?
- Shortcode content output but not in correct place
- Displaying theme options in css
- How to load a template-part based on a url wildcard?
- Custom theme: Alternatives to long list of ‘include’ in functions.php
- How to use an associative array in post__in with WP_Query?
- How to show part of the_content?
- Exclude posts based on meta value
- Remove echo from shortcode
- Show latest posts in a plain HTML website custom widget [closed]
- unable to use ‘new WP_Query’ in AJAX call
- How to remove coupon dropdown feature
- Why in my theme I can’t see all the statics content under the posts?
- Theme not calling Jquery properly
- Add html link in functions.php files of the theme
- Double Curly Brackets in Php
- PHP contact form not redirecting [closed]
- How to Schedule Cronjobs for start of every month and year
- Get post categories
- Handling PHP/HTML inside the output of a shortcode function
- How to hide posts of a specific custom category in WordPress?
- Output only links using wp_nav_menu()
- Need help removing […] after excerpt
- How to add aria role and schema markup to custom walker container
- How to correctly load a different version of main menu based on the user language in WordPress? Is it a good solution?
- displaying a fall back query if there’s nothing in the post-type category
- WordPressUser Submission Form
- Shortcode displaying at the top of the page [duplicate]
- WordPress redirects page query parameter in URL
- Getting text from custom field from customizer
- WordPress navigation wont appear with wp_head
- How do you get the current post taxonomy so I can get the current post taxonomy? into a variable to THEN loop through all post with that taxonomy.,
- wp_query with multiple arguments with AND
- Background image no longer fits to screen now that project is in php files
- Nested Queries of decreasing specificity
- how to replace h1 entry title with h2 in category pages only
- Shortcode in Shortcode/HTML Graphics and Pictures
- in_array not working on dev server but works on localhost
- WP query posts BUT show the most recent and one per author
- Display post date also if the date it’s the same for each post
- Submit remote form to wordpress REST API and save data to custom post type
- alternate left – right content inside the loop
- register dependency css and js inside a plugin class
- Search for single post by 2 tags
- HTML Formatting “single_term_title()”?
- Woocommerce Related Product by 2 taxonomy
- Creating Log-In Page for backend server
- Woocommerce variable products are being added to the card on the homepage (ajax)
- user update profile for custom code
- Vertical Menu for one page only
- Bootstrap Carousel Indicators Won’t Cycle On Custom WordPress Theme
- How to get php file based on URL in WordPress
- Not able to get the exact URL of the file on server located in active wordpress theme
- Extend the WP_Customize_Image_Control class to change its non-frame $button_labels
- Query seems to be duplicated
- how to manipulate HTML parameters using PHP conditions
- need help to arabic text in wordpress
- Display wordpress post to static website in the footer
- Keeping the previous get value and add another value when submitted
- How to edit homepage in WordPress?
- Using is home to get content [closed]
- How I can give a php page a style from my theme
- WordPress PHP8 Critical Error in class-wp-widget.php