Forum

Thread tagged as: Error, Configuration, Runway

Buckets not working in Runway?

I am trying to get buckets working in Runway 2.7.3

I am not sure if it's my configuration or Runway. I get this error in the CMS

Work Item Image

Fatal error: Call to a member function initialise() on a non-object in /var/sites/#/#/public_html/2014/site_admin/core/lib/PerchFieldTypes.class.php on line 685

buckets,php looks like this:

<?php 
    return array(
        'imghome' => array(
            'web_path'  => '/assets/img/home',
            'file_path' => '/var/sites/#/#/public_html/2014/assets/img/home'
        )
    );
?>

I have also tried....

<?php 
    return array(
        'imghome' => array(
            'web_path'  => '/2014/assets/img/home',
            'file_path' => '/var/sites/#/#/public_html/2014/assets/img/home'
        )
    );
?>

config.php has this:

    define('PERCH_LOGINPATH', '/2014/site_admin');
    define('PERCH_PATH', str_replace(DIRECTORY_SEPARATOR.'config', '', dirname(__FILE__)));
    define('PERCH_CORE', PERCH_PATH.DIRECTORY_SEPARATOR.'core');
    define('PERCH_RESFILEPATH', PERCH_PATH . DIRECTORY_SEPARATOR . 'resources');
    define('PERCH_RESPATH', PERCH_LOGINPATH . '/resources'); 
    define('PERCH_HTML5', true); 
    define('SITE_PATH', '/var/sites/#/#/public_html/2014');

the template has this:

<img src="<perch:content type="image" id="image" label="Work Item Image" bucket="imghome" />" alt="<perch:content type="text" id="alt" label="Image Description" required="true"  title="true" />" />

If I remove [bucket="imghome"] from the template, everything works fine albeit the image gets uploaded to the default 'resources' folder instead.

Help!

Neil Duddridge

Neil Duddridge 1 points

  • 7 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Does anything change if you add

'type' => 'file',

to you bucket definition?

Hi Drew,

I still get the same Fatal Error

Drew McLellan

Drew McLellan 2638 points
Perch Support

Can you show me your diagnostics report?

Here you go, I've hashed some of the sensitive data.

Diagnostics report
PERCH INFORMATION

Perch: 2.7.3
Production mode: Production (100)
Installed apps: content (2.7.3), assets (2.7.3), categories (2.7.3), perch_blog (4.5.2), perch_twitter (3.3.1)
DB driver: PDO
DB tables: perch2_backup_plans, perch2_backup_resources, perch2_backup_runs, perch2_blog_authors, perch2_blog_categories, perch2_blog_comments, perch2_blog_posts, perch2_blog_posts_to_categories, perch2_blog_posts_to_tags, perch2_blog_sections, perch2_blog_tags, perch2_categories, perch2_category_counts, perch2_category_sets, perch2_collection_index, perch2_collection_items, perch2_collection_revisions, perch2_collections, perch2_content_index, perch2_content_items, perch2_content_regions, perch2_navigation, perch2_navigation_pages, perch2_page_routes, perch2_page_templates, perch2_pages, perch2_resource_log, perch2_resource_tags, perch2_resources, perch2_resources_to_tags, perch2_settings, perch2_twitter_settings, perch2_twitter_tweets, perch2_user_privileges, perch2_user_role_privileges, perch2_user_roles, perch2_users
Users: 1
App runtimes:
<?php

    $apps_list = array(
        'content',
        'categories',
        'perch_blog',
        'perch_twitter',
    );
?>
Scheduled tasks for perch_blog: delete_spam_comments (1440 mins)
Scheduled tasks for perch_twitter: update_tweets (10 mins)
Editor plug-ins: ckeditor, redactor, markitup
H1: 3ea065ef87143f9a8b84a81954539669
L1: 95ef83c36f3f16c3f0fe678b5c0b7d01
headerColour: rgb(54,54,54)
content_singlePageEdit: 1
helpURL:
siteURL: /
hideBranding: 1
content_collapseList: 1
lang: en-gb
update_2.4.9: done
latest_version: 2.5.3
on_sale_version: 2.7.3
headerScheme: dark
dashboard: 1
hide_pwd_reset: 0
content_hideNonEditableRegions: 0
content_frontend_edit: 0
logoPath: /2014/site_admin/resources/logofeb2013-cms.png
perch_twitter_update: 3.2
update_2.6: done
perch_blog_post_url: /blog/post.php?s={postSlug}
perch_blog_update: 5.0
update_2.6.6: done
update_2.7.2: done
update_2.7.3: done
PERCH_DEVELOPMENT: 10
PERCH_STAGING: 50
PERCH_PRODUCTION: 100
PERCH_DB_USERNAME: #
PERCH_DB_SERVER: #
PERCH_DB_DATABASE: #
PERCH_DB_PREFIX: perch2_
PERCH_TZ: Europe/London
PERCH_EMAIL_FROM: #
PERCH_EMAIL_FROM_NAME: #
PERCH_LOGINPATH: /2014/site_admin
PERCH_PATH: /var/sites/#/#/public_html/2014/site_admin
PERCH_CORE: /var/sites/#/#/public_html/2014/site_admin/core
PERCH_RESFILEPATH: /var/sites/#/#/public_html/2014/site_admin/resources
PERCH_RESPATH: /2014/site_admin/resources
PERCH_HTML5: 1
PERCH_RUNWAY: 1
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_DEBUG:
PERCH_PREVIEW_ARG: preview
PERCH_TEMPLATE_PATH: /var/sites/#/#/public_html/2014/site_admin/templates
PERCH_DEFAULT_DOC: index.php
PERCH_DEFAULT_EXT: .php
PERCH_PRODUCTION_MODE: 100
PERCH_RWD:
PERCH_HTML_ENTITIES:
PERCH_SSL:
PERCH_AUTH_PLUGIN:
PERCH_DB_CHARSET: utf8
PERCH_DB_PORT:
PERCH_DB_SOCKET:
PERCH_APPS_EDITOR_PLUGIN: markitup
PERCH_APPS_EDITOR_MARKUP_LANGUAGE: textile
HOSTING SETTINGS

PHP: 5.5.12
Zend: 2.5.0
OS: Linux
SAPI: cgi-fcgi
Safe mode: not detected
MySQL client: mysqlnd 5.0.11-dev - 20120503 - $Id: bf9ad53b11c9a57efdb1057292d73b928b8c5c77 $
MySQL server: 5.6.17
Extensions: Core, date, ereg, libxml, openssl, pcre, sqlite3, zlib, bcmath, calendar, ctype, curl, dom, hash, fileinfo, filter, ftp, gd, gettext, SPL, iconv, session, json, ldap, mbstring, mcrypt, mssql, standard, mysql, mysqlnd, mysqli, PDO, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, Reflection, imap, SimpleXML, soap, sockets, exif, tidy, tokenizer, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, cgi-fcgi, memcache, geoip, mhash, ionCube Loader
GD: Yes
ImageMagick: No
PHP max upload size: 100M
PHP max form post size: 100M
PHP memory limit: 128M
Total max uploadable file size: 100M
Resource folder writeable: Yes
Session timeout: 240 minutes
Native JSON: Yes
Filter functions: Yes
Transliteration functions: No
DOCUMENT_ROOT: /var/sites/#/#/public_html
GATEWAY_INTERFACE: CGI/1.1
HTTP_ACCEPT: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
HTTP_ACCEPT_ENCODING: gzip,deflate,sdch
HTTP_ACCEPT_LANGUAGE: en-US,en;q=0.8
HTTP_CONNECTION: close
HTTP_COOKIE: hittail_ok=1; language=en; clickheat=#%7C%7C5ccfe9a77201506f19bd368f4225310c; clickheat-admin=1; __atssc=twitter%3B1; #DomRenewRes=eyJzdWNjZXNzIjoic3VjY2VzcyJ9; LiveHelpSession=y5u15rypeskz8hui0a8d26c513fc7f08eeed8751072124d74b8b0d40IiVZ0wOYox7G9CO4pKIHnRh2XZweZmQB7lNkFc2E2Es%3D; cmssb=0; WHMCSSD=eyJpbnZvaWNlcyI6eyJvcmRlcmJ5IjoiaWQiLCJzb3J0IjoiIn19; WHMCSzzvb7z2JPtYO=cafa9712819ff75dfed828df24305432; WHMCSFD=eyJjbGllbnRzIjp7InVzZXJpZCI6IiIsImNvdW50cnkiOiIiLCJjbGllbnRuYW1lIjoiIiwiY29tcGFueW5hbWUiOiIiLCJlbWFpbCI6IiIsImFkZHJlc3MiOiIiLCJzdGF0dXMiOiIiLCJzdGF0ZSI6IiIsImNsaWVudGdyb3VwIjoiIiwicGhvbmVudW1iZXIiOiIiLCJjdXJyZW5jeSI6IiIsImNhcmRsYXN0Zm91ciI6IiIsImN1c3RvbWZpZWxkcyI6IiJ9LCJjbGllbnRzaW52b2ljZXMiOnsic2VydmljZWlkIjoiIiwiYWRkb25pZCI6IiIsImRvbWFpbmlkIjoiIiwiY2xpZW50bmFtZSI6IiIsImludm9pY2VudW0iOiIiLCJsaW5laXRlbSI6IiIsInBheW1lbnRtZXRob2QiOiIiLCJpbnZvaWNlZGF0ZSI6IiIsImR1ZWRhdGUiOiIiLCJkYXRlcGFpZCI6IiIsInRvdGFsZnJvbXRvdGFsdG8iOiIiLCJzdGF0dXMiOiIiLCJ0b3RhbGZyb20iOiIiLCJ0b3RhbHRvIjoiIn0sImludm9pY2VzIjp7ImNsaWVudGlkIjoiIiwiaW52b2ljZW51bSI6IiIsImNsaWVudG5hbWUiOiIiLCJpbnZvaWNlZGF0ZSI6IiIsImxpbmVpdGVtIjoiIiwiZHVlZGF0ZSI6IiIsInBheW1lbnRtZXRob2QiOiIiLCJkYXRlcGFpZCI6IiIsInN0YXR1cyI6IiIsInRvdGFsZnJvbSI6IiIsInRvdGFsdG8iOiIifSwic3VwcG9ydHRpY2tldHMiOnsidmlldyI6ImFjdGl2ZSIsImRlcHRpZCI6IiIsImNsaWVudCI6IiIsImNsaWVudGlkIjoiIiwiY2xpZW50bmFtZSI6IiIsInN1YmplY3QiOiIiLCJlbWFpbCI6IiIsInRhZyI6IiJ9LCJvcmRlcnMiOnsiY2xpZW50IjoiIiwiY2xpZW50aWQiOiIiLCJjbGllbnRuYW1lIjoiIiwib3JkZXJpZCI6IiIsIm9yZGVybnVtIjoiIiwicGF5bWVudHN0YXR1cyI6IiIsIm9yZGVyZGF0ZSI6IiIsInN0YXR1cyI6IiIsImFtb3VudCI6IiIsIm9yZGVyaXAiOiIifX0%3D; __atuvc=7%7C42%2C6%7C43%2C54%7C44%2C35%7C45%2C24%7C46; __atuvs=5465d2e028f0ce1b000; cmsa=1; __utmt=1; __utma=153685562.2070933712.1401461902.1415890916.1415959264.125; __utmb=153685562.4.10.1415959264; __utmc=153685562; __utmz=153685562.1415631162.113.12.utmcsr=#|utmccn=(referral)|utmcmd=referral|utmcct=/; PHPSESSID=a027995b9b4780f1809fc0a0cee7b4dc
HTTP_HOST: #
HTTP_REFERER: https://#/2014/site_admin/core/settings/diagnostics/
HTTP_USER_AGENT: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.111 Safari/537.36
HTTP_X_FORWARDED_FOR: #
PATH: /bin
QUERY_STRING: extended
REDIRECT_STATUS: 200
REMOTE_ADDR: #
REMOTE_PORT: 36819
REQUEST_METHOD: GET
REQUEST_URI: /2014/site_admin/core/settings/diagnostics/?extended
SCRIPT_FILENAME: /var/sites/#/#/public_html/2014/site_admin/core/settings/diagnostics/index.php
SCRIPT_NAME: /2014/site_admin/core/settings/diagnostics/index.php
SERVER_ADDR: #
SERVER_ADMIN: you@example.com
SERVER_NAME: #
SERVER_PORT: 80
SERVER_PROTOCOL: HTTP/1.1
SERVER_SOFTWARE: Apache
PHP_SELF: /2014/site_admin/core/settings/diagnostics/index.php
REQUEST_TIME_FLOAT: 1415960910.2
REQUEST_TIME: 1415960910
argc: 1
Drew McLellan

Drew McLellan 2638 points
Perch Support

It's really hard to say, especially as you won't share full information with me. Is there anything in those hashed areas that might cause an issue?

Obviously this isn't generally broken for everyone, so it has to be something specific to the environment.

Drew, I can provide that info privately

Am I ok to email you directly with the diagnostics report attached?

Drew McLellan

Drew McLellan 2638 points
Perch Support

Sure, please do.

Thanks Drew, I did that a short while back using the 'contact us' link from the 'help and support' tab

Hi,

Did you get my email ok?

Drew McLellan

Drew McLellan 2638 points
Perch Support

I did - I'm looking at this today.

Thanks Drew

Just so you know, the installation of Runway was done as an upgrade from standard Perch and not as a fresh install.

Drew McLellan

Drew McLellan 2638 points
Perch Support

Ok, thanks.

Hi Drew, any news on this?

Should I just install a fresh copy of Runway?

Hi Drew,

Apologies, I have it working now. You mentioned previously about adding type > file

I have just spotted a typo which I corrected and now it works.

Sorry! so your advice to add that definition was the correct solution