Can not Add Any Block to GlobalArea

Permalink
Hello

I'm starting to get little crazy with 5.7, I like the Drag&Drop but have so many bugs..
I added one area "new GlobalArea" to my page and if I'm at the Home page I can edit this new area, add, delete and add any Block to this Area but if I navigate to other page or add any new page I can not Add anything to this GlobalArea resulting always in the following error:

call_user_func_array() expects parameter 1 to be a valid callback, class 'Concrete\Core\Permission\Key\AddBlockBlockTypeKey' does not have a method 'canAddBlock'


It's very strange error but if anyone can help me please, because now I cant finish the project that I'm developing.
All the help it's welcome, thank you very much.

pedroserapio
 
andrew replied on at Permalink Reply
andrew
Have you done any work customizing permissions in any way? Someone else reported this but we really haven't had any luck reproducing it.
pedroserapio replied on at Permalink Reply
pedroserapio
That was the first step that I did, I checked all the permissions page by page but no lucky.
The strange part, I can go to Dashboard -> Stacks & Blocks then select View Global Areas -> Select for example one of the Global Areas then add what I need to appear in this areas. After this step I see in all pages this appear and I can edit in any page the content of this areas and they are updated along all the pages. But I can not add anything, really strange behavior and I have the same feeling that is something to do with permissions but can not find.
pedroserapio replied on at Permalink Reply
pedroserapio
I was thinking this problem was solved in 5.7.1 but I still can not add anything to GlobalAreas if I create a new Theme. With the core theme Elements this is possible and when I create a new theme the only page that let do this operations it's the Home page. Very hard to me to understand what can be wrong, anything or any global variable that I need to define in my page templates?

I used Apache in Windows, in Ubuntu Linux and with Nginx, in all this environments I got the same problem.
pedroserapio replied on at Permalink Reply
pedroserapio
I understand that this is a Beta version full of bugs but "come on", start to be almost impossible to use, again in 5.7.2 I can only add contents to GlobalAreas If I'm at the Home page but after add new page I can not add anything, always get this error:


call_user_func_array() expects parameter 1 to be a valid callback, class 'Concrete\Core\Permission\Key\AddBlockBlockTypeKey' does not have a method 'canAddBlock'


Tried in WAMP, LAMP and LEMP... nothing nothing.
pedroserapio replied on at Permalink Reply
pedroserapio
To make this more crazy.

I added a new user that belong to Administrators Group and after log in I can not add any new Page.

You do not have permission to publish a page in this location


I start to see that we need stick with the Core Theme, any customization it's almost impossible.

Thank you very much if anyone have any idea.
stereocenter replied on at Permalink Reply
Hi, I was wondering if you could explain how you added a global area to your page. Is this done within the dashboard via drag-and-drop in a way I'm not seeing? Any insights would be appreciated. Thanks!
mhawke replied on at Permalink Reply
mhawke
"Global Areas" are hard-coded into the php files in your theme folder on your server. You can't add them from the front end.
pedroserapio replied on at Permalink Reply
pedroserapio
mhawke It's right. The Global and New Areas must be previously programmed, we don't have any easy drag and drop. In that part I don't have any problem. My problem it's when I start adding new content blocks to this GlobalAreas. I think I don't have any other solution, I'm "moving" the website to 5.6, maybe one day can use the fancy 5.7.

stereocenter, here I write some examples for your future projects and keep in mind if later you delete a New Area you will lose the access to the content that you added to this areas and if you change the name of a Global Area then 5.7 go "bananas"

Example of Global Area:
<?php
$a = new GlobalArea('Navigation');
$a->display();?>


Example of New Area:
<?php
$a = new Area('MainColumn');
$a->display($c);?>



Thank you very much for all the support mhawke.
pedroserapio replied on at Permalink Reply
pedroserapio
After another day of work I made again all the website in 5.6, add Users, some to Administrators Group some to other groups. The Global Areas worked well well in any page, including the Home page and new Pages. The users that belong to Administrators Group can edit any page, add pages and edit the Global Areas. And I almost forgot, this have a custom Theme.

I just have one question, why in 5.6 this is possible and it's simple task and why in 5.7 this is impossible? What it's so different in 5.7 that make the usage of users impossible?

Thank you very much.
mhawke replied on at Permalink Reply
mhawke
5.7 is too new. There are lots of issues and the core team is working day and night to fix them all but every software version has bugs at the beginning.
andrew replied on at Permalink Reply
andrew
This has been identified as a problem when using page templates that didn't have a Main area on them. We have fixed this issue and it will be released very soon. We didn't catch this because all our templates have a Main area in them, because including Main, while not a strict requirement, is a very good idea and definitely a best practice.
lexbi replied on at Permalink Reply
Hey @andrew what do you mean by "Main" area? Is this all you mean?
<?php
    $a = new Area('Main');
    $a->display($c);
?>

I am having this issue now. I don't get an error or anything and it seems like I can add a block to the global area in edit mode, though when I publish it simply disappears...

P.S - Please could I request an update to your site, it's really annoying that you have to reply in a lightbox, I quite like being able to scroll the thread & refer back to the original post while writing out a response.