drbowen wrote on Monday, October 17, 2005:
“I understand your points. I have not been through the whole system yet, but so far about 75 - 90% of the files in the directories I’ve been through have been changed. That means that nearly every file need changing in the same way as sql-ledger uses the same text-array for every single file in the system.”
"But offcause for the single practitioner in the future it will only be needed to change the file lang.php in order to decide what language to use. "
"There are a few things to decide, that might be important for first of all the developers:"
"1) Using one large or many small files?
- I tend to think many small files are better. Especially since one in an easy way can add more modules and let the needed language-files come with the module in an easy way. "
Personally, I think the use of smaller files will speed up operation. You may need to make you best judgment here.
"2) Using arrays or single variables.
- I don’t know enough about php-coding to know if this makes any difference for memory-usage or speed. I must say that I am not sure that it even makes a difference using constants or variables in php. (In c-code it would be better to use constants since these steal less memory and makes faster programs but in an interpreted language like php I don’t know) "
Constants are generally faster but are more difficult to maintain. Arrays will require more memory but will be easier to maintain. PHP has always been popular because of its ease of use. Taking the easy way is the traditional PHP approach. Again, this is likely going to be your preference.
"3) Naming of the variables.
- So far I mostly have used simple naming in order to not get conflicts with existing variables and make fast programming. But the readability is more difficult using this naming. It might be worth working out a better naming but it will take more resources too. "
I suspect in the long run this area will not need much maintenance. What I have down with my naming is to start all similar variables with a common prefix and then follow with an individual name. In my bronchitis form all variables start with the name of the table that containes the bronchitis information, such as:
bronchitis_cough
bronchitis_murmur
etc.
Would there be any benefit to have a static table that has the name of the variables in one column and a fuller discription in a second column?
Sam Bowen