docs/tmp/*
config.mk
*~
+*.exe
+*.dmg
*.zip
*.gz
*.bz2
</Files>
RewriteEngine on
-RewriteCond $1 !^(index\.php|img|css|js|data|robots\.txt)
+RewriteCond $1 !^(index\.php|img|css|js|data|download|robots\.txt)
RewriteRule ^(.*)$ index.php/$1 [L]
--- /dev/null
+<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
+
+/**
+ * Article Engine Configurations which include libraries and helpers to be
+ * loaded for each article.
+ */
+
+// Examples
+$config['article_$method_helpers'] = array();
+$config['article_$method_libraries'] = array();
\ No newline at end of file
$route['watch/([\d]+)/?'] = "video/watch/$1";
$route['watch/([\d]+)/(.+)'] = "video/watch/$1/$2";
// Article pages
+$route['install-plugins'] = 'article/install-plugins';
$route['about'] = 'article/about';
$route['help'] = 'article/help';
-$route['install-plugins'] = 'article/install-plugins';
+$route['contact'] = 'article/contact';
* Their content depends on the language.
*
* The page views are located in "application/views/article/$language/$method".
- * Article's name can be set in language file 'article_lang.php' by using an
- * entry named "article_$method". If not present "$method" is used as a name.
- * Article meta description has the entry "article_$method_description"
*
* @category Controller
* @author Călin-Andrei Burloiu
*/
class Article extends Article_Controller {
+
+ public function __construct()
+ {
+ parent::__construct();
+ }
public function _remap($method, $params = array())
- {
+ {
+ parent::_remap($method, $params);
+
// **
// ** DATA
// **
- $this->lang->load('article');
- $title = $this->lang->line("article_$method");
- if ($title == FALSE)
- $title = $method;
- $descr = $this->lang->line("article_${method}_description");
- if ($descr == FALSE)
- $descr = '';
- $html_params = array( 'title' =>
- $title.' - '. $this->config->item('site_name'),
+ $html_params = array('title' => $this->title.' - '
+ . $this->config->item('site_name'),
'css' => array(
'jquery-ui.css'
- ),
- //'js' => array(),
- 'metas' => array('description'=>$descr)
+ ),
+ 'js' => array(
+ 'jquery.js',
+ 'jquery-ui.js'
+ ),
+ 'metas' =>
+ array('description'=>$this->metaDescription)
);
$this->load->library('html_head_params', $html_params);
$this->load->view('header', array('selected_menu' => $method));
$main_params['content'] = $this->_load($method, $params);
- // TODO side
- $main_params['side'] = '<h1>Side Box</h1><p>TODO: Put side box content here</p>';
+ $main_params['side'] = $this->load->view('side_default.php', NULL, TRUE);
$this->load->view('main', $main_params);
$this->load->view('footer');
'css' => array(
'catalog.css',
'jquery-ui.css'
- ),
- //'js' => array(),
+ ),
+ 'js' => array(
+ 'jquery.js',
+ 'jquery-ui.js'
+ ),
//'metas' => array('description'=>'','keywords'=>'')
);
$this->load->library('html_head_params', $params);
$this->load->view('header', array('selected_menu' => 'home'));
$main_params['content'] = $this->load->view('catalog/index_view', $data, TRUE);
- // TODO: side
- $main_params['side'] = '<h1>Side Box</h1><p>TODO: Put side box content here</p>';
+ $main_params['side'] = $this->load->view('side_default.php', NULL, TRUE);
$this->load->view('main', $main_params);
$this->load->view('footer');
'css' => array(
'jquery-ui.css'
),
- //'js' => array(),
+ 'js' => array(
+ 'jquery.js',
+ 'jquery-ui.js'
+ ),
//'metas' => array('description'=>'','keywords'=>'')
);
$this->load->library('html_head_params', $params);
'css' => array(
'catalog.css',
'jquery-ui.css'
- ),
- //'js' => array(),
+ ),
+ 'js' => array(
+ 'jquery.js',
+ 'jquery-ui.js'
+ ),
//'metas' => array('description'=>'','keywords'=>'')
);
$this->load->library('html_head_params', $params);
* Library Article_Controller can be extended by a controller to be used for
* content pages that depend on the language.
*
- * Several language specific parameters can be coded in language files.
- * Non language specific parameters can be putted in config files.
+ * The page views are usually located in
+ * "application/views/article/$language/$method".
+ * Parameters:
+ * <ul>
+ * <li><strong>Article Title:</strong> in language file 'article_lang.php':
+ * an entry named "article_$method".
+ * If not present "$method" is used as a name.</li>
+ * <li><strong>Article Meta Description:</strong> in language file..:
+ * an entry "article_${method}_description"</li>
+ * <li><strong>Helpers, Libraries:</strong> in config file 'article.php':
+ * an entry named "article_${method}_helpers" or "article_${method}_libraries"
+ * respectively with an array of helpers or libraries to be loaded for the
+ * article.</li>
+ * </ul>
*
- * @category Library
+ * @category Base Controller Library
* @author Călin-Andrei Burloiu
*/
class Article_Controller extends CI_Controller {
+ protected $title = NULL;
+ protected $metaDescription = NULL;
+ protected $helpers = array();
+ protected $libraries = array();
+
function __construct()
{
parent::__construct();
+
+ // Language, title and description
+ $this->lang->load('article');
+
+ // Helpers and libraries.
+ $this->config->load('article');
}
/**
- * Override this with site specific information (header, menus...) and call
+ * Extend this with site specific information (header, menus...) and call
* $this->_load which is a generic method that loads the article.
* Both parameters must be passed to $this->_load.
*/
public function _remap($method, $params = array())
{
- $this->load->view('echo',
- array('output' => $this->_load($method, $params),
- 'clear' => TRUE)
- );
+ // Title
+ $this->title = $this->lang->line("article_$method");
+ if ($this->title === FALSE)
+ $this->title = $method;
+
+ // Meta Description
+ $this->metaDescription = $this->lang->line("article_${method}_description");
+ if ($this->metaDescription === FALSE)
+ $this->metaDescription = '';
+
+ // Helpers
+ $this->helpers = $this->config->item("article_${method}_helpers");
+ if ($this->helpers !== FALSE)
+ $this->load->helper($this->helpers);
+
+ // Libraries
+ $this->libraries = $this->config->item("article_${method}_library");
+ if ($this->libraries !== FALSE)
+ $this->load->library($libraries);
}
/**
$lang['ui_nav_menu_home'] = 'Home';
$lang['ui_nav_menu_install_plugins'] = 'Install Plugins';
$lang['ui_nav_menu_about'] = 'About';
+$lang['ui_nav_menu_help'] = 'Help';
+$lang['ui_nav_menu_contact'] = 'Contact';
$lang['ui_nav_menu_log_in'] = 'Log In';
$lang['ui_nav_menu_register'] = 'Register';
-$lang['ui_nav_menu_help'] = 'Help';
$lang['ui_search'] = 'Search';
<h1>P2P-Next</h1>
-<p><a title="P2P-Next" href="http://www.p2p-next.org/">P2P-Next</a> is an integrated FP7 EU project involving more than 20 partners, including <a title="University Politehnica of Bucharest" href="http://www.upb.ro">University Politehnica of Bucharest</a> (UPB).</p>
+<p><a title="P2P-Next" href="http://www.p2p-next.org/">P2P-Next</a> is an integrated FP7 EU project involving more than 20 partners, including <a title="University Politehnica of Bucharest" href="http://www.upb.ro" ref="nofollow">University Politehnica of Bucharest</a> (UPB).</p>
<p>P2P-Next aims to build the next generation Peer-to-Peer (P2P) content delivery platform.</p>
<p>This site provides information on UPB's contribution to the P2P-Next project activities. We are currently part of WP4 (Work Package 4 - IPvNext Networking Fabric) and WP8 (Work Package 8 - Living Lab Trials).</p>
<h1>NextShare Video Plugins</h1>
<dl>
<dt><a href="http://www.tribler.org/trac/wiki/BrowserPlugin" target="_blank">NextSharePC</a></dt>
- <dd>a media-player browser plugin which uses <a href="http://www.videolan.org/vlc/" target="_blank">VLC</a> libraries for video rendering and incorporates P2P technology for VideoOnDemand (VoD) and LiveStreaming content delivery. The plugin is currently working with Internet Explorer and Firefox on Windows.</dd>
+ <dd>a media-player browser plugin which uses <a href="http://www.videolan.org/vlc/" target="_blank" ref="nofollow">VLC</a> libraries for video rendering and incorporates P2P technology for VideoOnDemand (VoD) and LiveStreaming content delivery. The plugin is currently working with Internet Explorer and Firefox on Windows.</dd>
</dl>
<dl>
<dt><a href="http://www.tribler.org/trac/wiki/SwarmPlayer" target="_blank">SwarmPlayer</a></dt>
<a href="http://www.tribler.org/trac/wiki/BrowserPlugin" target="_blank">NextSharePC</a>
</th>
<td>
- <a href="http://www.videolan.org/vlc/" target="_blank"><img src="<?php echo site_url('img/vlc-icon.png') ?>" alt="win" /> VLC</a>
+ <a href="http://www.videolan.org/vlc/" target="_blank" ref="nofollow"><img src="<?php echo site_url('img/vlc-icon.png') ?>" alt="win" /> VLC</a>
</td>
<td>
<p><img src="<?php echo site_url('img/windows-icon.png') ?>" alt="win" /> Windows</p>
<p><img src="<?php echo site_url('img/macosx-icon.png') ?>" alt="win" /> Mac OS X</p>
</td>
<td>
- <p><img src="<?php echo site_url('img/firefox-icon.png') ?>" alt="win" /> <a href="http://www.mozilla.com/" target="_blank">Mozilla Firefox</a> 3.5 or greater</p>
- <p><img src="<?php echo site_url('img/ie-icon.png') ?>" alt="win" /> <a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home" target="_blank">Internet Explorer</a> 7.0 or greater</p>
+ <p><img src="<?php echo site_url('img/firefox-icon.png') ?>" alt="win" /> <a href="http://www.mozilla.com/" target="_blank" ref="nofollow">Mozilla Firefox</a> 3.5 or greater</p>
+ <p><img src="<?php echo site_url('img/ie-icon.png') ?>" alt="win" /> <a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home" target="_blank" ref="nofollow">Internet Explorer</a> 7.0 or greater</p>
</td>
</tr>
<tr>
<a href="http://www.tribler.org/trac/wiki/SwarmPlayer" target="_blank">SwarmPlayer</a>
</th>
<td>
- <a href="http://www.w3.org/TR/html5/" target="_blank"><img src="<?php echo site_url('img/html5-icon.png') ?>" alt="win" /> HTML5</a>
+ <a href="http://www.w3.org/TR/html5/" target="_blank" ref="nofollow"><img src="<?php echo site_url('img/html5-icon.png') ?>" alt="win" /> HTML5</a>
</td>
<td>
<p><img src="<?php echo site_url('img/windows-icon.png') ?>" alt="win" /> Windows</p>
<p><img src="<?php echo site_url('img/macosx-icon.png') ?>" alt="win" /> Mac OS X</p>
</td>
<td>
- <p><img src="<?php echo site_url('img/firefox-icon.png') ?>" alt="win" /> <a href="http://www.mozilla.com/" target="_blank">Mozilla Firefox</a> 3.5 or greater</p>
- <p><img src="<?php echo site_url('img/ie-icon.png') ?>" alt="win" /> <a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home" target="_blank">Internet Explorer</a> 7.0 or greater</p>
+ <p><img src="<?php echo site_url('img/firefox-icon.png') ?>" alt="win" /> <a href="http://www.mozilla.com/" target="_blank" ref="nofollow">Mozilla Firefox</a> 3.5 or greater</p>
+ <p><img src="<?php echo site_url('img/ie-icon.png') ?>" alt="win" /> <a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home" target="_blank" ref="nofollow">Internet Explorer</a> 7.0 or greater</p>
</td>
</tr>
</table>
<li>from <a href="<?php site_url('catalog/category/1') ?>">feature films</a></li>
<li>from <a href="<?php echo site_url('catalog/category/2') ?>"><em>TechTalks</em> technical presentations</a></li>
<li>or from <a href="<?php site_url('catalog/category/3') ?>">various events</a> from our faculty</li>
- <li>from <a href="<?php site_url('catalog/category/4') ?>">karaoke parties</a> in <a href="http://acs.pub.ro/" target="_blank">Automatic Control and Computers Faculty</a></li>
+ <li>from <a href="<?php site_url('catalog/category/4') ?>">karaoke parties</a> in <a href="http://acs.pub.ro/" target="_blank" ref="nofollow">Automatic Control and Computers Faculty</a></li>
</ul>
-<p>All available movies are currently seeded by 5 peers with high bandwidth (1Gbit) kindly provided by the<a title="NCIT-Cluster" href="http://cluster.ncit.pub.ro/" target="_blank"> NCIT-Cluster</a>. Anyone that watches a movie will take part in the swarm and ensure greater availability to provided content.</p>
-
-<!--<h1>Contact and support</h1>
-<p>In case there are issues getting the SwarmPlugin to work or for any other information, please contact us at <a title="P2P-Next Contact Address" href="mailto:p2p-next-contact@cs.pub.ro">p2p-next-contact@cs.pub.ro</a>.</p>
-<p>Please access <a title="Swarm Plugin Demo" href="extra/SwarmPluginDemo.wmv">this link</a> in order to download a small demo movie about using the <a title="Swarm Plugin" href="http://www.tribler.org/trac/wiki/BrowserPlugin">SwarmPlugin</a> on <a title="P2P-Next UPB Trial Site">this site</a>.</p>-->
\ No newline at end of file
+<p>All available movies are currently seeded by 5 peers with high bandwidth (1Gbit) kindly provided by the<a title="NCIT-Cluster" href="http://cluster.ncit.pub.ro/" target="_blank" ref="nofollow"> NCIT-Cluster</a>. Anyone that watches a movie will take part in the swarm and ensure greater availability to provided content.</p>
\ No newline at end of file
--- /dev/null
+<h1>Contact and support</h1>
+<p>In case there are issues getting NextShare plugins to work or for any other information or suggestion, please contact us:
+
+<dl>
+ <dt><img src="<?php echo site_url('img/email-icon.png') ?>" class="inline" alt="email" /> E-mail: </dt>
+ <dd>
+ <?php echo safe_mailto('p2p-next-contact@cs.pub.ro', 'p2p-next-contact@cs.pub.ro') ?>
+ <!--<a href="mailto:p2p-next-contact@cs.pub.ro">p2p-next-contact@cs.pub.ro</a>-->
+ </dd>
+</dl>
\ No newline at end of file
-<h1>Install Plugins</h1>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
-<p>install plugins instructions</p>
\ No newline at end of file
+<h1>NextShare Plugins</h1>
+<ol>
+ <li><a href="#SwarmPlayer">SwarmPlayer (based on HTML5)</a></li>
+ <li><a href="#NextSharePC">NextSharePC (based on VLC)</a></li>
+</ol>
+
+<h1><a name="SwarmPlayer">SwarmPlayer</a></h1>
+<p>To install SwarmPlayer video plugin which is based on HTML5 visit P2P-Next's <a href="http://swarmplayer.p2p-next.org/" target="_blank">SwarmPlayer Site</a>. You should find a green button there labeled "Add Swarmplayer...", click it and follow the instructions.</p>
+<a href="http://swarmplayer.p2p-next.org/" target="_blank"><img src="<?php echo site_url('img/SwarmPlayer-site.jpg') ?>" alt="SwarmPlayer Site" width="288" height="240" /></a>
+
+<h1><a name="NextSharePC">NextSharePC</a></h1>
+<p>To install NextSharePC video plugin which is based on VLC do the following:</p>
+<ol>
+ <li>If you are using:
+ <p><img src="<?php echo site_url('img/windows-icon.png') ?>" alt="win" class="inline" /> Windows run <a href="download/NextSharePC.exe">the Windows installer</a>.</p
+ <p><img src="<?php echo site_url('img/macosx-icon.png') ?>" alt="win" class="inline" /> a Mac run <a href="download/NextSharePC.dmg">the Mac OS X installer</a>.</p
+ </li>
+ <li>Restart your browser and revisit the page.</li>
+ <li>Enjoy! ;)</li>
+</ol>
\ No newline at end of file
<div id="footer">
- Copyright © 2011, <a href="http://www.upb.ro/">University POLITEHNICA of Bucharest</a>, <a href="http://www.p2p-next.org/">P2P-Next Project</a>
+ <div>Copyright © 2011, <a href="http://www.upb.ro/">University POLITEHNICA of Bucharest</a>, <a href="http://www.p2p-next.org/">P2P-Next Project</a></div>
</div>
<li class="menu-left"><a href="<?php echo site_url('help') ?>"
<?php echo ($selected_menu == 'help' ? 'class="selected"' : '') ?>><?php echo $this->lang->line('ui_nav_menu_help') ?></a></li>
+
+ <li class="menu-left"><a href="<?php echo site_url('contact') ?>"
+ <?php echo ($selected_menu == 'contact' ? 'class="selected"' : '') ?>><?php echo $this->lang->line('ui_nav_menu_contact') ?></a></li>
<li class="menu-right"><a href="#<?php //echo site_url('register') ?>"
<?php echo ($selected_menu == 'register' ? 'class="selected"' : '') ?>><?php echo $this->lang->line('ui_nav_menu_register') ?></a></li>
--- /dev/null
+<div class="ui-widget ui-widget-content ui-widget-header ui-corner-all">
+ <div id="container-install-swarmplayer" class="container-install">
+ <a id="install-swarmplayer" href="<?php echo site_url('install-plugins#SwarmPlayer') ?>">Install SwarmPlayer Plugin</a>
+ </div>
+ <div id="container-install-nextsharepc" class="container-install">
+ <a id="install-nextsharepc" href="<?php echo site_url('install-plugins#NextSharePC') ?>">Install NextSharePC Plugin</a>
+ </div>
+</div>
+
+<script type="text/javascript">
+ $(function() {
+ $('#install-swarmplayer')
+ .button({
+ icons: {
+ primary: "ui-icon-arrowthickstop-1-s"
+ }
+ });
+ $('#install-nextsharepc')
+ .button({
+ icons: {
+ primary: "ui-icon-arrowthickstop-1-s"
+ }
+ });
+ });
+</script>
\ No newline at end of file
margin: 0;
font-family: Arial, Helvetica, sans-serif;
font-size: 75%;
- background: white url('/devel/img/bg.png') repeat-x left 90px;
+ background: white url('/devel/img/bg.png') repeat-x left 88px;
}
a:link
margin-bottom: 8px;
}
+.inline
+{
+ vertical-align: middle;
+}
+
+.container-install
+{
+ width: 192px;
+ margin: 0 auto;
+ margin-top: 8px;
+ margin-bottom: 8px;
+}
+
#nav-menu
{/*
left: 0;
#nav-menu a:link, #nav-menu a:visited
{
display: block;
- height: 14px;
+ height: 12px;
color: white;
text-align: center;
line-height: 100%;
padding-bottom: 5px;
padding-left: 16px;
padding-right: 16px;
+ border: 1px solid transparent;
text-decoration: none;
}
+#nav-menu a:hover
+{
+ background-color: rgb(90,148,216);
+ border: 1px outset rgb(0,90,192);
+}
+#nav-menu a:active
+{
+ background-color: rgb(90,148,216);
+ border: 1px inset rgb(60,128,208);
+}
#nav-menu a.selected
{
background-color: rgb(60,128,208);
+ border: 1px inset rgb(60,128,208);
color: #FFE4B5;
font-weight: bold;
}
-#nav-menu a:hover, #nav-menu a:active
-{
- background-color: rgb(90,148,216);
-}
#header
{
top: 24px;
left: 0;
width: 100%;*/
- height: 64px;
+ height: 62px;
background: #e5ecf5;
- border-bottom: 2px ridge rgb(60,128,208);
+ border: 1px outset #e5ecf5;
}
#logo
font-weight: bold;
color: #000D60;
text-align: left;
- padding: 10px 0px 0px 10px;
+ padding: 0px 0px 0px 8px;
+ margin: 8px 0px 8px 0px;
background: url(/devel/img/header.png) top repeat-x;
+ outline: 1px outset rgb(108,162,222);
clear: both;
}
vertical-align: middle;
}
+#main dt
+{
+ font-weight: bold;
+}
+
#content
{
float: left;
#footer
{
clear: both;
- border-top: 2px ridge rgb(60,128,208);
- padding-top: 8px;
- padding-bottom: 8px;
+ border: 1px outset #e5ecf5;
+ padding-top: 0.5em;
+ padding-bottom: 0.4em;
background: #e5ecf5;
+ font-size: 0.9em;
text-align: center;
}