From: Phil D. <ph...@du...> - 2004-05-02 07:30:20
|
Hi jesse, Still working through it all ... in the statment below ... $Item->move_item($StkMoveNo, true); where is the move_item method I expected to be in the DefineCartClass.inc - can't see it anywhere was looking forward to seeing how this was processed. (sicko!) Your MiscFunctions script -I do have some reservations as I guess you would expect. I reckon one function would be fine - even then have a question about whether its worth it - for the PrintMessage stuff but you have 10 separate functions!! My weird criteria for functions/includes is based on the fact that using a function or include requires the reader of the code to look elsewhere to figure out what's going on - so there is a cost in excessive use ... it is labour intensive for someone else to read/understand the code! Against that I really do understand that there are some big pluses for maintenance and reducing code/typing where there are heaps of possibilities for re-use. Where the latter clearly outweigh the former .... lets go, otherwise lets not!! So if we are replacing ... include("includes/footer.inc"); exit; with an endWEBERP() function - I can't see the point. or 10 PrnMsg functions to replace an echo statement? .... Nah! On the other hand your variable initation stuff is clearly a significant saving of typing which appears again and again - its a sitter I should have seen before. Same with the DB_query stuff - great! I hope this makes sense and that my eccentricities are not too much to live with! Phil |