Support » Plugin: Simple Page Ordering » error loading spinner.gif with custom folder structure

  • Hi there,

    have been loving your plugin ever since it’s release! I just noticed a small (non-breaking) bug: if you have a custom folder structure on your wordpress install, where your wp-content folder is outside the core folder, the “spinner.gif” won’t be loaded, since the location of the plugin’s css file is somewhere else relative to the wp-content folder.

    The only fix that comes to my mind would be to use php to detetct the location of /wp-admin/images/ dynamically. As a temporary fix I put this into our functions.php file:

    add_action( 'admin_footer', 'b09_spo_css_override' );
    
    function b09_spo_css_override() {
    	$images_url = site_url() . '/wp-admin/images/';
    	?>
    	<style>
    		.spo-updating-row .check-column {
    			background-image: url('<?php echo $images_url ?>spinner.gif') !important;
    		}
    		@media print,
    		(-o-min-device-pixel-ratio: 5/4),
    		(-webkit-min-device-pixel-ratio: 1.25),
    		(min-resolution: 120dpi) {
    			.spo-updating-row .check-column {
    				background-image: url('<?php echo $images_url ?>spinner-2x.gif') !important;
    				background-size: 20px 20px;
    			}
    		}
    	</style>
    	<?php
    }

    https://wordpress.org/plugins/simple-page-ordering/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Of course I meant that it’s somewhere else relative to the wp-admin folder…

    Plugin Author Jake Goldman

    (@jakemgold)

    10up Engineer

    Yea, I know… just seemed cheap to package my own spinner or spit out more CSS in the page. I’ll fix it.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘error loading spinner.gif with custom folder structure’ is closed to new replies.