WordPress.org

Ready to get started?Download WordPress

Forums

Meta Slider
[resolved] adding images to slider exception (8 posts)

  1. MadBong
    Member
    Posted 1 year ago #

    hey matcha labs,

    i would like to test this plugin. unfortunately it does not work. i use firefox 19 and firebug shows me the following js-exception after i close the "select slide" dialog by pressing the "add to slider" button:

    <br />
    TypeError: attachment.sizes is undefined<br />
    http://localhost/dformhorak_dev/wp-content/plugins/ml-slider/assets/ml-slider.js?ver=3.5.1<br />
    Line 94<br />

    same result with different images and different sizes (10kB png, 1.8 MB bmp).
    same result when selecting from library and uploading freshly.

    and i tried in chromium, which gives me this exception:

    <br />
    Uncaught TypeError: Cannot read property 'thumbnail' of undefined ml-slider.js:94<br />
    (anonymous function) ml-slider.js:94<br />
    T.map.T.collect load-scripts.php:10<br />
    r.(anonymous function) load-scripts.php:28<br />
    (anonymous function) ml-slider.js:86<br />
    g.Events.trigger load-scripts.php:12<br />
    f.extend._onModelEvent load-scripts.php:27<br />
    g.Events.trigger load-scripts.php:12<br />
    f.view.Toolbar.Select.f.view.Toolbar.extend.clickSelect load-scripts.php:65<br />
    f.view.Button.f.View.extend.click load-scripts.php:65<br />
    v.event.dispatch load-scripts.php:2<br />
    o.handle.u load-scripts.php:2<br />

    i guess something is wrong with my images?

    regards

    http://wordpress.org/extend/plugins/ml-slider/

  2. Matcha Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Hi MadBong,

    Thanks for the report and the detailed description - much appreciated.

    Looking into this now and I'll get back to you.

    Regards,
    Tom.

  3. Matcha Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Hi MadBong,

    The quick answer is: BMP files are not accepted - WordPress is unable to make thumbnails from or resize BMP files (it uses the GD image library and unfortunately that does not have the ability to resize BMP files). In this case I'd suggest saving the BMP file as a PNG and using that instead.

    Additionally, if you attempt to use an image that is smaller than your WordPress Thumbnail Size configuration, ML Slider will fail to add it. ML Slider looks for a thumbnail image to display on the admin page, but WordPress won't have made one available. In this case I'd suggest uploading a larger version of the image if you have one available.

    I'll add some error checking in for the BMP files, and have a think about what to do with slides that are smaller than the default thumbnail size. It seems unlikely someone would want to use a really, really small image for a slide, but we will try and make it possible even so.

    Thanks again for the detailed report, the updates will be in the next version (1.2.1).

    Regards,
    Tom.

  4. Matcha Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Quick update, a fix has been committed to trunk. Will be in the next release.

  5. MadBong
    Member
    Posted 1 year ago #

    hi tom,

    i am glad i am able to help.

    so i tried again, according to your guidelines with an 500kB and a 1.6 MB jpeg. also errors:


    TypeError: attachment.sizes.thumbnail is undefined
    http://localhost/dformhorak_dev/wp-content/plugins/ml-slider/assets/ml-slider.js?ver=3.5.1
    Line 94

    then i tried the plugin on another server/wp-installation. and there it works just fine. except for the bmp-behavior of course.

    so, small pngs seem not to be a problem. it is a problem with my localhost installation.

    i have to look into this further. if you have any suggestions, where to look - any help is welcome.

    thanks,
    arthur

  6. Matcha Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Arthur,

    Try uploading a large image (locally), and checking the uploads folder:

    If you upload car.jpg, you should also see car-150x150.jpg, car-300x168.jpg and so on in your uploads folder. If you're only seeing car.jpg in there then you need to track down why WordPress isn't creating the thumbnails for you. I would check your php installation has the GD extension installed first of all, then folder permissions.

    The 'smaller than thumbnail size' image problem is a genuine bug and has been fixed ready for the next release.

    Regards,
    Tom.

  7. MadBong
    Member
    Posted 1 year ago #

    hey tom,

    thanks a lot for the help. with php-gd installed, it now works on my local machine too.

    i was wondering if there is an official list of required php-extensions to be found on wordpress.org. but there is none.

    so for anyonhe who is interested, a quick search revealed these very helpful postings:

    http://wordpress.stackexchange.com/questions/42098/what-are-php-extensions-and-libraries-wp-needs-and-or-uses

    regards,
    arthur

  8. Matcha Labs
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Arthur,

    The missing GD extension has caught us out a few times also!

    Glad you have it sorted.

    Regards,
    Tom.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags