Mega menu throws an error when adding the block

Permalink Browser Info Environment
Throws an error when we attempt to add the menu to our site on a clean install of 9.1.1

Undefined property: Concrete\Package\JbMegamenu\Block\JbMegamenu\Controller::$requestArray
Details
/home/uksmdtxb/public_html/concrete/src/Block/BlockController.php(698): Whoops\Exception\ErrorException->null   
/home/uksmdtxb/public_html/concrete/src/Block/BlockController.php(698): Whoops\Run->handleError   
/home/uksmdtxb/public_html/packages/jb_megamenu/blocks/jb_megamenu/controller.php(203): Concrete\Core\Block\BlockController->post   
/home/uksmdtxb/public_html/concrete/src/Entity/Block/BlockType/BlockType.php(675): Concrete\Package\JbMegamenu\Block\JbMegamenu\Controller->save   
/home/uksmdtxb/public_html/concrete/src/Page/Collection/Collection.php(1032): Concrete\Core\Entity\Block\BlockType\BlockType->add   
/home/uksmdtxb/public_html/concrete/src/Page/Page.php(2653): Concrete\Core\Page\Collection\Collection->addBlock   
/home/uksmdtxb/public_html/concrete/controllers/dialog/page/add_block.php(100): Concrete\Core\Page\Page->addBlock   
/home/uksmdtxb/public_html/concrete/src/Controller/AbstractController.php(318): Concrete\Controller\Dialog\Page\AddBlock->submit   
/home/uksmdtxb/public_html/concrete/src/Controller/AbstractController.php(318): null->call_user_func_array   
/home/uksmdtxb/public_html/concrete/src/Routing/ControllerRouteAction.php(64): Concrete\Core\Controller\AbstractController->runAction   
/home/uksmdtxb/public_html/concrete/src/Http/RouteDispatcher.php(37): Concrete\Core\Routing\ControllerRouteAction->execute   
/home/uksmdtxb/public_html/concrete/src/Http/Middleware/DispatcherDelegate.php(39): Concrete\Core\Http\RouteDispatcher->dispatch   
/home/uksmdtxb/public_html/concrete/src/Http/Middleware/MiddlewareStack.php(86): Concrete\Core\Http\Middleware\DispatcherDelegate->next

Type: Ticket
Status: In Progress
UKSMDT
View Replies:
jb1 replied on at Permalink Reply
jb1
Hi, that's pretty strange. I have not tested in 9.1.1 but as far as I'm aware there shouldn't be any breaking changes.

Have you installed this on any other sites with previous versions of Concrete CMS?

I noticed in your environment you've got PHP 8+. I don't think I've tested Mega Menu on PHP 8 yet either. It's been a bit hit or miss with Concrete so I've been waiting until the core is more stable with 8 before pushing forward with that.

Any chance you can test with PHP 7.4 to see if that's the cause?

JB
UKSMDT replied on at Permalink Reply
UKSMDT
Seems that php 8.0 is the issue here, concrete themselves are officially supporting 8.0 up now so you may get more people having this issue going forward.
jb1 replied on at Permalink Reply
jb1
When I first installed Concrete CMS V9, I tried with PHP 8 and it threw errors (that's just the core, not addons). So even after a couple months I would not be comfortable running it on a production site even without the errors now. There are likely to be more core bugs that get discovered relating to PHP8 in the coming weeks.

I'm currently travelling and out of the office for an extended period, so development work is on hold until I get back. But as soon as I get a chance I'll run 9.1.1 on a new installation to test it more thoroughly.

JB
jb1 replied on at Permalink Reply
jb1
Just circling back to let you know that the latest version of Mega Menu is compatible with PHP8 and the latest version of ConcreteCMS 9.x. Hope this helps.

concrete5 Environment Information

# Concrete Version
Core Version - 9.1.1
Version Installed - 9.1.1
Database Version - 20220516191423

# Database Information
Version: 10.3.35-MariaDB-cll-lve
SQL Mode: STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

# Concrete Packages
Cloneamental (0.9.3), Macareux Stripe Subscription (2.0.1), Mega Menu (2.0)

# Concrete Overrides
None

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

# Server Software
Apache

# Server API
litespeed

# PHP Version
8.0.21

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

# PHP Settings
max_execution_time - 30
log_errors_max_len - 1024
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
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
session.cache_limiter - <i>no value</i>
session.gc_maxlifetime - 7200
soap.wsdl_cache_limit - 5
unserialize_max_depth - 4096

Browser User-Agent String

Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.5005.115 Safari/537.36 OPR/88.0.4412.85 (Edition std-1)

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.