Blueprint changed by rejon: Whiteboard changed: Could add a method to aiki class or just make a global $messages variable. - $messagelist = array(); or class aiki { - $messagelist = array(); + $messagelist = array(); } or class aiki { - $_messagelist = array(); + $_messagelist = array(); - // have to create mutators though + // have to create mutators though } Then in message.php need to make that final parameter have more options: function message($text,$attribs=NULL, $echo = true) {} or just add all messages to the queue...just don't want an overflow problem if we keep filling this thing infinitely. Since there aren't limits, we could allow something like 128 messages, then after that, pop the oldest off as a precaution. - Sooo, basically everytime one calls: $aiki->message->warning("No clipart's found"); - $aiki->message->error("No file upload", array("class"=>"fatal")); + $aiki->message->error("No file upload", array("class"=>"fatal")); $aiki->message->general("Hi, Roger", array("id"=>"welcome")); - In the function message, would at the end before return set: $aiki->messagelist[] = array('attribs' => $attribs, 'text' => $text, 'fancy' => $cRet, 'uses' => 0); - Roger, what do you think? Too much information? Better idea for this? Other information for a message that might be relevant is date/time and some stack information. But I think better to start small here. + NEXT, need to sort out where and how to display in the code. - NEXT, need to sort out where and how to display in the code. + + ### + + roger, how much of this got resolved with your new code? Jon
-- add message queue system for aiki messages, errors and warnings https://blueprints.launchpad.net/aikiframework/+spec/add-message-queue _______________________________________________ Mailing list: https://launchpad.net/~aikiframework-devel Post to : aikiframework-devel@lists.launchpad.net Unsubscribe : https://launchpad.net/~aikiframework-devel More help : https://help.launchpad.net/ListHelp