[Hastymail-cvs] SF.net SVN: hastymail: [498] trunk/hastymail2
Brought to you by:
sailfrog,
slushpupie
From: <sai...@us...> - 2008-06-02 04:20:27
|
Revision: 498 http://hastymail.svn.sourceforge.net/hastymail/?rev=498&view=rev Author: sailfrog Date: 2008-06-01 21:20:24 -0700 (Sun, 01 Jun 2008) Log Message: ----------- make the application pages array in the index file work Modified Paths: -------------- trunk/hastymail2/index.php trunk/hastymail2/lib/url_action_class.php Modified: trunk/hastymail2/index.php =================================================================== --- trunk/hastymail2/index.php 2008-06-01 18:58:28 UTC (rev 497) +++ trunk/hastymail2/index.php 2008-06-02 04:20:24 UTC (rev 498) @@ -139,9 +139,9 @@ /* main application pages */ $app_pages = array( - 'login', 'logout', 'about', 'new', 'inline_image', - 'contacts', 'profile', 'options', 'compose', 'folders', - 'search', 'thread_view', 'mailbox', 'message' + 'login', 'logout', 'new', 'inline_image', + 'contacts', 'profile', 'options', 'compose', 'folders', + 'search', 'thread_view', 'mailbox', 'message', 'about' ); /* sort types for client side sorting */ Modified: trunk/hastymail2/lib/url_action_class.php =================================================================== --- trunk/hastymail2/lib/url_action_class.php 2008-06-01 18:58:28 UTC (rev 497) +++ trunk/hastymail2/lib/url_action_class.php 2008-06-02 04:20:24 UTC (rev 498) @@ -84,6 +84,7 @@ global $conf; global $tools; global $imap; + global $app_pages; $f = $conf['filesystem_delim']; if (isset($get['rs'])) { return; @@ -94,23 +95,11 @@ $user->page_data['url_mailbox'] = urlencode($get['mailbox']); } if (isset($get['page'])) { - switch ($get['page']) { - case 'profile': - case 'login': - case 'mailbox': - case 'thread_view': - case 'message': - case 'search': - case 'folders': - case 'compose': - case 'options': - case 'contacts': - case 'inline_image': - case 'new': - case 'about': + switch (true) { + case in_array($get['page'], $app_pages) && method_exists($this, 'url_action_'.$get['page']): $this->{'url_action_'.$get['page']}($get); break; - case 'logout': + case $get['page'] == 'logout': $this->url_action_login($get); break; default: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |