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: Bloqs not saving only on remote environment

Status Resolved
Add-on / Version Bloqs 3.3.4
Severity
EE Version 3.5.15

Mighty Citizen

Feb 16, 2018

 

Hey Brian,
I’m having an issue where my Bloqs content isn’t saving on a remote environment - I’ve disabled every other addon, caching, and I’m still having the issue. It’s working fine on my local, which is running on the same PHP version. I know it’s not easy to troubleshoot without access to their environment since I’m doubtful that you’ll get the issue on your local, but I did want to reach out to you about whether there was anything you noticed on their PHP info file that would be relevant to Bloqs inserting content into the database.

I’m doubtful that our client will give you access to their environment, but I was going to spin up a development site on a different environment to confirm that the issue is localized to that initial instance, and I can give you access to that if needed.

Thanks,
Kristine

 

 

 

#1

BoldMinded (Brian)

Hi Kristine. How many blocks are you trying to save in the entry? If it has a lot of blocks and atoms, it may have an issue with the max imput vars. http://php.net/manual/en/info.configuration.php#ini.max-input-vars

Basically it would truncate the $_POST array and not save everything, or throw an error. Are you seeing any errors or it just doesn’t save anything (regardless of the atom fieldtype)?

#2

BoldMinded (Brian)

Forgot to mention to check the max_input_vars value in the php.ini file on both servers to see if they are different.

#3

Mighty Citizen

I’ve tested with saving just one block and had the issue. I’m not seeing any errors and I get the default EE Entry Updated success message, but it just doesn’t save anything regardless of atom fieldtype. The server that’s having the issue has max_input_vars set to 1000, which is the same as my local.

#4

BoldMinded (Brian)

What other add-ons do you have installed?

#5

Mighty Citizen

I have the following installed - but I’ve uninstalled all of them except Bloqs and still have the issue: Antenna 2.2 BBD Chopper 1.0.3 Bloqs 3.3.4
Digi Nut Control Panel CSS & JS 1.0.1 Low Events 2.1.0 Low Search 5.2.0 Low Seg2Cat 3.0.0 NavEE 3.1.16 Publisher 2.7.5 Publisher - NavEE Support 2.0.0 SEO Lite 1.5.4 Snaptcha 2.0.2 Stash 3.0.6 VZ Bad Behavior 2.0.2 Wygwam 4.1.9

#6

BoldMinded (Brian)

In the CP, in both environments, see if there is a hidden field named bloqs_form_secret_X where x is the field id. And make sure it has a value.

#7

Mighty Citizen

Both environments have that hidden field and they both have a value

#8

Mighty Citizen

I ran a diff checker on the field output on the two environments and they were the same (aside from the difference in URL on the hidden img field): https://www.diffchecker.com/ChoANZ8d

#9

BoldMinded (Brian)

Comment has been marked private.

#10

BoldMinded (Brian)

Have you tried a 3rd environment? I’m not sure how much help I would be without CP and FTP access to that production environment to fix the issue b/c I don’t know what is happening. Are you able to provide such access?

#11

Mighty Citizen

I’ve created a 3rd environment and the issue isn’t happening there - but if you want to take a look to see what I’ve got, I added the access details to the ticket

#12

BoldMinded (Brian)

Have you compared the php.ini of the environments? Can you provide CP access to the environment that isn’t working? I don’t know if I’ll be able to tell much without debugging the code, but maybe I’ll see something in the CP… its a long shot though.

#13

Mighty Citizen

I reached out to them about getting you access - otherwise, I’ll see if I can take a look at the php.ini file and see if there are any clues there

  • K
#14

BoldMinded (Brian)

You could also load up that php info page from the CP in both environments, save the html source locally, then run a diff against them.

#15

Mighty Citizen

Comment has been marked private.

#16

Mighty Citizen

FYI the original text is the working environment

#17

BoldMinded (Brian)

So the one on the left is local/dev, and right is production? Meaning production is Windows, not Apache? That is a pretty big difference, though I don’t know why Bloqs would care about that.

#18

BoldMinded (Brian)

Dev has max_input_vars set to 2500, but prod has it at 1000.

#19

Mighty Citizen

Left is dev (the one that I’ve given access details in the ticket info) and right is production - yeah, sorry forgot to mention that it’s a Windows environment.

I didn’t include my local, which is what had max_input_vars set to 1000 as well - I just updated the dev environment from 2500 to 1000, and it still works there so I don’t think that’s the issue. Still waiting on their response about whether they would be willing to give you access to their environment.

#20

Mighty Citizen

They’re still looking into getting you access, but he suggested setting up a screenshare - would you be available for a screenshare to walk me through any troubleshooting steps?

Thanks, Kristine

#21

BoldMinded (Brian)

I need to be able to inspect the code and add var_dumps or logging at various points to determine what the issue is, and it could take awhile to do that. I’m not sure it would be an efficient use of time, and I would have to do it in the evenings.

Could you try adding this die statement to see if it triggers? Its the only place I know of that absolutely prevents Bloqs from saving.

https://www.dropbox.com/s/93ekd638dmxb49t/Screenshot 2018-02-20 14.34.38.png?dl=0

#22

Mighty Citizen

You’re right - that looks like where it’s breaking. I echoed the $sessionFormSecret and $postFormSecret to compare and it looks like the $sessionFormSecret is blank

#23

BoldMinded (Brian)

Ok, for now, just comment out that conditional that compares the two. It was only added b/c a couple people had issues with content editors hitting the submit button twice and it was creating too many blocks. Its there only to make sure that the form is only submitted once. So I’m guessing something on your production server doesn’t like the $_SESSION global.

#24

Mighty Citizen

Sounds good, seems to be working now - thanks so much for your help, Brian!

#25

BoldMinded (Brian)

No problem. Sorry I didn’t think of that sooner 😊

Try replacing that die() statement with var_dump($_SESSION); die; to see what is in the global.

#26

Mighty Citizen

Here’s what outputs:

array(4) { [“exp_publisher_prev_status_cp”]=> string(0) “” [“exp_publisher_site_language_cp”]=> int(1) [“exp_publisher_save_status_cp”]=> string(4) “open” [“isNewEntry”]=> bool(false) }

#27

BoldMinded (Brian)

Following up on this… I have no idea why that $_SESSION variable is not getting set, or its getting set but removed too soon by something else? This is the first I’ve seen this happen and the only instance of Bloqs that I know of that is running on a Windows environment. I’m going to try to use EE’s session->cache instead of the server $_SESSION to see if I can keep the functionality but still make it work in your environment. I’ll test this locally and let you know when I figure something out.

#28

Mighty Citizen

Sounds good - thanks as always for your help!

#29

BoldMinded (Brian)

I still can’t connect, tried FTP and SFTP.

#30

Mighty Citizen

That’s odd - what’s your IP address? I’ll see if I can whitelist you

#31

BoldMinded (Brian)

Comment has been marked private.

#32

Mighty Citizen

Alright, just whitelisted - let me know if that works!

#33

BoldMinded (Brian)

Comment has been marked private.

#34

Mighty Citizen

Hmm, nope that doesn’t need to be changed. I updated the password in the ticket and on the server - maybe something about the password pasting in the ticket is screwing it up.

#35

BoldMinded (Brian)

It works with the new password. Thanks.

#36

Mighty Citizen

Phew! Sorry about that

#37

BoldMinded (Brian)

Keeping this ticket open for a few more days b/c it has login info in it. The latest version of Bloqs has that conditional removed, so it should resolve the issue you’re having.

Login to reply