All add-ons currently require PHP 7.4 or greater.

On July 4th 2024 PHP 8.2 will be the new minimum requirement for all add-ons. Expect any add-on released after that date to require 8.2 or greater. Some releases may not immediately take advantage of 8.x specific features in PHP, which means you might, be able to continue using new releases in PHP 7.4, however, if you experience an error the first thing you should do is update to PHP 8.2 then create a support ticket if the error persists.

Publisher does not support the Fluid field type. Please do not contact asking when support will be available.

If you purchased an add-on from expressionengine.com, be sure to visit boldminded.com/claim to add the license to your account here on boldminded.com.

Ticket: Only variables should be passed by reference

Status Resolved
Add-on / Version 1.7.1
Severity
EE Version 2.11

Cameron Ross

Nov 23, 2016

Description:

Getting an error when i go to publish an entry :

A PHP Error was encountered
Severity: Notice
Message: Only variables should be passed by reference
Filename: models/publisher_query.php
Line Number: 141


Detailed steps to reproduce the issue:
1. Log in to cms
2. Go to publish entry
3. Error displays

#1

BoldMinded (Brian)

What version of PHP?

#2

BoldMinded (Brian)

Line 141 of that file is this: $file = str_replace(‘.php’, ”, end(explode(‘/’, $backtrace[‘file’])));

And there isn’t a single variable in that file being accessed by reference. This error makes no sense. Before line 141 add:

var_dump(debug_backtrace(null, 5));

and see what it prints out.

#3

Cameron Ross

Hi

Any update on this?

#4

BoldMinded (Brian)

Can you add echo ‘<pre>’; before that var dump so I can read the output better?

#5

BoldMinded (Brian)

Can you provide more info on what types of fields you have on the page? In the email you mentioned you had a Grid field… what fieldtypes are inside the Grid? Could you attach screenshot of the entire Publish page to this ticket?

Also, please respond in the ticket thread, not directly via email. Thanks.

#6

Cameron Ross

Hi

and go to content-publish->home you will see the error

I have only added a grid field for testing but we will be using this field type a lot

the field group is called home and i only have 1 cell

#7

Cameron Ross

maybe you might have a quick for for this?

#8

BoldMinded (Brian)

Comments are public unless you mark them private. Your FTP info was public for a few minutes. I’ll remove it from the comments.

I don’t have a quick fix, sorry. I can replicate it locally so I can work on a fix in the next few days.

#9

BoldMinded (Brian)

The only quick fix I can offer is to turn off/down your error reporting. The error is only a notice, so there probably isn’t anything actually going wrong here. The notice will should then go away.

#10

BoldMinded (Brian)

Cameron, see this ticket. https://boldminded.com/support/ticket/1356

#11

Gavin Lawrie

This bug is fixed if you follow the patch described here - https://boldminded.com/support/ticket/1356

#12

BoldMinded (Brian)

Confirmed that is a viable fix and it’ll be in the next release. Cameron, until the next release just edit that file as Gavin pointed out.

Login to reply