Page field in Concrete 9.1 & PHP 8.1 returns the value bool(false) in its view.php

Permalink Browser Info Environment
In PHP 8.1 and concrete 9.1, Page field always returns false at its block's view.php

Not only as a single field but also occurred under repeatable.

The value of the page filed (cID) is correctly saved in the database. Page selector and setting the value won't have any problems at form.php.

I have tried to get the page field value at view.php but it always returns bool(false).

If I run the block conf files under php 7.4 and Concrete 9.1, the page filed returns its page collection value correctly.

It seems that this problem occurs depending on PHP version. My test config.php for this bug is here.


return [
// Block
'block' => [
'name' => t('Test'),
'description' => t('Created with Block Developer'),
],

// Fields
'fields' => [
'page_one' => [
"type" => "Page",
"label" => "select",
],
"entry"=>[
"type" => "Repeatable",
"label" => "tests",
"searchable" => true,
"config" => [
"add_label" => "Add",
"fields" => [
"page"=>[
"type" => "Page",
"label" => "select",
],
"title" => [
"type" => "Text",
"label" => "title",
"required" => false,
],
"image" => [
"type" => "File",
"label" => "image",
"required" => false,
],
]
]
]
],
];

I purchased this block for production. I hope this bug is patched as soon as possible.

Type: Ticket
Status: Resolved
media3140
View Replies:
media3140 replied on at Permalink Reply
media3140
oh, sorry. I noticed this forum (https://marketplace.concretecms.com/marketplace/addons/block-developer/support/page-selector/) after posting.

Upgrading to 1.4.2 from 1.4.1, this problem has been solved.

concrete5 Environment Information

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

# Hostname
eda136f3ff80

# Environment
production

# Database Information
Version: 5.7.21
SQL Mode: ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

# Concrete Packages
Block Developer (1.4.1), Manual Nav (3.0.0), Multiple-Step Workflow (2.0.0a1), 世田谷社会福祉協議会様テーマ・パッケージ (1.1.3)

# Concrete Overrides
blocks/test/add.php, blocks/test/composer.php, blocks/test/config.php, blocks/test/controller.php, blocks/test/db.xml, blocks/test/edit.php, blocks/test/form.php, blocks/test/icon.png, blocks/test/view.php, blocks/test, controllers/workflow/categories/page.php, controllers/workflow/categories, controllers/workflow, elements/page_controls_footer.php, elements/workflow/notifications.php, elements/workflow, mail/basic_workflow_notification.php, single_pages/dashboard/sitemap/full.php, single_pages/dashboard/sitemap, single_pages/dashboard, src/Workflow/MultipleStepWorkflow.php, src/Workflow

# 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/2.4.54 (Debian)

# Server API
apache2handler

# PHP Version
8.1.12

# PHP Extensions
apache2handler, Core, ctype, curl, date, dom, fileinfo, filter, ftp, gd, hash, iconv, intl, json, libxml, mbstring, mysqli, mysqlnd, openssl, pcre, PDO, pdo_mysql, pdo_sqlite, Phar, posix, Reflection, session, SimpleXML, sodium, SPL, sqlite3, standard, tokenizer, xml, xmlreader, xmlwriter, zip, zlib

# PHP Settings
max_execution_time - 30
max_file_uploads - 20
max_input_nesting_level - 64
max_input_time - 60
max_input_vars - 1000
memory_limit - 128M
post_max_size - 8M
upload_max_filesize - 2M
zend.exception_string_param_max_len - 15
mbstring.regex_retry_limit - 1000000
mbstring.regex_stack_limit - 100000
mysqli.max_links - Unlimited
mysqli.max_persistent - Unlimited
pcre.backtrack_limit - 1000000
pcre.recursion_limit - 100000
session.cache_limiter - no value
session.gc_maxlifetime - 7200
unserialize_max_depth - 4096

Browser User-Agent String

Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.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.