• Hello All,

    I just wanted to share a fix that I have because I ran into an issue with the portfolio images. They don’t seem to update into order while I’m arranging them on the edit portfolio item page. To make the sorting works on the portfolio items, open this file (/wp-content/plugins/otw-portfolio-light/js/custom-js.js). Next, find line 71 and you’ll see this lines of code:

    jQuery('.custom_repeatable').sortable({
    		opacity: 0.6,
    		revert: true,
    		cursor: 'move',
    		handle: '.sort'
    	});

    Change that section into:

    jQuery('.custom_repeatable').sortable({
    		opacity: 0.6,
    		revert: true,
    		cursor: 'move',
    		handle: '.sort',
    		update: function( event, ui ){
    			var inc = 0;
    			jQuery('.custom_repeatable li').each(function(){
    				jQuery('input', this).attr('name', 'custom_otw-portfolio-repeatable-image['+inc+']');
    				jQuery('img', this).attr('name', 'custom_otw-portfolio-repeatable-image['+inc+']');
    				inc++;
    			});
    		}
    	});

    That’ll fix the image ordering under the portfolio items.

    https://www.ads-software.com/plugins/otw-portfolio-light/

  • The topic ‘Portfolio Images Bug Fix’ is closed to new replies.