Fatal error: Uncaught ImageWorkshopBaseException: [2]: You must give a php image var to initialize a

Discussion in 'Subrion CMS Packages Discussions' started by wazza, Aug 26, 2014.

  1. wazza

    wazza Member

    Hi Guys....

    Just added an image field to my package and receive the following error

    Fatal error: Uncaught ImageWorkshopBaseException: [2]: You must give a php image var to initialize a layer. thrown in /usr/home/wmhc/domains/empireofnames.com.au/public_html/includes/phpimageworkshop/Core/ImageWorkshopLayer.php on line 131

    I googled it but could not find the answer to solve....

    Any ideas?
  2. Vasily_B.

    Vasily_B. Project Manager

    Hi Quentin,

    Do you use the default processing for the image field you added using parsePost method? Is there any way to check your files, so we could reproduce and investigate the issue?

  3. wazza

    wazza Member

    Hi Vasily,

    Yes using default. seems im only getting this error on 3.1.8 version.

    Im just checking over the file now...

    if i disable line 131 in WorkshopLayer.php the image will upload but not display...

    Well that file hasn`t changed in any way.... still plodding along
    Last edited: Aug 27, 2014
  4. wazza

    wazza Member

    Hi Vasily,

    Seems there may have been some changes since i last worked on the package. Was using 3.1.2.

    I am going through the subrion versions to see where my package breaks.

    Ill let you know results....

    Also is the packagestructure changed in any way?
  5. wazza

    wazza Member

    hmmm....if i upload .png files i have no error...just seems .jpg files trhow the error....havnt tried gifs yet
  6. wazza

    wazza Member

    Hi Again Vasily,

    I have never noticed this error before....
    Seems to only happen with .jpg images.

    GIF and PNG Files have no problem at all.

    It wasn`t anything to do with the package as same problem with earlier versions of Subrion....

    Also tested some of your packages and getting same error with them....

    Only JPG files
  7. Vasily_B.

    Vasily_B. Project Manager

    One possible resolution then. Make sure your GD library is compiled with jpeg files support.

  8. wazza

    wazza Member

    ok thanks Vasily....
  9. Vasily_B.

    Vasily_B. Project Manager

    Resolved now?
  10. wazza

    wazza Member

    Hi Vasily,

    I checked GD and jpeg support is enabled.

    GD Support enabled
    GD Version bundled (2.1.0 compatible)
    FreeType Support enabled
    FreeType Linkage with freetype
    FreeType Version 2.5.3
    GIF Read Support enabled
    GIF Create Support enabled
    JPEG Support enabled
    libJPEG Version 6b
    PNG Support enabled
    libPNG Version 1.2.51
    WBMP Support enabled
    XPM Support enabled
    libXpm Version 30411
    XBM Support enabled

    DirectiveLocal ValueMaster Value

Share This Page