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: Redirect a disabled language

Status Resolved
Add-on / Version Publisher 2.10.7
Severity
EE Version 5.2.1

Werner Gusset

Jan 19, 2021

The installation is EE 5.3.2 and Publisher 3.1.5 on one server and EE 5.3.2 and Publisher 3.2.2 on the dev server with the same website project.

Dev server had PHP 7.2 during development and all went right. and I moved to the new server that has PHP 7.4 and there I have troubles.

when I open an entry I get the following error. On dev server I updated to 3.2.2 of Publisher and on PHP 7.4 I get the same error on a different code line.
When I go to PHP 7.2 on dev server the error is away. On the other server the customer refuses to go to PHP 7.2. So I am stuck

The error

Publisher 3.2.2

Trying to access array offset on value of type null
user/addons/publisher/tab.publisher.php, line 166
*
Severity: E_NOTICE


Publisher 3.1.5

NoticeTrying to access array offset on value of type null
user/addons/publisher/tab.publisher.php, line 139
*
Severity: E_NOTICE

On the customer’s server with PHP 7.4 there is another issue. When I call the domain URL EE tries to go to the standard language and add the /de to the domain URL and this gives 404 The requested URL was not found on this server.
If this is tied to the above error I don’t know.

Any idea what goes wrong?

#1

BoldMinded (Brian)

Comment has been marked private.

#2

BoldMinded (Brian)

As for your second issue with the /de to the domain URL, what you’re describing is very vague. It sounds like a Publisher configuration issue. If you’re forcing it to show the language segment and German is the default, then that explains the redirect. If it’s showing a 404, then that isn’t Publisher, that would most likely be a template issue.

#3

Werner Gusset

Thanks for the fix. Can only test tomorrow morning.

The second issue: yes the redirect is normal, I know that. I only don’t understand why it then has a 404. It is not the template, it works on the dev server. I don’t know if it could be something on the server. It’s not bought hosting, it’s the customer’s own server. According to the specs for EE there is all correct. I might test using query string tomorrow too.

#4

BoldMinded (Brian)

Check the Network tab to see if there are any headers if it is doing a redirect to a 404 page. Every time Publisher performs a redirect, it adds the header “X-Publisher-Redirect: [whatever method called the redirect]” - so it’s easy to tell where and why it might be performing a redirect.

#5

Werner Gusset

Have updated Publisher to 3.2.3

The error when opening an entry is gone. Thanks.

But the diagnostics says

Uh oh! It looks like there is an error with your Publisher install. Either a hook is missing or not enabled.

Do I need to do something?

#6

BoldMinded (Brian)

Can you share a screenshot of the diagnostics page? It should clearly show which hook is not installed if that were the case.

#7

Werner Gusset

Comment has been marked private.

#8

BoldMinded (Brian)

Yeah, that’s not good. Are you sure extensions are enabled? You don’t have $config[‘allow_extensions’] = ‘n’; in your config.php file do you?

Did you check the exp_extensions table to see if those rows exist?

#9

Werner Gusset

The config has no entry about extensions.

The rows are in the exp_extensions table. Have not checked all, but the first 15 are.

#10

Werner Gusset

We still search for the second issue’s reason. Can Publisher be removed and the site will still function? In the default language only of course.

#11

BoldMinded (Brian)

It’s hard to tell why it’s reporting those hook issues, but if Publisher is working, e.g. translations are showing up, then it’s probably fine and there might be a logic issue with that diagnostics page.

Publisher can be removed, but when you do that, you’ll lose all your non-default language data.

#12

Werner Gusset

At the moment we don’t see any issues with Publisher. But it was only a short check.

#13

Werner Gusset

Coming back to the diagnostics page that shows all in red:

I only now see that one line shows this:

blocks_after_display_field NOT INSTALLED

How can I get rid of this?

#14

BoldMinded (Brian)

That doesn’t get installed unless you have Bloqs. And it’s getting removed in the next version, so I wouldn’t worry about it.

#15

Werner Gusset

Found another issue with 3.2.3 that I only now see when I am logged in:

Warning Declaration of Publisher_channel_categories::category_subtree($cdata, $active_cat) should be compatible with Channel::category_subtree($cdata = Array, $active_cat = NULL)

user/addons/publisher/legacy/libraries/Publisher_channel_categories.php, line 1096

we did not have this with older version.

#16

Werner Gusset

Oh, but Boqs is in use in this install

#17

BoldMinded (Brian)

Did you click run addon updates?

#18

Werner Gusset

And where should I click this. There is a Link “Install Step 2”, is it this you mean? That was clicked.

#19

BoldMinded (Brian)

Is this a new installation or an upgrade? If an upgrade, from the add-ons list, it should have a button next to the add-on to upgrade.

#20

BoldMinded (Brian)

Comment has been marked private.

#21

Werner Gusset

You might be interested to know this:

I already finished moving the site to a new server as another test (the server where the site should go does give us problems, therefor we test on server we know good).

The copy I installed does not give that error when we click a link that is a category, like it does on the dev server of this site.

Why is that, no idea? It’s a 1 to 1 copy. How come it’s on the dev version? I understand that you might not know too.

#22

Werner Gusset

Oh, I only saw now that you have that new built. Gonna test.

#23

Werner Gusset

The error is gone. Thank you.

You can close this ticket.

#24

BoldMinded (Brian)

Werner, something came up in another ticket that might have revealed an issue with the 3.0.0 update script.

Run this query, and if it returns 0 rows, run the next query to add it

select * from exp_extensions where class = 'Publisher_ext' and method = 'cp_members_member_delete_end';
INSERT INTO `exp_extensions` (`class`, `method`, `hook`, `settings`, `priority`, `version`, `enabled`)
VALUES
 ('Publisher_ext', 'cp_members_member_delete_end', 'cp_members_member_delete_end', '', 5, '3.2.2', 'y');

Also seeing if the exp_publisher_previews table has the override and route columns, if not, run these two queries:

ALTER TABLE `exp_publisher_previews` ADD `override` text DEFAULT null AFTER `custom` ;
 ALTER TABLE `exp_publisher_previews` ADD `route` int(4) DEFAULT 0 AFTER `override` ;
#25

Werner Gusset

Brian, I checked. Found 1 row in there.

And there are the 2 columns.

Thanks for letting me know.

#26

BoldMinded (Brian)

What about the value of this query?

select val from exp_publisher_settings where `key` = 'install_complete';
#27

Werner Gusset

this has now row

#28

BoldMinded (Brian)

Run this query then

INSERT INTO `exp_publisher_settings` (`site_id`, `key`, `val`, `type`) VALUES (0, 'install_complete', 'yes', 'boolean');
#29

Werner Gusset

Done!

#30

BoldMinded (Brian)

What does your diagnostics page show now?

#31

Werner Gusset

It does still show what I reported before:

All hooks seems OK, but the icons are red and the message is “Uh oh! It looks like….”

#32

BoldMinded (Brian)

Is this a site you can provide FTP access to so I can see what the issue is?

#33

Werner Gusset

Yes, I can give you access. How do send the infos?

#34

BoldMinded (Brian)

Edit the ticket and use the fields provided. When the ticket is closed the field values are deleted from the db.

#35

Werner Gusset

It has changed the title and version infos. Are they saved in my browser?

Have updated the ticket. This dev version runs as an subdomain in a directory.

#36

BoldMinded (Brian)

There is an http auth in front of the EE login screen that I can’t get past. Can you put the user/pass in a private comment?

#37

Werner Gusset

Comment has been marked private.

#38

BoldMinded (Brian)

Got to the login screen, but the user/pass you provided doesn’t work :(

#39

BoldMinded (Brian)

Thanks for providing that info. It was just a simple php logic issue. The diagnostics page should report correctly now. I’ll have this fix in the next release.

Login to reply