Version9 and PHP 8 compatibility

Permalink Browser Info Environment
Following on from our discussion in Ajax Forms - Express Edition Light

Running this package on Concrete CMS version 9 and PHP 8 gives the following error:

Undefined property: Concrete\Package\KalmoyaHiddenAttributes\Attribute\HiddenAttributeDynamic\Controller::$avID

I appreciate this package is not expected to work yet - any ETA on compatibility?

Type: Pre-Sale
Status: Resolved
katalysis
View Replies:
mnakalay replied on at Permalink Reply
mnakalay
Thank you for the heads up. So far no ETA but I'll see what I can do and try to do it quickly
mnakalay replied on at Permalink Reply
mnakalay
Hello again,
I'm almost ready for this actually, it was faster than expected but I think I found a bug in Concrete that makes using this package a bit problematic under certain circumstances.

Could you run a test to see if you get the same problem. I'm on concrete 9.1.2.

Create an express form from the block, just add a field or 2. Just use normal core fields no need to use hidden ones. Also don't use the form already installed by Concrete, create a new one.

Then submit the form.

Then go to the dashboard to see the submission, edit it, and do you get errors when you try to save?

Let me know.
katalysis replied on at Permalink Reply
katalysis
I'm seeing the same thing. With PHP7.4 I get this:

Doctrine \ DBAL \ Exception \ InvalidFieldNameException
An exception occurred while executing 'UPDATE TestFormExpressSearchIndexAttributes SET ak_name = ? WHERE exEntryID = ?' with params [null, 20473]: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ak_name' in 'field list'
Previous exceptions
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ak_name' in 'field list' (42S22)
SQLSTATE[42S22]: Column not found: 1054 Unknown column 'ak_name' in 'field list' (42S22)


If I have PHP8 on I get an error from Anti Spam Master:

Undefined array key "timeOfLastIpLogClean"
mnakalay replied on at Permalink Reply
mnakalay
Yes Anti Spam Master is not v8 ready yet.

So anyway, the hack to deal with the core issue is to navigate to the Express object created by the form in the dashboard and then edit and save each attribute. Just put them in edit mode and save, no need to change anything.

I'm going to keep looking for a solution in the core so i can push it in GitHub
mnakalay replied on at Permalink Reply
mnakalay
Hello,
I fixed the package for PHP 8 and Concrete v9 and I pushed a PR to Concrete's Core for the bug I mentioned. Hopefully it gets accepted.

Update to version 3.0 of the package and you should be good to go
katalysis replied on at Permalink Reply
katalysis
This is is looking good for me now. Many thanks.

concrete5 Environment Information

# Concrete Version
Core Version - 9.1.2
Version Installed - 9.1.2
Database Version - 20220908074900

# Hostname
nh2.katalysis.net

# Environment
production

# Database Information
Version: 10.3.36-MariaDB
SQL Mode: STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

# Concrete Packages
Afixia: SEO Redirects (1.1.3), Ajax Forms - Express Edition Light (2.1.0), Anti-Spammer Master (2.0.3), Hidden Data Attributes for Express (2.0.3), Katalysis Base Bootstrap (0.0.6.0.0), Katalysis PSR Solicitors Theme Bootstrap (0.0.5.6)

# Concrete Overrides
blocks/page_list/controller.php, blocks/page_list, blocks/core_area_layout/form.php, blocks/core_area_layout, controllers/page_types/case_studies.php, controllers/page_types/blog.php, controllers/page_types/testimonials.php, controllers/page_types, elements/block_area_footer.php

# Concrete Cache Settings
Block Cache - Off
Overrides Cache - Off
Full Page Caching - Off
Full Page Cache Lifetime - Every 6 hours (default setting).

# Server Software
Apache

# Server API
cgi-fcgi

# PHP Version
8.0.24

# PHP Extensions
bcmath, bz2, calendar, cgi-fcgi, Core, ctype, curl, date, dba, dom, enchant, exif, fileinfo, filter, ftp, gd, gettext, gmp, hash, iconv, imagick, imap, intl, json, ldap, libxml, mbstring, mysqli, mysqlnd, odbc, openssl, pcntl, pcre, PDO, pdo_mysql, PDO_ODBC, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, readline, redis, Reflection, session, SimpleXML, soap, sockets, sodium, SPL, sqlite3, standard, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, xml, xmlreader, xmlwriter, xsl, Zend OPcache, zip, zlib

# PHP Settings
max_execution_time - 120
log_errors_max_len - 1024
max_file_uploads - 20
max_input_nesting_level - 64
max_input_time - 120
max_input_vars - 1000
memory_limit - 512M
post_max_size - 128M
upload_max_filesize - 128M
zend.exception_string_param_max_len - 0
ldap.max_links - Unlimited
mbstring.regex_retry_limit - 1000000
mbstring.regex_stack_limit - 100000
mysqli.max_links - Unlimited
mysqli.max_persistent - Unlimited
odbc.max_links - Unlimited
odbc.max_persistent - Unlimited
pcre.backtrack_limit - 1000000
pcre.recursion_limit - 100000
pgsql.max_links - Unlimited
pgsql.max_persistent - Unlimited
redis.pconnect.connection_limit - 0
session.cache_limiter - no value
session.gc_maxlifetime - 7200
soap.wsdl_cache_limit - 5
unserialize_max_depth - 4096
opcache.jit_bisect_limit - 0
opcache.jit_max_exit_counters - 8192
opcache.jit_max_loop_unrolls - 8
opcache.jit_max_polymorphic_calls - 2
opcache.jit_max_recursive_calls - 2
opcache.jit_max_recursive_returns - 2
opcache.jit_max_root_traces - 1024
opcache.jit_max_side_traces - 128
opcache.max_accelerated_files - 10000
opcache.max_file_size - 0
opcache.max_wasted_percentage - 5

Browser User-Agent String

Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You may not request a refund that is not currently owned by you.