Forum

Thread tagged as: Configuration, Addons, Gallery

Problem uploading images in Gallery app

I have upgraded Perch from 2.4.x to 2.8.31 (updated core directory). I have then installed the latest version of Gallery.

I'm getting issues uploading files, this is what happens....

I can create a new Album no problem. I then try to add images to the album. The first strange thing that I notice is that when I try to upload and use the Add Files button and use the filter "All Supported Types" then it doesn't recognise any of my .jpg or any other image types. If change the filter to "All Files" then pick a .jpg file, then start the upload it will start to make progress and then stall at some point then bail out with an http error. This was quite a small file, about 140kb.

My config/filetypes.ini has this entry for images:

[image] image/*

I'll post the perch diagnostics below. Is it likely to be because the server rejects the file type? GD is available on the server although imagemagick isn't. Would appreciate any hints. Thanks.

Perch information

Perch: 2.8.31
Production mode: Production (100)
Installed apps: content (2.8.31), assets (2.8.31), categories (2.8.31), perch_gallery (2.8.6)
DB driver: PDO
DB tables: perch2_categories (0), perch2_category_counts (0), perch2_category_sets (0), perch2_content_index (888), perch2_content_items (1345), perch2_content_regions (176), perch2_gallery_albums (1), perch2_gallery_image_versions (0), perch2_gallery_images (0), perch2_navigation (0), perch2_navigation_pages (0), perch2_page_templates (13), perch2_pages (28), perch2_resource_log (249), perch2_resource_tags (0), perch2_resources (66), perch2_resources_to_tags (0), perch2_settings (18), perch2_user_passwords (0), perch2_user_privileges (30), perch2_user_role_privileges (15), perch2_user_roles (2), perch2_users (3)
Users: 3
App runtimes:

<?php
    include(PERCH_PATH.'/core/apps/content/runtime.php');
    include(PERCH_PATH.'/core/apps/categories/runtime.php');
    include(PERCH_PATH.'/core/apps/perch_gallery/runtime.php');
?>

Editor plug-ins: markitup-old, markitup
H1: 301676f597225dba8b4988045da96e28
L1: ccbbea60ec72315798b74b305fb07bf5
F1: 2edba60ed1f613d6dd804feb202456a2
headerColour: #ffffff
content_singlePageEdit: 1
helpURL:
siteURL: /
hideBranding: 1
content_collapseList: 1
lang: en-gb
update_2.4.9: done
latest_version: 2.8.15
on_sale_version: 2.8.31
headerScheme: light
dashboard: 0
hide_pwd_reset: 0
content_hideNonEditableRegions: 0
content_frontend_edit: 0
logoPath: /admin/resources/amodeo-logo-perch.png
update_2.8.31: done
perch_gallery_update: 2.8.5
PERCH_DEVELOPMENT: 10
PERCH_STAGING: 50
PERCH_PRODUCTION: 100
PERCH_DB_USERNAME: vpeymvoh_admin
PERCH_DB_SERVER: localhost
PERCH_DB_DATABASE: vpeymvoh_cms
PERCH_DB_PREFIX: perch2_
PERCH_TZ: UTC
PERCH_EMAIL_FROM: nigel.harding@talktalk.net
PERCH_EMAIL_FROM_NAME: Nigel Harding
PERCH_LOGINPATH: /admin
PERCH_PATH: /home/vpeymvoh/public_html/admin
PERCH_CORE: /home/vpeymvoh/public_html/admin/core
PERCH_RESFILEPATH: /home/vpeymvoh/public_html/admin/resources
PERCH_RESPATH: /admin/resources
PERCH_HTML5: 1
PERCH_RUNWAY:
PERCH_ERROR_MODE: DIE
PERCH_DATE_LONG: %d %B %Y
PERCH_DATE_SHORT: %d %b %Y
PERCH_TIME_SHORT: %H:%M
PERCH_TIME_LONG: %H:%M:%S
PERCH_RUNWAY_ROUTED:
PERCH_STRONG_PASSWORDS:
PERCH_DEBUG:
PERCH_PREVIEW_ARG: preview
PERCH_TEMPLATE_PATH: /home/vpeymvoh/public_html/admin/templates
PERCH_DEFAULT_DOC: index.php
PERCH_DEFAULT_EXT: .php
PERCH_PRODUCTION_MODE: 100
PERCH_RWD:
PERCH_HTML_ENTITIES:
PERCH_SSL:
PERCH_STRIPSLASHES:
PERCH_PROGRESSIVE_FLUSH: 1
PERCH_PARANOID:
PERCH_FORCE_SECURE_COOKIES:
PERCH_PASSWORD_MIN_LENGTH: 6
PERCH_MAX_FAILED_LOGINS: 10
PERCH_AUTH_LOCKOUT_DURATION: 1 HOUR
PERCH_VERIFY_UPLOADS:
PERCH_AUTH_PLUGIN:
PERCH_DB_CHARSET: utf8
PERCH_DB_PORT:
PERCH_DB_SOCKET:
PERCH_SESSION_TIMEOUT_MINS: 20

Hosting settings

PHP: 5.5.33
Zend: 2.5.0
OS: Linux
SAPI: cgi-fcgi
Safe mode: not detected
MySQL client: mysqlnd 5.0.11-dev - 20120503 - $Id: 15d5c781cfcad91193dceae1d2cdd127674ddb3e $
MySQL server: 5.6.30-log
Free disk space: 302.17 GB
Extensions: Core, date, ereg, libxml, openssl, pcre, sqlite3, zlib, bcmath, calendar, ctype, curl, dom, hash, filter, ftp, gd, gettext, SPL, iconv, session, json, mbstring, mcrypt, standard, mysqlnd, mysqli, pgsql, mysql, Phar, posix, pspell, Reflection, imap, SimpleXML, soap, sockets, exif, tidy, tokenizer, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, cgi-fcgi, PDO, pdo_sqlite, timezonedb, pdo_mysql, ionCube Loader, Zend Guard Loader
GD: Yes
ImageMagick: No
PHP max upload size: 20M
PHP max form post size: 20M
PHP memory limit: 128M
Total max uploadable file size: 20M
Resource folder writeable: Yes
Session timeout: 24 minutes
Native JSON: Yes
Filter functions: Yes
Transliteration functions: No
UNIQUE_ID: V@4qulVcS2gABG8k9dwAAAAT
HTTP_USER_AGENT: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:49.0) Gecko/20100101 Firefox/49.0
SERVER_PORT: 80
HTTP_HOST: www.pangbournehouse.com
REDIRECT_HANDLER: application/x-httpd-php5
DOCUMENT_ROOT: /home/vpeymvoh/public_html
SCRIPT_FILENAME: /home/vpeymvoh/public_html/admin/core/settings/diagnostics/index.php
REQUEST_URI: /admin/core/settings/diagnostics/?extended
SCRIPT_NAME: /admin/core/settings/diagnostics/index.php
HTTP_CONNECTION: keep-alive
REMOTE_PORT: 58915
PATH: /usr/local/bin:/usr/bin:/bin
CONTEXT_PREFIX: /cgi-sys
PWD: /usr/local/cpanel/cgi-sys
SERVER_ADMIN: webmaster@pangbournehouse.com
REQUEST_SCHEME: http
REDIRECT_STATUS: 200
REDIRECT_QUERY_STRING: extended
HTTP_ACCEPT_LANGUAGE: en-US,en;q=0.5
HTTP_REFERER: https://www.pangbournehouse.com/admin/core/settings/diagnostics/
HTTP_ACCEPT: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
REMOTE_ADDR: 88.106.61.244
SERVER_NAME: www.pangbournehouse.com
SERVER_SOFTWARE: Apache
QUERY_STRING: extended
SERVER_ADDR: 85.92.75.104
GATEWAY_INTERFACE: CGI/1.1
HTTP_UPGRADE_INSECURE_REQUESTS: 1
SERVER_PROTOCOL: HTTP/1.1
HTTP_ACCEPT_ENCODING: gzip, deflate
REDIRECT_URL: /admin/core/settings/diagnostics/index.php
REQUEST_METHOD: GET
HTTP_COOKIE: _ga=GA1.2.1047750694.1474466424; cmsa=1; PHPSESSID=73ea9fefdb5504b9b67e44d24e4c17e6
CONTEXT_DOCUMENT_ROOT: /usr/local/cpanel/cgi-sys/
ORIG_SCRIPT_FILENAME: /usr/local/cpanel/cgi-sys/php5
ORIG_PATH_INFO: /admin/core/settings/diagnostics/index.php
ORIG_PATH_TRANSLATED: /home/vpeymvoh/public_html/admin/core/settings/diagnostics/index.php
ORIG_SCRIPT_NAME: /cgi-sys/php5
PHP_SELF: /admin/core/settings/diagnostics/index.php
REQUEST_TIME_FLOAT: 1475226298.45
REQUEST_TIME: 1475226298
argc: 1
Nigel Harding

Nigel Harding 0 points

  • 5 years ago
Rachel Andrew

Rachel Andrew 394 points
Perch Support

What is the actual error message you are getting? Look in your PHP error log.

OK thanks, so I'm seeing this:

[30-Sep-2016 09:46:21 UTC] PHP Warning: include(): Failed opening '/home/vpeymvoh/public_html/admin/core/apps/perch_gallery/runtime.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/vpeymvoh/public_html/admin/config/apps.php on line 4 Which led me to resolve this when I realised that the apps.php line for perch_gallery was incorrect (was still pointing to a directory within 'core').

So I can now upload images successfully, I still don't see any .jpg images though when I filter for "All Supported Types" (.png and .jpeg are picked up). Is there a way to include .jpg as a supported image type?

Thanks

Drew McLellan

Drew McLellan 2638 points
Perch Support

Where does "All Supported Types" appear? I don't really follow.

OK, so in the Gallery App... go to to an album then click the Add Image button. You get an option to either drag files into the Filename area or you can hit a file chooser button "Add Files" to pick out your files from the file system on your device. If you hit the "Add files" button then by default the "All supported types" option shows .png, .jpeg, .gif and .zip but it doesn't show .jpg files.

See all supported types

Drew McLellan

Drew McLellan 2638 points
Perch Support

I'm not quite sure what would dictate which file types your computer shows you. What OS is that? Is it Windows of some sort?

What happens if you drag a .jpg file in? They should be fully supported.

I agree that it's an OS/machine setup thing, happens on one of my Windows 10 machines, the other is fine. You're right that .jpg is fully supported despite my filter glitch.