Latest (3/16) Ver Windows Install Issues

ideaman911 wrote on Tuesday, March 17, 2009:

I have just done a virgin install in XP which should be little different in Vista.  Much of my 2.9.1 directions is eliminated, so i will quickly provide a simpler setup instructions set.  Some problems still exist which i thought were addressed before.  Jason, if you are listening, please look at these in particular:

a)  I got Parse errors for three lines which can best be described as syntax errors in the $tag starting from lines 173 thru 177 in the …globals.php ad do not understand why the Linux does not show them also.

b)  Similarly, and as addressed now multiple times since 11/29/08 in …/forms.inc to prevent the "COERCIBLE error" which looks to be language related in the Encounters view after a single encounter is entered.  That is a red herring - the syntax has too many arguments.  I simply comment out the $sql . = "order by"  on line 43 and the problem disappears.  Why not, if the order is desired, simply make a single instructional def for $sql, or pre-build the parameters desired via concatenation and then make the call ?

c)  Despite my specific urging to do so, I note that there is still no indication of the encounter date in the Billing view, nor the "Justify" nor "1st Billed" tags I proposed for …/encounters.php  While I realize none of these is REQUIRED to make OpenEMR work, they will save a huge amount of jumping around to find the info for users, and I can see no downside to their inclusion.  Can any of you?  In any case, I will post those new instructions in my Wiki.

Other than that, having only done a cursory review, I like most of the added things like the Patient info in the center of the Title Bar, and the inclusion of most of the "silly" folder adders previously needed, plus the GACL inclusion.  They greatly simplify startup.  And the inclusion of user password definition during the MySQL database creation is long overdue and very welcome for security.

I did note that the “$register_globals” and “$magic_quotes_gpl” still had to be set to “Off” in …/php.ini but wonder why they would be different for Linux, although I recognize they are from the Xampp distribution, which may not be adjustable by OEMR.  There is simply no getting around the need to put the absolute location reference in …/globals.php but I wonder that the State and Country lists have only one entry each, and that the entirely new view for the Admin - Layout - Demographics will require more review to assure our own data will work.  I’ll report on that as soon as I can.

Thanks again, contributors.  I will start using the 3/16/09 release as the working release.

Joe Holzer

bradymiller wrote on Thursday, March 19, 2009:

Joe,

  We now have a new feature where you can download daily snapshots of CVS in zip format. Check out these wiki instructions at step 2 for links to zipped file, file MD5sum, and a timestamp: (I’m aware that need to manually untoggle “read only” permissions in interface/globals.php and library/sqlconf.php files; you’ll know what i mean when go through installation; this will be fixed in future)
http://www.oemr.org/modules/wiwimod/index.php?page=WindowsGenericOpenEmrInstallCvsSnapshot

In response to above (using current OpenEMR cvs version on windows XP with XAMPP version 1.7.0) tried browsers are firefox3 and ie6 (note not ie7):

a) I’m not seeing this error, perhaps these lines were changed in a “bad” editor after getting collected from CVS.

b) I can not reproduce this error. Nothing seen on screen and nothing going to my php, apache, or mysql error logs when I create or list encounters.  What browser you using?

c) In regards to this and other rec. code changes do you have a list anywhere of specific changes you want to make.  I can attempt to get these in (if can get the time) since I can test on both linux and windows rather quickly.

d) Right now our recs for register_globals is off for all environments (security issues and no longer gonna be supported in php6).  Our recs for magic_quotes_gpc is on for production environments (still some escape issues in some of the code) and off for development environments to avoid/fix escape issues (since php6 will no longer support this).  Does your windows environment have problems with magic_quotes_gpc turned on?

As an aside, perhaps its time for you to join the darkside (LINUX). A good way to learn linux in the context of OpenEMR is the developer appliance here (I think of it as an OpenEMR linux development environment with training wheels):
http://www.oemr.org/modules/wiwimod/index.php?page=OpenEmrDeveloperAndTesterVirtualMachine

-Brady

ideaman911 wrote on Thursday, March 19, 2009:

Brady (et al);

Part of the reason Dr Bowen has put up with me for so long is because he, like me, recognizes that most of the world for the forseeable future will be Windows and NOT Linux based.  You are probably correct that I will have to learn the workings of Linux eventually if only to assure I can bridge the team’s efforts to that wider world.  But I see my “niche” as Windows, if for no other reason than the number of you experts in Linux.  Better to be a big fish in a small pond, so to speak :wink:

As to the problems I have noted, there is plenty of anecdotal indication that some things which show up in Windows do not equally do so in Linux, and vice versa.  All the more reason for para 1 above.

I will look at the info you have posted as soon as possible.  But I also have other irons in the fire, so not sure how soon I can respond with full knowledge.  But I do know what I reported above as problems, and you can find repeated queries in the forums about them, which have included people running Linux environments also.  As a novice with them, I am however aware that there are a host of variations to platforms as selected by any one developer, one of the natural consequences of open-source.  And nobody can be expected to be expert in all.  Again, read para 1.

The parse and "COERCIBLE" errors are real and easily repeated in an XP environment by removing the fixes I advise from the as-distributed code.  In the case of the latter, I can see that the intent was to build a sortation into the query.  But it does not WORK that way in the XP environment, which uses the Xampp Apache & MySQL in the xampp-win32-1.4.13.zip distribution, and sees it simply as an extra argument it has no idea how to deal with. 

My changing the php.ini was per the notes I found before I started working with OpenEMR when there were no Windows advisers, so they may be obsolete.  But in the absence of indications otherwise, I presumed they were still required, since that Xampp distribution is the same as before.  Since setting the $magic_quotes_glc off seems to work fine for 2.9.1dev (as it did for 2.9.0), you can see why I noted it.  And the php.ini file itself warns against leaving $register_globals ON for production, so it made sense to change both.

As I noted in the forums, the changes to Encounters.php going from 2.9 to 3.0 are substantial.  But the posting "echo" statement which results in the printing of each encounter date in the resulting table for each patient can be preceded immediately with something like the following, which was the specific code for 2.9.1dev near 274:

                                                                                       
        $just = “”;                           //  Make Justify & Billed tags print beneath encounter date 2/22/09  JCH
        $jcpt = “CPT4”;
       
        $jtmp = sqlQuery("SELECT justify, bill_date, code_type, activity FROM billing WHERE " .
                “pid = ‘$pid’ AND code_type = ‘$jcpt’ AND activity AND encounter = '” . $iter[‘encounter’] . “’”);   
                                       
                        if (substr($jtmp[‘code_type’], 0, 3) == “CPT” && !$jtmp[‘justify’]) {
                            $just = ‘<br>’ . “Justify” . ‘<br><br>’; }
                        if (substr($jtmp[‘code_type’], 0, 3) == “CPT” && strlen($jtmp[‘bill_date’]    > 3)) {
                            $just = ‘<br>’ . “1st Billed” . ‘<br>’ . substr($jtmp[‘bill_date’], 0, 10) . ‘<br><br>’; }
                                                                                                                   
    echo “<td valign=‘top’>$linkbeg$raw_encounter_date$just$linkend</td>\n”; //  Added $just which is tag 2/22/09  JCH

I am pretty certain the "echo" statement in 3.0 has removed the $linkbeg & $linkend, but is otherwise pretty similar.  So, absent some significant logic change, this should work there as well with the fix to add the $just as a concatenate to the current $raw_encounter_date.

As to the addition of the encounter date in the Billing listing, the code below is again for 2.9.1dev, but I expect it would be very similar in 3.0, although I have not yet had a chance to get into the code for it.

In …/billing/billing_report.php does not display encounter date as distributed.  So modified to look like the following from near line 524 to display encounter date in "To Encounter" button, and reduce buttons size to offset added size for date

$ptname = $name[‘fname’] . " " . $name[‘lname’];
      $raw_encounter_date = date(“Y-m-d”, strtotime($iter[‘enc_date’]));
           
            //  Add Encounter Date to display with “To Encounter” button 2/17/09  JCH
      $lhtml .= “&nbsp;<span class=bold><font color=’$namecolor’>$ptname” .
        “</font></span><span class=small>&nbsp;(” . $iter[‘enc_pid’] . “-” .
        $iter[‘enc_encounter’] . “)</span>”;
               
            //  Not sure why the next section seems to do nothing except post “To Encounter” button, but added encounter date 2/17/09  JCH
      $lhtml .= "&nbsp;&nbsp;&nbsp;<a class=&quot;link_submit&quot; " .
        “href=&quot;javascript:window.toencounter(” . $iter[‘enc_pid’] .
        “,’” . addslashes($name[‘pubpid’]) .
        “’,’” . addslashes($ptname) . “’,” . $iter[‘enc_encounter’] .
        “,’$raw_encounter_date’)&quot;>[To&nbsp;Enctr – $raw_encounter_date]</a>”;
               
            //  Changed “To xxx” buttons to allow room for encounter date display 2/17/09  JCH
      $lhtml .= "&nbsp;&nbsp;&nbsp;<a class=&quot;link_submit&quot; " .
        “href=&quot;javascript:window.topatient(” . $iter[‘enc_pid’] .
        “)&quot;>[To&nbsp;Dems]</a>”;
               

As distributed, CMS 1500 forms and X12 will generate without a Justify, which means without the clinician’s “release”.  But we need to list them so we can see when they need the justify done.  You can modify near line 704 in …/billing/billing_report.php (also modified near 201 to indicate need for selecting “Fit-To-Page” when printing 1500 unless you change the margin values from 30 to 5 starting near line 119 in …/classes/class.ezpdf.php) to include ‘&& strlen($justify) > 2’ within the conditional test so that only encounters with justifications done will be billable.  That should reduce returns & errors.  However, it was found that those with Copays entered via the Fee Sheet would not bill due to spelling of COPAY and CPT, neither of which could be changed due to logical considerations elsewhere.

At worst with the addition of the code below inserted between the current if statement and the else statement near line 712 in …/billing/billing_report.php only those with copays from the fee sheet will potentially be billed before they have been justified, which is still better than the as-distributed situation:

else if ($iter[‘id’] && $last_encounter_id != $this_encounter_id && $iter[‘code_type’] == “COPAY”) {
      $tmpbpr = $iter[‘bill_process’];
      if ($tmpbpr == ‘0’ && $iter[‘billed’]) $tmpbpr = ‘2’;    
      $rhtml .= “<td><input type=‘checkbox’ value=’$tmpbpr’ name='claims[” . $this_encounter_id . “][bill]’ onclick=‘set_button_states()’>&nbsp;</td>\n”;
    }

My final input (for now, anyway :wink: is regards the calendar.  I still prefer the “fancy” version vs the Outlook version, because of immediacy of information, especially with the “Month” view.  I note that Jason fixed the display of only a Pt DOB, but otherwise left it pretty much as-is.  I would suggest, and plan to use in all versions myself to allow for multiple service locations, but with a single billing location easily shown (I discussed this with Rod Roark, and disagree with the feasibility of using different facilities because of text match problems, especially at Medicare), To add House Call and other service locations to calendar and to encounter drop-down to allow substitution of POS in claims, add them as New Categories in Admin - Calendar as House Call color #FFFF99 (for example) duration 1 Hr (3600) and change Office Visit to 1 Hr if desired (3600), and add TC Conference color Red IN THAT ORDER and verify with BROWSE in openemr_postcalendar_categories database in Admin to verify House Call has pc_catid = 12 also - these will display in Encounter view/new as drop-down selections.  Then add conditionals in …/library/claim.class.php at Function for POS near line 527, and do same for SNF, or other service locations as appropriate to enter correct code override.  Logic shown allows select substitution for claim of whatever form_encounter[‘pc_catid’] is in table with whatever POS code is required for proper claim submission, to replace POS code defined for facility as default.  Codes listing can be found in …/library/classes/POSRef.class.php and details are available at CMS website.

And on the calendar note, having only a start time and patient name (if available) with all the available space seems under-engineered.  My client wants to have at least the "comments" able to display, especially for other than patient appointments, so she can know WHY they are and WHAT they are.  "Out" is insufficient, and adding the comments would seem to be a minor change.  Is that possible?  Could it be switchable via the globals.php, so it would not be required (some would probably want it kept limited per access rules)?

Thanks for the soapbox

Joe Holzer

bradymiller wrote on Thursday, March 19, 2009:

hey,
  I also need some time to digest this.  My big question for now is why you are using xampp-win32-1.4.13.zip, this version is from 2005?  Why not use a more recent version; 1.7 was released last December and uses php5.  Not seeing reason to start an openemr/xampp release with such an old package.
-Brady

cfapress wrote on Friday, March 20, 2009:

Hi Joe,

I’ll chime in about the calendar stuff.

The Outlook style calendar is designed for people running OpenEMR at 800x600 or 1024x768. Thus the minimalist view. You mention there a lot of wasted space, but try viewing three or four practitioners at once. You’ll find the calendar to become very crowded.

Perhaps I could write some logic into the code so that when you’re viewing multiple practitioners that the extra detail goes away. Thus making us of the calendar space when it’s available.

You lost me when you started to talk about the different event categories. Those are user definable in the Admin->Calendar interface and every practice is different. For example, in our Agency we’ll be using a category called ‘Med Check’ because we have psychiatrists and that’s what they call a patient’s visit.

I’ve considered adding the event ‘comments’ to the mouse-over in the Outlook calendar. The trouble you’ll run into is that event comments could be a bit wordy. For an example of horrible use of mouse-over tooltips take a look at the encounter summary that appears in the bottom part of a patient’s screen. Just hover your mouse over a form in an existing encounter. My favorite is the ‘Review of Systems’ that makes a tooltip bigger than the frame it’s contained within. Hah!

The IN and OUT events are a special case. They show the comments on the calendar. Let me explain why. In our Agency we have practitioners going between different facilities. So when they are IN it’s not clear where they are IN. By entering the facility name in the comments field of the IN/OUT events you can see exactly where the practitioner is for that time. This was something I built into the code specifically for our Agency that has now slipped into the main code. It doesn’t seem to cause much harm because most people don’t put comments into the IN/OUT events. But now that I’ve brought it up perhaps people will take advantage of it.

Jason

bradymiller wrote on Friday, March 20, 2009:

Joe,

  If your indeed using version xampp-win32-1.4.13.zip of XAMPP (released in 4/2005), then your using MySQL version 4.1.11 .  Some of you errors will probably disappear if you move to a current release.  Is there any specific reason your using such an old package?

-Brady