Err 500 during modules enabling

ksen-pol
Forums
Hello! I have installed the distribution but I can not enable opigno modules. I have the page of err 500 after saving the configuration How should I enable opigno modules? Here is the video of what happenes https://www.youtube.com/watch?v=9lSR5mJBTFU&feature=youtu.be
James Aparicio

Hi ksen-pol,

Hi ksen-pol,

Does this happen with all modules? That is strange.

Check your server for the log.

 

Best regards

ksen-pol

Thank you

Thank you On server logs: syntax error, unexpected '[' in /home/.../profiles/opigno_lms/modules/contrib/homebox/homebox.module on line 37 Admins guess that it can be cause of PHP version that is PHP 5.3, on my server now. I have setting recommended for Drupal 7. Should I change them? Or may be I should unable homebox moudule? Do I really need this module?
ksen-pol

I had also such mistakes

I had also such mistakes 1)Undefined index: name in system_requirements() (line 34 of ... modules/system/system.install). • Notice: Undefined index: version in system_requirements() (line 36 ..../modules/system/system.install). 2)Notice: Undefined index: distribution_name in drupal_install_profile_distribution_name() (line 207 of /..../includes/install.inc). I found a way to fis it by changing return $info['distribution_name'] for if ( ! array_key_exists('distribution_name', $info)) { $info['distribution_name'] = 'Drupal'; return $info['distribution_name'];
James Aparicio

Oh i see,

Oh i see,

Latest version of opigno updated the homeboc module. 

That module has a line of code that requires php 5.4.

You can just apply this patch https://www.drupal.org/node/2782675 , or update php.

 

Best regards

 

ksen-pol

Thank you!

Thank you! Will my opigno work without this module? What will I loose? Is it a basic core module for the whole system or just gives any additioanl opportunities?
James Aparicio

Hi ksen-pol,

Hi ksen-pol,

The homebox module adds the homepage with different blocks such as latest added content, in progress couses etc.  The patch is just 1 line of code. If you change it you will not need to update php. We will release a new version in the following month or 2, with this patch.

I would suggest you install the distribution instead of the modules individually if you do not have experience with it.

Best regards

ksen-pol

Thank you

Thank you I see the question in the patch Where can I find the number of line to change and what to paste? Yes, now I have distribution
James Aparicio

Hi ksen-pol, Its in the patch

Hi ksen-pol,

Its in the patch. https://www.drupal.org/files/issues/homebox-php-syntax-error-2782675-7.x-2.0-rc3.patch
The name of the function is homebox_menu file homebox.module. The line you have to remove is the onw with a - and the one to add with a +.

Best regards 
ksen-pol

Thank you.

Thank you. I have never used any patches. While I was trying to learn how to do it my admin on hosting hepled by using this patch https://www.drupal.org/node/2771029 I am on the way to learn how to use patches. Thank you.