[Customisation Database Commits] r1071 - /misc/modules/ /misc/modules/includes/ /misc/modules/includes/mcp/ /misc/modules/includes/mcp/info/ /misc/modules/language/ /misc/modules/language/en/ /misc/modules/language/en/mods/ /misc/modules/styles/ /misc/modules/styles/prosilver/ /misc/modules/styles/prosilver/template/ /misc/modules/styles/prosilver/template/manage/ /trunk/includes/ /trunk/language/en/mods/ /trunk/styles/ /trunk/titania/docs/

Nathan Guse exreaction at phpbb.com
Sat Apr 17 06:10:37 BST 2010


Author: exreaction
Date: Sat Apr 17 06:10:36 2010
New Revision: 1071

Log:
Thinking about this some more...the modules should be in misc instead of in the trunk as they are not required and require some configuration of their own.

Added:
    misc/modules/
    misc/modules/includes/
    misc/modules/includes/mcp/
    misc/modules/includes/mcp/info/
    misc/modules/includes/mcp/info/mcp_titania.php   (with props)
    misc/modules/includes/mcp/mcp_titania.php   (with props)
    misc/modules/language/
    misc/modules/language/en/
    misc/modules/language/en/mods/
    misc/modules/language/en/mods/info_mcp_titania.php   (with props)
    misc/modules/styles/
    misc/modules/styles/prosilver/
    misc/modules/styles/prosilver/template/
    misc/modules/styles/prosilver/template/manage/
    misc/modules/styles/prosilver/template/manage/attention.html
    misc/modules/styles/prosilver/template/manage/attention_details.html
Removed:
    trunk/includes/
    trunk/language/en/mods/info_mcp_titania.php
    trunk/styles/
Modified:
    trunk/titania/docs/Installation and Requirements.txt

Added: misc/modules/includes/mcp/info/mcp_titania.php
==============================================================================
*** misc/modules/includes/mcp/info/mcp_titania.php (added)
--- misc/modules/includes/mcp/info/mcp_titania.php Sat Apr 17 06:10:36 2010
***************
*** 0 ****
--- 1,35 ----
+ <?php
+ /**
+ *
+ * @package Titania
+ * @version $Id$
+ * @copyright (c) 2008 phpBB Customisation Database Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
+ *
+ */
+ 
+ /**
+ * @package module_install
+ */
+ class mcp_titania_info
+ {
+ 	function module()
+ 	{
+ 		return array(
+ 			'filename'	=> 'mcp_titania',
+ 			'title'		=> 'MCP_TITANIA',
+ 			'version'	=> '1.0.0',
+ 			'modes'		=> array(
+ 				'attention'			=> array('title' => 'MCP_TITANIA_ATTENTION', 'auth' => 'acl_u_titania_mod_author_mod || acl_u_titania_mod_contrib_mod || acl_u_titania_mod_faq_mod || acl_u_titania_mod_post_mod', 'cat' => array('MCP_MAIN')),
+ 			),
+ 		);
+ 	}
+ 
+ 	function install()
+ 	{
+ 	}
+ 
+ 	function uninstall()
+ 	{
+ 	}
+ }
\ No newline at end of file

Propchange: misc/modules/includes/mcp/info/mcp_titania.php
------------------------------------------------------------------------------
    svn:keywords = Revision Author Date Id

Added: misc/modules/includes/mcp/mcp_titania.php
==============================================================================
*** misc/modules/includes/mcp/mcp_titania.php (added)
--- misc/modules/includes/mcp/mcp_titania.php Sat Apr 17 06:10:36 2010
***************
*** 0 ****
--- 1,99 ----
+ <?php
+ /**
+ *
+ * @package Titania
+ * @version $Id$
+ * @copyright (c) 2008 phpBB Customisation Database Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
+ *
+ */
+ 
+ global $phpbb_root_path;
+ 
+ /**
+ * Configuration needed!
+ *
+ * Set the titania root path here
+ */
+ define('TITANIA_ROOT', $phpbb_root_path . '../titania/');
+ 
+ /**
+ * @ignore
+ */
+ if (!defined('IN_PHPBB'))
+ {
+ 	exit;
+ }
+ 
+ /**
+ * mcp_titania
+ * Handling the titania stuff (proxy for some stuff in titania/manage/
+ */
+ class mcp_titania
+ {
+ 	var $p_master;
+ 	var $u_action;
+ 
+ 	function mcp_titania(&$p_master)
+ 	{
+ 		$this->p_master = &$p_master;
+ 	}
+ 
+ 	function main($id, $mode)
+ 	{
+ 		global $phpbb_root_path;
+ 
+ 		define('PHPBB_INCLUDED', true);
+ 		define('USE_PHPBB_TEMPLATE', true);
+ 
+ 		define('IN_TITANIA', true);
+ 		if (!defined('PHP_EXT')) define('PHP_EXT', substr(strrchr(__FILE__, '.'), 1));
+ 		require TITANIA_ROOT . 'common.' . PHP_EXT;
+ 
+ 		// Need a few hacks to be used from within phpBB
+ 		titania_url::decode_url(titania::$config->phpbb_script_path);
+ 		titania::$hook->register(array('titania_url', 'build_url'), 'titania_outside_build_url', 'standalone');
+ 		titania::$hook->register(array('titania_url', 'append_url'), 'titania_outside_build_url', 'standalone');
+ 		titania::$hook->register(array('titania', 'page_header'), 'titania_outside_page_header', 'standalone');
+ 		titania::$hook->register(array('titania', 'page_footer'), 'titania_outside_page_footer', 'standalone');
+ 		titania::$hook->register('titania_generate_text_for_display', 'titania_outside_generate_text_for_display', 'standalone');
+ 
+ 		titania::add_lang('manage');
+ 
+ 		$this->p_master->assign_tpl_vars(phpbb::append_sid('mcp'));
+ 
+ 		phpbb::$template->assign_vars(array(
+ 			'L_TITLE'		=> phpbb::$user->lang['ATTENTION'],
+ 			'L_EXPLAIN'		=> '',
+ 		));
+ 
+ 		include(TITANIA_ROOT . 'manage/attention.' . PHP_EXT);
+ 	}
+ }
+ 
+ function titania_outside_generate_text_for_display(&$hook, $text, $uid, $bitfield, $flags)
+ {
+ 	return generate_text_for_display($text, $uid, $bitfield, $flags);
+ }
+ 
+ function titania_outside_build_url(&$hook, $base, $params = array())
+ {
+ 	if ($base == 'manage/attention' || $base == titania_url::$current_page || strpos($base, 'mcp.' . PHP_EXT))
+ 	{
+ 		return phpbb::append_sid('mcp', array_merge(array('i' => 'titania', 'mode' => 'attention'), $params));
+ 	}
+ }
+ 
+ function titania_outside_page_header(&$hook, $page_title)
+ {
+ 	page_header($page_title);
+ 
+ 	return true;
+ }
+ 
+ function titania_outside_page_footer(&$hook, $run_cron)
+ {
+ 	page_footer(false);
+ 
+ 	return true;
+ }

Propchange: misc/modules/includes/mcp/mcp_titania.php
------------------------------------------------------------------------------
    svn:keywords = Revision Author Date Id

Added: misc/modules/language/en/mods/info_mcp_titania.php
==============================================================================
*** misc/modules/language/en/mods/info_mcp_titania.php (added)
--- misc/modules/language/en/mods/info_mcp_titania.php Sat Apr 17 06:10:36 2010
***************
*** 0 ****
--- 1,31 ----
+ <?php
+ /**
+ * titania mcp language [English]
+ *
+ * @package language
+ * @version $Id$
+ * @copyright (c) 2008 phpBB Customisation Database Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
+ */
+ 
+ /**
+ * @ignore
+ */
+ if (!defined('IN_PHPBB'))
+ {
+ 	exit;
+ }
+ 
+ // Create the lang array if it does not already exist
+ if (empty($lang) || !is_array($lang))
+ {
+ 	$lang = array();
+ }
+ 
+ // Merge the following language entries into the lang array
+ $lang = array_merge($lang, array(
+ 	'MCP_TITANIA'				=> 'Titania',
+ 	'MCP_TITANIA_ATTENTION'		=> 'Titania Attention',
+ ));
+ 
+ ?>
\ No newline at end of file

Propchange: misc/modules/language/en/mods/info_mcp_titania.php
------------------------------------------------------------------------------
    svn:keywords = Revision Author Date Id

Added: misc/modules/styles/prosilver/template/manage/attention.html
==============================================================================
*** misc/modules/styles/prosilver/template/manage/attention.html (added)
--- misc/modules/styles/prosilver/template/manage/attention.html Sat Apr 17 06:10:36 2010
***************
*** 0 ****
--- 1,82 ----
+ <!-- INCLUDE mcp_header.html -->
+ 
+ <form id="mcp" method="post" action="{S_ACTION}">
+ 
+ <h2>{L_TITLE}</h2>
+ 
+ <div class="panel">
+ 	<div class="inner"><span class="corners-top"><span></span></span>
+ 
+ 	<p>{L_EXPLAIN}</p>
+ 
+ 	<!-- IF .attention -->
+ 		<ul class="linklist">
+ 			<li class="rightside pagination">
+ 				<!-- IF TOTAL_RESULTS -->{TOTAL_RESULTS}<!-- ENDIF -->
+ 				<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF -->
+ 			</li>
+ 		</ul>
+ 		<ul class="topiclist">
+ 			<li class="header">
+ 				<dl>
+ 					<dt>{L_VIEW_DETAILS}</dt>
+ 					<dd class="moderation"><span>{L_REPORTER}</span></dd>
+ 					<!--<dd class="mark">{L_MARK}</dd>-->
+ 				</dl>
+ 			</li>
+ 		</ul>
+ 		<ul class="topiclist cplist">
+ 
+ 		<!-- BEGIN attention -->
+ 			<li class="row<!-- IF attention.S_CLOSED --> bg3<!-- ELSEIF attention.S_ROW_COUNT is odd --> bg1<!-- ELSE --> bg2<!-- ENDIF -->">
+ 				<dl>
+ 					<dt>
+ 						<a href="{attention.U_VIEW_DETAILS}" class="topictitle">{attention.ATTENTION_TITLE}</a><br />
+ 						<span>{L_POSTED} {L_POST_BY_AUTHOR} {attention.USER_FULL} &raquo; {attention.ATTENTION_POST_TIME}</span>
+ 					</dt>
+ 					<dd class="moderation">
+ 						<span>{attention.REPORTER_USER_FULL} &laquo; {attention.ATTENTION_TIME}</span>
+ 					</dd>
+ 					<!--<dd class="mark"><input type="checkbox" name="id_list[]" value="{attention.ATTENTION_ID}" /></dd>-->
+ 				</dl>
+ 			</li>
+ 		<!-- END attention -->
+ 		</ul>
+ 
+ 		<fieldset class="display-options">
+ 			<!-- IF NEXT_PAGE --><a href="{NEXT_PAGE}" class="right-box {S_CONTENT_FLOW_END}">{L_NEXT}</a><!-- ENDIF -->
+ 			<!-- IF PREVIOUS_PAGE --><a href="{PREVIOUS_PAGE}" class="left-box {S_CONTENT_FLOW_BEGIN}">{L_PREVIOUS}</a><!-- ENDIF -->
+ 			<!-- IF S_SELECT_SORT_DAYS -->
+ 				<label>{L_DISPLAY_POSTS}: {S_SELECT_SORT_DAYS}</label>
+ 				<label>{L_SORT_BY} {S_SELECT_SORT_KEY}</label><label>{S_SELECT_SORT_DIR}</label>
+ 			<!-- ENDIF -->
+ 			<input type="checkbox" name="open" id="open"<!-- IF S_OPEN_CHECKED --> checked="checked"<!-- ENDIF -->> <label for="open">{L_OPEN_ITEMS}</label> &nbsp;
+ 			<input type="checkbox" name="closed" id="closed"<!-- IF S_CLOSED_CHECKED --> checked="checked"<!-- ENDIF -->> <label for="closed">{L_CLOSED_ITEMS}</label>
+ 			<input type="submit" name="sort" value="{L_GO}" class="button2" />
+ 		</fieldset>
+ 		<hr />
+ 		<ul class="linklist">
+ 			<li class="rightside pagination">
+ 				<!-- IF TOTAL_RESULTS -->{TOTAL_RESULTS}<!-- ENDIF -->
+ 				<!-- IF PAGE_NUMBER --><!-- IF PAGINATION --> &bull; <a href="#" onclick="jumpto(); return false;" title="{L_JUMP_TO_PAGE}">{PAGE_NUMBER}</a> &bull; <span>{PAGINATION}</span><!-- ELSE --> &bull; {PAGE_NUMBER}<!-- ENDIF --><!-- ENDIF -->
+ 			</li>
+ 		</ul>
+ 
+ 	<!-- ELSE -->
+ 		<p><strong>{L_NO_REPORTS}</strong></p>
+ 	<!-- ENDIF -->
+ 
+ <!--
+ <!-- IF .attention -->
+ 	<fieldset class="display-actions">
+ 		<!-- IF not S_CLOSED -->&nbsp;<input class="button1" type="submit" name="close" value="{L_CLOSE_REPORTS}" /><!-- ENDIF -->
+ 		<div><a href="#" onclick="marklist('mcp', 'report_id_list', true); return false;">{L_MARK_ALL}</a> :: <a href="#" onclick="marklist('mcp', 'report_id_list', false); return false;">{L_UNMARK_ALL}</a></div>
+ 	</fieldset>
+ <!-- ENDIF -->
+ -->
+ </form>
+ 
+ 	<span class="corners-bottom"><span></span></span></div>
+ </div>
+ 
+ <!-- INCLUDE mcp_footer.html -->
\ No newline at end of file

Added: misc/modules/styles/prosilver/template/manage/attention_details.html
==============================================================================
*** misc/modules/styles/prosilver/template/manage/attention_details.html (added)
--- misc/modules/styles/prosilver/template/manage/attention_details.html Sat Apr 17 06:10:36 2010
***************
*** 0 ****
--- 1,102 ----
+ <!-- INCLUDE mcp_header.html -->
+ 
+ <!-- BEGIN attention -->
+ <div id="report" class="panel">
+ 	<div class="inner"><span class="corners-top"><span></span></span>
+ 
+ 	<div class="postbody">
+ 		<h3>{attention.ATTENTION_REASON}</h3>
+ 		<p class="author">{L_POST_BY_AUTHOR} {attention.REPORTER_USER_FULL} &laquo; {attention.ATTENTION_TIME}</p>
+ 		<div class="content">
+ 			{attention.ATTENTION_DESCRIPTION}
+ 		</div>
+ 
+ 		<!-- IF attention.S_UNAPPROVED -->
+ 			<form method="post" id="approve" action="{S_ACTION}">
+ 				<p class="rules">
+ 					<input class="button1" type="submit" value="{L_APPROVE}" name="approve" /> &nbsp;
+ 					<input class="button2" type="submit" value="{L_DISAPPROVE}" name="disapprove" />
+ 					{S_FORM_TOKEN}
+ 				</p>
+ 			</form>
+ 		<!-- ENDIF -->
+ 
+ 			<!-- IF attention.S_REPORTED -->
+ 			<form method="post" id="reported" action="{S_ACTION}">
+ 				<p class="rules">
+ 					<input class="button1" type="submit" value="{L_CLOSE_REPORT}" name="close" />
+ 					{S_FORM_TOKEN}
+ 				</p>
+ 			</form>
+ 		<!-- ENDIF -->
+ 	</div>
+ 
+ 	<span class="corners-bottom"><span></span></span></div>
+ </div>
+ <!-- END attention -->
+ 
+ <div class="panel">
+ 	<div class="inner"><span class="corners-top"><span></span></span>
+ 
+ 	<div class="postbody">
+ 		<!-- IF U_EDIT -->
+ 		<ul class="profile-icons">
+ 			<li class="edit-icon"><a href="{U_EDIT}" title="{L_EDIT_POST}"><span>{L_EDIT_POST}</span></a></li>
+ 		</ul>
+ 		<!-- ENDIF -->
+ 
+ 		<h3><a href="{U_VIEW}">{POST_SUBJECT}</a></h3>
+ 		<p class="author">{MINI_POST_IMG} {L_POSTED} {L_POST_BY_AUTHOR} {POSTER_USER_FULL} &raquo; {POST_DATE}</p>
+ 
+ 		<div class="content">
+ 			{POST_TEXT}
+ 		</div>
+ 
+ 		<!-- IF .attachment -->
+ 			<dl class="attachbox">
+ 				<dt>{L_ATTACHMENTS}</dt>
+ 				<!-- BEGIN attachment -->
+ 					<dd>{attachment.DISPLAY_ATTACHMENT}</dd>
+ 				<!-- END attachment -->
+ 			</dl>
+ 		<!-- ENDIF -->
+ 
+ 		<!-- IF EDITED_MESSAGE or DELETED_MESSAGE -->
+ 			<div class="notice">
+ 				{EDITED_MESSAGE}<!-- IF EDITED_MESSAGE and DELETED_MESSAGE --><br /><!-- ENDIF -->{DELETED_MESSAGE}
+ 				<!-- IF POST_EDIT_REASON --><br /><strong>{L_REASON}:</strong> <em>{POST_EDIT_REASON}</em><!-- ENDIF -->
+ 			</div>
+ 		<!-- ENDIF -->
+ 	</div>
+ 
+ 	<span class="corners-bottom"><span></span></span></div>
+ </div>
+ 
+ <!-- IF attention_closed -->
+ <h3>{L_CLOSED_ITEMS}</h3>
+ <!-- ENDIF -->
+ <!-- BEGIN attention_closed -->
+ <div id="attention">
+ 	<h4>{attention_closed.ATTENTION_REASON}</h4>
+ 	<p class="author">{L_POST_BY_AUTHOR} {attention_closed.REPORTER_USER_FULL} &laquo; {attention_closed.ATTENTION_TIME}</p>
+ 	<table>
+ 		<tbody>
+ 		<tr>
+ 			<td class="bg2"><strong>{L_CLOSED_BY}:</strong></td>
+ 			<td class="bg1">{attention_closed.CLOSER_USER_FULL}</td>
+ 		</tr>
+ 		<tr>
+ 			<td class="bg2"><strong>{L_DATE_CLOSED}:</strong></td>
+ 			<td class="bg1">{attention_closed.ATTENTION_CLOSE_TIME}</td>
+ 		</tr>
+ 		</tbody>
+ 	</table>
+ 	<div class="content">
+ 		<blockquote><div><cite>{attention_closed.CLOSER_USER_FULL} {L_WROTE}:</cite>{attention_closed.ATTENTION_DESCRIPTION}</div></blockquote>
+ 	</div>
+ 	<!-- IF not attention_closed.S_LAST_ROW --><hr class="dashed" /><!-- ENDIF -->
+ </div>
+ <!-- END attention_closed -->
+ 
+ 
+ <!-- INCLUDE mcp_footer.html -->
\ No newline at end of file

Removed: trunk/language/en/mods/info_mcp_titania.php
==============================================================================
*** trunk/language/en/mods/info_mcp_titania.php (original)
--- trunk/language/en/mods/info_mcp_titania.php (removed)
***************
*** 1,31 ****
- <?php
- /**
- * titania mcp language [English]
- *
- * @package language
- * @version $Id$
- * @copyright (c) 2008 phpBB Customisation Database Team
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- */
- 
- /**
- * @ignore
- */
- if (!defined('IN_PHPBB'))
- {
- 	exit;
- }
- 
- // Create the lang array if it does not already exist
- if (empty($lang) || !is_array($lang))
- {
- 	$lang = array();
- }
- 
- // Merge the following language entries into the lang array
- $lang = array_merge($lang, array(
- 	'MCP_TITANIA'				=> 'Titania',
- 	'MCP_TITANIA_ATTENTION'		=> 'Titania Attention',
- ));
- 
- ?>
\ No newline at end of file
--- 0 ----

Modified: trunk/titania/docs/Installation and Requirements.txt
==============================================================================
*** trunk/titania/docs/Installation and Requirements.txt (original)
--- trunk/titania/docs/Installation and Requirements.txt Sat Apr 17 06:10:36 2010
***************
*** 13,16 ****
  	3. Make the files/ and store/search/ directories writable by the server
  	4. Copy titania/config.example.php to config.php; edit settings as required
  	5. Visit any page in titania/ in your browser and run the installer script (you will be redirected to it)
! 	6. Done!
\ No newline at end of file
--- 13,22 ----
  	3. Make the files/ and store/search/ directories writable by the server
  	4. Copy titania/config.example.php to config.php; edit settings as required
  	5. Visit any page in titania/ in your browser and run the installer script (you will be redirected to it)
! 	6. Done!
! 
! How to install the modules for phpBB:
! 	1. Copy the misc/modules/ to your phpBB root path
! 	2. Open the includes/(module type)/(module_type)_titania.php file
! 	3. Change define('TITANIA_ROOT', $phpbb_root_path . '../customisation/'); to point correctly to the titania root.
! 	4. Add the modules through the ACP Module Management
\ No newline at end of file




More information about the customisationdb-commits mailing list