Missing Calendar

cravaus wrote on Tuesday, July 15, 2014:

I installed OpenEMR in another directory of my NAS. After linking it with my domain name, it was clear that I should have put it into the web directory and not the www directory. But now, for some reason, there is no calendar (white screen where calendar should be, Calendar Icon is Present in left column). Everything else appears to be in order. I looked at the Globals and it is not disabled. I deleted the install and openemr database and folder and started over and again no calendar. When installing at step one (both times) I had to do the following:

Permissions needed to be changed at:
chmod 0755 /volume1/web/openemr/phpmyadmin/config.inc.php
chmod 666 /volume1/web/openemr/sites/default/sqlconf.php
chmod 666 /volume1/web/openemr/sites/default/documents
chmod 666 /volume1/web/openemr/sites/default/edi
chmod 666 /volume1/web/openemr/sites/default/era
chmod 666 /volume1/web/openemr/sites/default/letter_templates
chmod 666 /volume1/web/openemr/gacl/admin/templates_c
chmod 666 /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pntemplates/compiled
chmod 666 /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pntemplates/cache

Changed owners for most of the same directories:
chown -R nobody:nobody /volume1/web/openemr/sites/default/documents
chown -R nobody:nobody /volume1/web/openemr/sites/default/edi
chown -R nobody:nobody /volume1/web/openemr/sites/default/era
chown -R nobody:nobody /volume1/web/openemr/sites/default/letter_templates
chown -R nobody:nobody /volume1/web/openemr/gacl/admin/templates_c
chown -R nobody:nobody /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pntemplates/compiled
chown -R nobody:nobody /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pntemplates/cache

So, there are some calendar items with problems that needed fixing. Any ideas on where I should look next? Should I delete all of MySQL completely and start over–again?

Craig

cravaus wrote on Tuesday, July 15, 2014:

Looking at the Error Log entries I see the following and am not sure what to do with it:

FastCGI: server “/php-fpm-handler” stderr: PHP message: PHP Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /volume1/web/openemr/library/adodb/drivers/adodb-mysql.inc.php on line 365, referer: https://[MyNASS]/openemr/interface/main/main_info.php

Which pionts to:
363 if (ADODB_PHPVER >= 0x4300)
364 $this->_connectionID = mysql_connect($argHostname,$argUsername,$argPassword,
365 $this->forceNewConnect,$this->clientFlags);
366 else if (ADODB_PHPVER >= 0x4200)
367 $this->_connectionID = mysql_connect($argHostname,$argUsername,$argPassword,
368 $this->forceNewConnect);

FastCGI: server “/php-fpm-handler” stderr: PHP message: PHP Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pnincludes/Smarty/Smarty_Compiler.class.php on line 92, referer: https://[MyNASS]/openemr/interface/main/main_info.php

Which points to:
89 /* Annihilate the comments. /
90 $template_source = preg_replace("!({$ldq})*(.
?)*({$rdq})!se",
91 “’\1*’.str_repeat(”\n", substr_count(’\2’, “\n”)) .’*\3’",
92 $template_source);

FastCGI: server “/php-fpm-handler” stderr: PHP message: PHP Warning: Smarty error: problem writing ‘modules/PostCalendar/pntemplates/compiled/default^views^day^default.html.’ in /volume1/web/openemr/interface/main/calendar/modules/PostCalendar/pnincludes/Smarty/Smarty.class.php on line 589, referer: https://[MyNASS]/openemr/interface/main/main_info.php

Which points to:
587 function trigger_error($error_msg, $error_type = E_USER_WARNING)
588 {
589 trigger_error(“Smarty error: $error_msg”, $error_type);
}

I will keep looking. Any tips are appreciated. Thanks.

cravaus wrote on Tuesday, July 15, 2014:

My minimal understanding of the code brings me to this. It looks like the second Error item is the issue. I think this may be what it is asking me to do but my syntax is wrong:

    $template_source = preg_replace_callback("!({$ldq})\*(.*?)\*({$rdq})!s",
                                    create_function ("'\\1*'.str_repeat(\"\n\", substr_count('\\2', \"\n\")) .'*\\3'",
                                    $template_source);

fsgl wrote on Wednesday, July 16, 2014:

Found this.

iankarlwallace wrote on Thursday, July 17, 2014:

Craig - The two deprecation warnings won’t be the problem. Deprecations
just mean that in the next release of PHP most likely these calls won’t
work or won’t work as you expect them to work. The OpenEMR group is aware
that we need to move away from the older mysql_connect calls and the
deprecated preg_replace. Both those fixes will most likely come to our
attention with the next version of PHP.

The real issue still seems to be in the directory permissions your third
error is the key:

Smarty error: problem writing
‘modules/PostCalendar/pntemplates/compiled/default^views^day^default.html.’

I would recheck the perms on the compiled directory and make sure that the
webserver user (if it’s nobody:nobody) can truly create a file in that
directory.

Hope that points in the correct direction. Confirm that there is not a
directory in the ‘compiled’ directory named ‘default’.

cheers
ian

On Wed, Jul 16, 2014 at 12:04 PM, fsgl fsgl@users.sf.net wrote:

Found this
http://sourceforge.net/p/openemr/discussion/202505/thread/ef5baedb.

Missing Calendar
https://sourceforge.net/p/openemr/discussion/202505/thread/923d23e7/?limit=25#b22a

Sent from sourceforge.net because you indicated interest in
OpenEMR / Discussion / Help

To unsubscribe from further messages, please visit
SourceForge.net: Log In to SourceForge.net


Ian Wallace - CCRMC DFM Staff Physician - (c) 303.681.5732

cravaus wrote on Monday, July 21, 2014:

This became a gradually growing tornado of items disappearing from the screen so I took it all off and started over. What I have learned: On a Synology NAS OpenEMR works when loaded into the User/www directory with some minor modifications to the globals.php file (change $web_root = ‘/~[User Name]/openemr’;). It does not work in the web directory or in a virtual host directory.