deschel wrote on Friday, August 16, 2013:
Hi Robert,
I am working on an improved demographics webpage. I too am not crazy about the current interface in OpenEMR and played with incorporating a different interface in the webpage. I saw twitter bootstrap and this inspired my interface. Like you, I wanted to change the tabs appearance. I realized that the visual interface is mostly in the bootstrap.css file. I studied this and realized that there was only a small part of this that really impacted what I was doing. Too make it easier to incorporate my themes into OpenEMR I copied the relevant css files from bootstrap to modify one of the OpenEMR theme files (style_oemr.css) and of course I renamed it. This css file was placed in the directory /interface/themes (with the other them files), and made it so that you can select this new theme file in globals. Any changes in this theme file were easily applied to all of OpenEMR. I not only copied what was in bootstrap, but I also made changes to the css code that I took from bootstrap to improve the look even more.
I suggest that you take this approach, because it will make your life soooo much easier, and also allow you to develop the interface that you take from the bootstrap.css file. There are some cool interface themes there, but there are some that could be customized/improved.
I am basically providing an in depth rationale and how to to what Brady hinted at in his previous posts to this discussion.
Since only your theme would use bootstrap.css and not anyone else’s, you don’t want to include bootstrap.css on every page of openemr. You want to only include it if your theme is being used. It sounds like your approach would include it everywhere.
If you look in the code of openemr the css file of the theme is called in the php code with:
$css_header is the path to the theme selected in globals. I guess that you can change this in every page that does this and call your “global style header”.
However, for the css aspect of your interface overhaul, it would be easier, more compatible with the existing OpenEMR code, and more customizable to create a css file that is derivative of style_oemr.css, incorporating the css code from bootstrap.css into this derivative. This way you don’t need to change the above code.
In your interface overhaul, you will probably only need to use a small subset of the css definitions in bootstrap.css. Therefore, you don’t really need to include the file as a whole.
Too bad, you can’t use “include” in css files. It would make life so much easier if you could.
I really do like what you are trying to do. I already did a little of what you are trying to do as a side track to my project. I like a lot of the css themes in twitter bootstrap.
Please consider my suggestion. Also, I’d like to hear from Brady to see if this approach is consistent with what he is suggesting.
David Eschelbacher MD