diff options
| author | 2013-12-23 13:22:50 +0100 | |
|---|---|---|
| committer | 2013-12-23 13:22:50 +0100 | |
| commit | 24d9d1628d673f68fa0cc7b98a3ef9a8d021b070 (patch) | |
| tree | 2d794dc100d707e53b82a2de7d84b3d13103e461 /app/views | |
| parent | 75096e6a39fe5d34d3951991f296f616e62a9fd8 (diff) | |
| parent | 9e46c1ee7fc7f9ad9e2c07f0cf826573dd4c9766 (diff) | |
Fusion 0.7-dev
Diffstat (limited to 'app/views')
| -rw-r--r-- | app/views/configure/categorize.phtml | 22 | ||||
| -rw-r--r-- | app/views/configure/display.phtml | 121 | ||||
| -rw-r--r-- | app/views/configure/feed.phtml | 84 | ||||
| -rw-r--r-- | app/views/configure/importExport.phtml | 18 | ||||
| -rw-r--r-- | app/views/configure/sharing.phtml | 64 | ||||
| -rw-r--r-- | app/views/configure/shortcut.phtml | 40 | ||||
| -rwxr-xr-x | app/views/entry/bookmark.phtml | 17 | ||||
| -rwxr-xr-x | app/views/entry/read.phtml | 17 | ||||
| -rw-r--r-- | app/views/error/index.phtml | 4 | ||||
| -rw-r--r-- | app/views/helpers/javascript_vars.phtml | 24 | ||||
| -rwxr-xr-x | app/views/helpers/logs_pagination.phtml | 16 | ||||
| -rwxr-xr-x | app/views/helpers/pagination.phtml | 28 | ||||
| -rw-r--r-- | app/views/helpers/view/global_view.phtml | 8 | ||||
| -rw-r--r-- | app/views/helpers/view/normal_view.phtml | 173 | ||||
| -rw-r--r-- | app/views/helpers/view/reader_view.phtml | 18 | ||||
| -rwxr-xr-x | app/views/helpers/view/rss_view.phtml | 11 | ||||
| -rw-r--r-- | app/views/index/about.phtml | 26 | ||||
| -rw-r--r-- | app/views/index/index.phtml | 10 | ||||
| -rw-r--r-- | app/views/index/logs.phtml | 16 | ||||
| -rw-r--r-- | app/views/javascript/actualize.phtml | 4 |
20 files changed, 438 insertions, 283 deletions
diff --git a/app/views/configure/categorize.phtml b/app/views/configure/categorize.phtml index 95951247e..a564e8cdd 100644 --- a/app/views/configure/categorize.phtml +++ b/app/views/configure/categorize.phtml @@ -1,28 +1,28 @@ <?php $this->partial ('aside_feed'); ?> <div class="post"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> <form method="post" action="<?php echo _url ('configure', 'categorize'); ?>"> - <legend><?php echo Translate::t ('categories_management'); ?></legend> + <legend><?php echo Minz_Translate::t ('categories_management'); ?></legend> - <p class="alert alert-warn"><?php echo Translate::t ('feeds_moved_category_deleted', $this->defaultCategory->name ()); ?></p> + <p class="alert alert-warn"><?php echo Minz_Translate::t ('feeds_moved_category_deleted', $this->defaultCategory->name ()); ?></p> <?php $i = 0; foreach ($this->categories as $cat) { $i++; ?> <div class="form-group"> <label class="group-name" for="cat_<?php echo $cat->id (); ?>"> - <?php echo Translate::t ('category_number', $i); ?> + <?php echo Minz_Translate::t ('category_number', $i); ?> </label> <div class="group-controls"> <input type="text" id="cat_<?php echo $cat->id (); ?>" name="categories[]" value="<?php echo $cat->name (); ?>" /> <?php if ($cat->nbFeed () > 0) { ?> - <a class="confirm" href="<?php echo _url ('feed', 'delete', 'id', $cat->id (), 'type', 'category'); ?>"><?php echo Translate::t ('ask_empty'); ?></a> + <a class="confirm" href="<?php echo _url ('feed', 'delete', 'id', $cat->id (), 'type', 'category'); ?>"><?php echo Minz_Translate::t ('ask_empty'); ?></a> <?php } ?> - (<?php echo Translate::t ('number_feeds', $cat->nbFeed ()); ?>) + (<?php echo Minz_Translate::t ('number_feeds', $cat->nbFeed ()); ?>) <?php if ($cat->id () == $this->defaultCategory->id ()) { ?> - <i class="icon i_help"></i> <?php echo Translate::t ('can_not_be_deleted'); ?> + <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t ('can_not_be_deleted'); ?> <?php } ?> <input type="hidden" name="ids[]" value="<?php echo $cat->id (); ?>" /> @@ -31,16 +31,16 @@ <?php } ?> <div class="form-group"> - <label class="group-name" for="new_category"><?php echo Translate::t ('add_category'); ?></label> + <label class="group-name" for="new_category"><?php echo Minz_Translate::t ('add_category'); ?></label> <div class="group-controls"> - <input type="text" id="new_category" name="new_category" placeholder="<?php echo Translate::t ('new_category'); ?>" /> + <input type="text" id="new_category" name="new_category" placeholder="<?php echo Minz_Translate::t ('new_category'); ?>" /> </div> </div> <div class="form-group form-actions"> <div class="group-controls"> - <button type="submit" class="btn btn-important"><?php echo Translate::t ('save'); ?></button> - <button type="reset" class="btn"><?php echo Translate::t ('cancel'); ?></button> + <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button> + <button type="reset" class="btn"><?php echo Minz_Translate::t ('cancel'); ?></button> </div> </div> </form> diff --git a/app/views/configure/display.phtml b/app/views/configure/display.phtml index 8ad626b86..ad35d7c71 100644 --- a/app/views/configure/display.phtml +++ b/app/views/configure/display.phtml @@ -1,13 +1,13 @@ <?php $this->partial ('aside_configure'); ?> <div class="post"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> <form method="post" action="<?php echo _url ('configure', 'display'); ?>"> - <legend><?php echo Translate::t ('general_configuration'); ?></legend> + <legend><?php echo Minz_Translate::t ('general_configuration'); ?></legend> <div class="form-group"> - <label class="group-name" for="language"><?php echo Translate::t ('language'); ?></label> + <label class="group-name" for="language"><?php echo Minz_Translate::t ('language'); ?></label> <div class="group-controls"> <select name="language" id="language"> <?php $languages = $this->conf->availableLanguages (); ?> @@ -19,12 +19,12 @@ </div> <div class="form-group"> - <label class="group-name" for="theme"><?php echo Translate::t ('theme'); ?></label> + <label class="group-name" for="theme"><?php echo Minz_Translate::t ('theme'); ?></label> <div class="group-controls"> <select name="theme" id="theme"> <?php foreach ($this->themes as $theme) { ?> <option value="<?php echo $theme['path']; ?>"<?php echo $this->conf->theme () == $theme['path'] ? ' selected="selected"' : ''; ?>> - <?php echo $theme['name'] . ' ' . Translate::t ('by') . ' ' . $theme['author']; ?> + <?php echo $theme['name'] . ' ' . Minz_Translate::t ('by') . ' ' . $theme['author']; ?> </option> <?php } ?> </select> @@ -32,68 +32,68 @@ </div> <div class="form-group"> - <label class="group-name" for="old_entries"><?php echo Translate::t ('delete_articles_every'); ?></label> + <label class="group-name" for="old_entries"><?php echo Minz_Translate::t ('delete_articles_every'); ?></label> <div class="group-controls"> - <input type="number" id="old_entries" name="old_entries" value="<?php echo $this->conf->oldEntries (); ?>" /> <?php echo Translate::t ('month'); ?> + <input type="number" id="old_entries" name="old_entries" value="<?php echo $this->conf->oldEntries (); ?>" /> <?php echo Minz_Translate::t ('month'); ?> </div> </div> <div class="form-group"> - <label class="group-name" for="mail_login"><?php echo Translate::t ('persona_connection_email'); ?></label> + <label class="group-name" for="mail_login"><?php echo Minz_Translate::t ('persona_connection_email'); ?></label> <?php $mail = $this->conf->mailLogin (); ?> <div class="group-controls"> - <input type="email" id="mail_login" name="mail_login" value="<?php echo $mail ? $mail : ''; ?>" placeholder="<?php echo Translate::t ('blank_to_disable'); ?>" /> - <noscript><b><?php echo Translate::t ('javascript_should_be_activated'); ?></b></noscript> + <input type="email" id="mail_login" name="mail_login" value="<?php echo $mail ? $mail : ''; ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>" /> + <noscript><b><?php echo Minz_Translate::t ('javascript_should_be_activated'); ?></b></noscript> <label class="checkbox" for="anon_access"> <input type="checkbox" name="anon_access" id="anon_access" value="yes"<?php echo $this->conf->anonAccess () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('allow_anonymous'); ?> + <?php echo Minz_Translate::t ('allow_anonymous'); ?> </label> </div> </div> <div class="form-group"> - <label class="group-name" for="token"><?php echo Translate::t ('auth_token'); ?></label> + <label class="group-name" for="token"><?php echo Minz_Translate::t ('auth_token'); ?></label> <?php $token = $this->conf->token (); ?> <div class="group-controls"> - <input type="text" id="token" name="token" value="<?php echo $token; ?>" placeholder="<?php echo Translate::t ('blank_to_disable'); ?>"/> - <i class="icon i_help"></i> <?php echo Translate::t('explain_token', Url::display(null, 'html', true), $token); ?> + <input type="text" id="token" name="token" value="<?php echo $token; ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>"/> + <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t('explain_token', Minz_Url::display(null, 'html', true), $token); ?> </div> </div> - <legend><?php echo Translate::t ('reading_configuration'); ?></legend> + <legend><?php echo Minz_Translate::t ('reading_configuration'); ?></legend> <div class="form-group"> - <label class="group-name" for="posts_per_page"><?php echo Translate::t ('articles_per_page'); ?></label> + <label class="group-name" for="posts_per_page"><?php echo Minz_Translate::t ('articles_per_page'); ?></label> <div class="group-controls"> <input type="number" id="posts_per_page" name="posts_per_page" value="<?php echo $this->conf->postsPerPage (); ?>" /> </div> </div> <div class="form-group"> - <label class="group-name" for="sort_order"><?php echo Translate::t ('sort_order'); ?></label> + <label class="group-name" for="sort_order"><?php echo Minz_Translate::t ('sort_order'); ?></label> <div class="group-controls"> <select name="sort_order" id="sort_order"> - <option value="low_to_high"<?php echo $this->conf->sortOrder () == 'low_to_high' ? ' selected="selected"' : ''; ?>><?php echo Translate::t ('newer_first'); ?></option> - <option value="high_to_low"<?php echo $this->conf->sortOrder () == 'high_to_low' ? ' selected="selected"' : ''; ?>><?php echo Translate::t ('older_first'); ?></option> + <option value="DESC"<?php echo $this->conf->sortOrder () === 'DESC' ? ' selected="selected"' : ''; ?>><?php echo Minz_Translate::t ('newer_first'); ?></option> + <option value="ASC"<?php echo $this->conf->sortOrder () === 'ASC' ? ' selected="selected"' : ''; ?>><?php echo Minz_Translate::t ('older_first'); ?></option> </select> </div> </div> <div class="form-group"> - <label class="group-name" for="view_mode"><?php echo Translate::t ('default_view'); ?></label> + <label class="group-name" for="view_mode"><?php echo Minz_Translate::t ('default_view'); ?></label> <div class="group-controls"> <select name="view_mode" id="view_mode"> - <option value="normal"<?php echo $this->conf->viewMode () == 'normal' ? ' selected="selected"' : ''; ?>><?php echo Translate::t ('normal_view'); ?></option> - <option value="reader"<?php echo $this->conf->viewMode () == 'reader' ? ' selected="selected"' : ''; ?>><?php echo Translate::t ('reader_view'); ?></option> - <option value="global"<?php echo $this->conf->viewMode () == 'global' ? ' selected="selected"' : ''; ?>><?php echo Translate::t ('global_view'); ?></option> + <option value="normal"<?php echo $this->conf->viewMode () == 'normal' ? ' selected="selected"' : ''; ?>><?php echo Minz_Translate::t ('normal_view'); ?></option> + <option value="reader"<?php echo $this->conf->viewMode () == 'reader' ? ' selected="selected"' : ''; ?>><?php echo Minz_Translate::t ('reader_view'); ?></option> + <option value="global"<?php echo $this->conf->viewMode () == 'global' ? ' selected="selected"' : ''; ?>><?php echo Minz_Translate::t ('global_view'); ?></option> </select> <label class="radio" for="radio_all"> <input type="radio" name="default_view" id="radio_all" value="all"<?php echo $this->conf->defaultView () == 'all' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('show_all_articles'); ?> + <?php echo Minz_Translate::t ('show_all_articles'); ?> </label> <label class="radio" for="radio_not_read"> <input type="radio" name="default_view" id="radio_not_read" value="not_read"<?php echo $this->conf->defaultView () == 'not_read' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('show_not_reads'); ?> + <?php echo Minz_Translate::t ('show_not_reads'); ?> </label> </div> </div> @@ -102,8 +102,8 @@ <div class="group-controls"> <label class="checkbox" for="auto_load_more"> <input type="checkbox" name="auto_load_more" id="auto_load_more" value="yes"<?php echo $this->conf->autoLoadMore () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('auto_load_more'); ?> - <?php echo $this->conf->displayPosts () == 'no' ? '<noscript> - <b>' . Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> + <?php echo Minz_Translate::t ('auto_load_more'); ?> + <?php echo $this->conf->displayPosts () == 'no' ? '<noscript> - <b>' . Minz_Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> </label> </div> </div> @@ -112,8 +112,8 @@ <div class="group-controls"> <label class="checkbox" for="display_posts"> <input type="checkbox" name="display_posts" id="display_posts" value="yes"<?php echo $this->conf->displayPosts () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('display_articles_unfolded'); ?> - <?php echo $this->conf->displayPosts () == 'no' ? '<noscript> - <b>' . Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> + <?php echo Minz_Translate::t ('display_articles_unfolded'); ?> + <?php echo $this->conf->displayPosts () == 'no' ? '<noscript> - <b>' . Minz_Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> </label> </div> </div> @@ -122,57 +122,61 @@ <div class="group-controls"> <label class="checkbox" for="lazyload"> <input type="checkbox" name="lazyload" id="lazyload" value="yes"<?php echo $this->conf->lazyload () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('img_with_lazyload'); ?> - <?php echo $this->conf->lazyload () == 'yes' ? '<noscript> - <b>' . Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> + <?php echo Minz_Translate::t ('img_with_lazyload'); ?> + <?php echo $this->conf->lazyload () == 'yes' ? '<noscript> - <b>' . Minz_Translate::t ('javascript_should_be_activated') . '</b></noscript>' : ''; ?> </label> </div> </div> <div class="form-group"> - <label class="group-name"><?php echo Translate::t ('auto_read_when'); ?></label> + <label class="group-name"><?php echo Minz_Translate::t ('auto_read_when'); ?></label> <div class="group-controls"> <label class="checkbox" for="check_open_article"> <input type="checkbox" name="mark_open_article" id="check_open_article" value="yes"<?php echo $this->conf->markWhenArticle () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('article_selected'); ?> + <?php echo Minz_Translate::t ('article_selected'); ?> </label> <label class="checkbox" for="check_open_site"> <input type="checkbox" name="mark_open_site" id="check_open_site" value="yes"<?php echo $this->conf->markWhenSite () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('article_open_on_website'); ?> + <?php echo Minz_Translate::t ('article_open_on_website'); ?> </label> <label class="checkbox" for="check_scroll"> <input type="checkbox" name="mark_scroll" id="check_scroll" value="yes"<?php echo $this->conf->markWhenScroll () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('scroll'); ?> + <?php echo Minz_Translate::t ('scroll'); ?> + </label> + <label class="checkbox" for="check_reception"> + <input type="checkbox" name="mark_upon_reception" id="check_reception" value="yes"<?php echo $this->conf->markUponReception () == 'yes' ? ' checked="checked"' : ''; ?> /> + <?php echo Minz_Translate::t ('upon_reception'); ?> </label> </div> </div> <div class="form-group"> - <label class="group-name"><?php echo Translate::t ('after_onread'); ?></label> + <label class="group-name"><?php echo Minz_Translate::t ('after_onread'); ?></label> <div class="group-controls"> <label class="checkbox" for="onread_jump_next"> <input type="checkbox" name="onread_jump_next" id="onread_jump_next" value="yes"<?php echo $this->conf->onread_jump_next () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('jump_next'); ?> + <?php echo Minz_Translate::t ('jump_next'); ?> </label> </div> </div> - <legend><?php echo Translate::t ('reading_icons'); ?></legend> + <legend><?php echo Minz_Translate::t ('reading_icons'); ?></legend> <div class="form-group"> <table> <thead> <tr> - <th> </th> - <th><a class="read" title="<?php echo Translate::t ('mark_read'); ?>"> </span></th> - <th><a class="bookmark" title="<?php echo Translate::t ('mark_favorite'); ?>"> </span></th> - <th><?php echo Translate::t ('sharing'); ?></th> - <th><?php echo Translate::t ('related_tags'); ?></th> - <th><?php echo Translate::t ('publication_date'); ?></th> - <th class="item link"><a> </a></th> + <th> </th> + <th title="<?php echo Minz_Translate::t ('mark_read'); ?>"><?php echo FreshRSS_Themes::icon('read'); ?></th> + <th title="<?php echo Minz_Translate::t ('mark_favorite'); ?>"><?php echo FreshRSS_Themes::icon('bookmark'); ?></th> + <th><?php echo Minz_Translate::t ('sharing'); ?></th> + <th><?php echo Minz_Translate::t ('related_tags'); ?></th> + <th><?php echo Minz_Translate::t ('publication_date'); ?></th> + <th><?php echo FreshRSS_Themes::icon('link'); ?></th> </tr> </thead> <tbody> <tr> - <th><?php echo Translate::t ('top_line'); ?></th> + <th><?php echo Minz_Translate::t ('top_line'); ?></th> <td><input type="checkbox" name="topline_read" value="yes"<?php echo $this->conf->toplineRead () ? ' checked="checked"' : ''; ?> /></td> <td><input type="checkbox" name="topline_favorite" value="yes"<?php echo $this->conf->toplineFavorite () ? ' checked="checked"' : ''; ?> /></td> <td><input type="checkbox" disabled="disabled" /></td> @@ -180,7 +184,7 @@ <td><input type="checkbox" name="topline_date" value="yes"<?php echo $this->conf->toplineDate () ? ' checked="checked"' : ''; ?> /></td> <td><input type="checkbox" name="topline_link" value="yes"<?php echo $this->conf->toplineLink () ? ' checked="checked"' : ''; ?> /></td> </tr><tr> - <th><?php echo Translate::t ('bottom_line'); ?></th> + <th><?php echo Minz_Translate::t ('bottom_line'); ?></th> <td><input type="checkbox" name="bottomline_read" value="yes"<?php echo $this->conf->bottomlineRead () ? ' checked="checked"' : ''; ?> /></td> <td><input type="checkbox" name="bottomline_favorite" value="yes"<?php echo $this->conf->bottomlineFavorite () ? ' checked="checked"' : ''; ?> /></td> <td><input type="checkbox" name="bottomline_sharing" value="yes"<?php echo $this->conf->bottomlineSharing () ? ' checked="checked"' : ''; ?> /></td> @@ -192,29 +196,22 @@ </table> </div> - <legend><?php echo Translate::t ('sharing'); ?></legend> - <div class="form-group"> - <label class="group-name" for="shaarli"><?php echo Translate::t ('your_shaarli'); ?></label> - <div class="group-controls"> - <input type="text" id="shaarli" name="shaarli" value="<?php echo $this->conf->urlShaarli (); ?>" placeholder="<?php echo Translate::t ('blank_to_disable'); ?>"/> - </div> - </div> - - <legend><?php echo Translate::t ('advanced'); ?></legend> + <legend><?php echo Minz_Translate::t ('advanced'); ?></legend> <div class="form-group"> <label class="group-name"></label> <div class="group-controls"> - <a class="btn" href="<?php echo _url('entry', 'optimize'); ?>"> - <?php echo Translate::t('optimize_bdd'); ?> - </a> - <i class="icon i_help"></i> <?php echo Translate::t('optimize_todo_sometimes'); ?> + <p><?php echo $this->nb_total; ?> <?php echo Minz_Translate::t('articles') ?>, <?php echo formatBytes($this->size_total); ?>.</p> + <p><a class="btn" href="<?php echo _url('entry', 'optimize'); ?>"> + <?php echo Minz_Translate::t('optimize_bdd'); ?> + </a></p> + <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t('optimize_todo_sometimes'); ?> </div> </div> <div class="form-group form-actions"> <div class="group-controls"> - <button type="submit" class="btn btn-important"><?php echo Translate::t ('save'); ?></button> - <button type="reset" class="btn"><?php echo Translate::t ('cancel'); ?></button> + <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button> + <button type="reset" class="btn"><?php echo Minz_Translate::t ('cancel'); ?></button> </div> </div> </form> diff --git a/app/views/configure/feed.phtml b/app/views/configure/feed.phtml index b61de6dcb..4504b8d76 100644 --- a/app/views/configure/feed.phtml +++ b/app/views/configure/feed.phtml @@ -2,100 +2,108 @@ <?php if ($this->flux) { ?> <div class="post"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> <?php echo Translate::t ('or'); ?> <a href="<?php echo _url ('index', 'index', 'get', 'f_' . $this->flux->id ()); ?>"><?php echo Translate::t ('filter'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> <?php echo Minz_Translate::t ('or'); ?> <a href="<?php echo _url ('index', 'index', 'get', 'f_' . $this->flux->id ()); ?>"><?php echo Minz_Translate::t ('filter'); ?></a> <h1><?php echo $this->flux->name (); ?></h1> <?php echo $this->flux->description (); ?> <?php if ($this->flux->inError ()) { ?> - <p class="alert alert-error"><span class="alert-head"><?php echo Translate::t ('damn'); ?></span> <?php echo Translate::t ('feed_in_error'); ?></p> + <p class="alert alert-error"><span class="alert-head"><?php echo Minz_Translate::t ('damn'); ?></span> <?php echo Minz_Translate::t ('feed_in_error'); ?></p> <?php } ?> <form method="post" action="<?php echo _url ('configure', 'feed', 'id', $this->flux->id ()); ?>"> - <legend><?php echo Translate::t ('informations'); ?></legend> + <legend><?php echo Minz_Translate::t ('informations'); ?></legend> <div class="form-group"> - <label class="group-name" for="name"><?php echo Translate::t ('title'); ?></label> + <label class="group-name" for="name"><?php echo Minz_Translate::t ('title'); ?></label> <div class="group-controls"> <input type="text" name="name" id="name" value="<?php echo $this->flux->name () ; ?>" /> </div> </div> <div class="form-group"> - <label class="group-name"><?php echo Translate::t ('website_url'); ?></label> + <label class="group-name"><?php echo Minz_Translate::t ('feed_description'); ?></label> <div class="group-controls"> - <span class="control"> - <?php echo $this->flux->website (); ?> - <a target="_blank" href="<?php echo $this->flux->website (); ?>"><i class="icon i_link"></i></a> - </span> + <textarea name="description" id="description"><?php echo htmlspecialchars($this->flux->description(), ENT_NOQUOTES, 'UTF-8'); ?></textarea> </div> </div> <div class="form-group"> - <label class="group-name"><?php echo Translate::t ('feed_url'); ?></label> + <label class="group-name"><?php echo Minz_Translate::t ('website_url'); ?></label> <div class="group-controls"> - <span class="control"> - <?php echo $this->flux->url (); ?> - <a target="_blank" href="<?php echo $this->flux->url (); ?>"><i class="icon i_link"></i></a> - </span> + <input type="text" name="website" id="website" value="<?php echo $this->flux->website (); ?>" /> + <a target="_blank" href="<?php echo $this->flux->website (); ?>"><?php echo FreshRSS_Themes::icon('link'); ?></a> + </div> + </div> + <div class="form-group"> + <label class="group-name"><?php echo Minz_Translate::t ('feed_url'); ?></label> + <div class="group-controls"> + <input type="text" name="url" id="url" value="<?php echo $this->flux->url (); ?>" /> + <a target="_blank" href="<?php echo $this->flux->url (); ?>"><?php echo FreshRSS_Themes::icon('link'); ?></a> + <a class="btn" target="_blank" href="http://validator.w3.org/feed/check.cgi?url=<?php echo $this->flux->url (); ?>"><?php echo Minz_Translate::t ('feed_validator'); ?></a> + </div> + </div> + <div class="form-group"> + <label class="group-name" for="category"><?php echo Minz_Translate::t ('category'); ?></label> + <div class="group-controls"> + <select name="category" id="category"> + <?php foreach ($this->categories as $cat) { ?> + <option value="<?php echo $cat->id (); ?>"<?php echo $cat->id ()== $this->flux->category () ? ' selected="selected"' : ''; ?>> + <?php echo $cat->name (); ?> + </option> + <?php } ?> + </select> </div> </div> <div class="form-group"> <label class="group-name"></label> <div class="group-controls"> <a class="btn" href="<?php echo _url ('feed', 'actualize', 'id', $this->flux->id ()); ?>"> - <i class="icon i_refresh"></i> <?php echo Translate::t('actualize'); ?> + <?php echo FreshRSS_Themes::icon('refresh'); ?> <?php echo Minz_Translate::t('actualize'); ?> </a> </div> </div> <div class="form-group"> - <label class="group-name"><?php echo Translate::t ('number_articles'); ?></label> + <label class="group-name"><?php echo Minz_Translate::t ('number_articles'); ?></label> <div class="group-controls"> <span class="control"><?php echo $this->flux->nbEntries (); ?></span> <label class="checkbox" for="keep_history"> <input type="checkbox" name="keep_history" id="keep_history" value="yes"<?php echo $this->flux->keepHistory () == 'yes' ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('keep_history'); ?> + <?php echo Minz_Translate::t ('keep_history'); ?> </label> </div> </div> - <div class="form-group"> - <label class="group-name" for="category"><?php echo Translate::t ('category'); ?></label> + <label class="group-name"></label> <div class="group-controls"> - <select name="category" id="category"> - <?php foreach ($this->categories as $cat) { ?> - <option value="<?php echo $cat->id (); ?>"<?php echo $cat->id ()== $this->flux->category () ? ' selected="selected"' : ''; ?>> - <?php echo $cat->name (); ?> - </option> - <?php } ?> - </select> + <button class="btn btn-attention confirm" formmethod="post" formaction="<?php echo Minz_Url::display (array ('c' => 'feed', 'a' => 'truncate', 'params' => array ('id' => $this->flux->id ()))); ?>"><?php echo Minz_Translate::t ('truncate'); ?></button> </div> </div> - <legend><?php echo Translate::t ('advanced'); ?></legend> + <legend><?php echo Minz_Translate::t ('advanced'); ?></legend> <div class="form-group"> - <label class="group-name" for="priority"><?php echo Translate::t ('show_in_all_flux'); ?></label> + <label class="group-name" for="priority"><?php echo Minz_Translate::t ('show_in_all_flux'); ?></label> <div class="group-controls"> <label class="checkbox" for="priority"> <input type="checkbox" name="priority" id="priority" value="10"<?php echo $this->flux->priority () > 0 ? ' checked="checked"' : ''; ?> /> - <?php echo Translate::t ('yes'); ?> + <?php echo Minz_Translate::t ('yes'); ?> </label> </div> </div> <div class="form-group"> - <label class="group-name" for="path_entries"><?php echo Translate::t ('css_path_on_website'); ?></label> + <label class="group-name" for="path_entries"><?php echo Minz_Translate::t ('css_path_on_website'); ?></label> <div class="group-controls"> - <input type="text" name="path_entries" id="path_entries" value="<?php echo $this->flux->pathEntries (); ?>" placeholder="<?php echo Translate::t ('blank_to_disable'); ?>" /> - <i class="icon i_help"></i> <?php echo Translate::t ('retrieve_truncated_feeds'); ?> + <input type="text" name="path_entries" id="path_entries" value="<?php echo $this->flux->pathEntries (); ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>" /> + <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t ('retrieve_truncated_feeds'); ?> </div> </div> <?php $auth = $this->flux->httpAuth (false); ?> <div class="form-group"> - <label class="group-name" for="http_user"><?php echo Translate::t ('http_username'); ?></label> + <label class="group-name" for="http_user"><?php echo Minz_Translate::t ('http_username'); ?></label> <div class="group-controls"> <input type="text" name="http_user" id="http_user" value="<?php echo $auth['username']; ?>" autocomplete="off" /> - <i class="icon i_help"></i> <?php echo Translate::t ('access_protected_feeds'); ?> + <?php echo FreshRSS_Themes::icon('help'); ?> <?php echo Minz_Translate::t ('access_protected_feeds'); ?> </div> - <label class="group-name" for="http_pass"><?php echo Translate::t ('http_password'); ?></label> + <label class="group-name" for="http_pass"><?php echo Minz_Translate::t ('http_password'); ?></label> <div class="group-controls"> <input type="password" name="http_pass" id="http_pass" value="<?php echo $auth['password']; ?>" autocomplete="off" /> </div> @@ -104,13 +112,13 @@ <div class="form-group form-actions"> <div class="group-controls"> - <button class="btn btn-important"><?php echo Translate::t ('save'); ?></button> - <button class="btn btn-attention confirm" formaction="<?php echo Url::display (array ('c' => 'feed', 'a' => 'delete', 'params' => array ('id' => $this->flux->id ()))); ?>"><?php echo Translate::t ('delete'); ?></button> + <button class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button> + <button class="btn btn-attention confirm" formmethod="post" formaction="<?php echo Minz_Url::display (array ('c' => 'feed', 'a' => 'delete', 'params' => array ('id' => $this->flux->id ()))); ?>"><?php echo Minz_Translate::t ('delete'); ?></button> </div> </div> </form> </div> <?php } else { ?> -<div class="alert alert-warn"><span class="alert-head"><?php echo Translate::t ('no_selected_feed'); ?></span> <?php echo Translate::t ('think_to_add'); ?></div> +<div class="alert alert-warn"><span class="alert-head"><?php echo Minz_Translate::t ('no_selected_feed'); ?></span> <?php echo Minz_Translate::t ('think_to_add'); ?></div> <?php } ?> diff --git a/app/views/configure/importExport.phtml b/app/views/configure/importExport.phtml index 4cc575356..29a0a682b 100644 --- a/app/views/configure/importExport.phtml +++ b/app/views/configure/importExport.phtml @@ -1,9 +1,9 @@ <?php if ($this->req == 'export') { ?> <?php echo '<?xml version="1.0" encoding="UTF-8" ?>'; // résout bug sur certain serveur ?> -<!-- Generated by <?php echo Configuration::title (); ?> --> +<!-- Generated by <?php echo Minz_Configuration::title (); ?> --> <opml version="2.0"> <head> - <title><?php echo Configuration::title (); ?> OPML Feed</title> + <title><?php echo Minz_Configuration::title (); ?> OPML Feed</title> <dateCreated><?php echo date('D, d M Y H:i:s'); ?></dateCreated> </head> <body> @@ -14,12 +14,12 @@ <?php $this->partial ('aside_feed'); ?> <div class="post "> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> - <form method="post" action="<?php echo Url::display (array ('c' => 'configure', 'a' => 'importExport', 'params' => array ('q' => 'import'))); ?>" enctype="multipart/form-data"> - <legend><?php echo Translate::t ('import_export_opml'); ?></legend> + <form method="post" action="<?php echo Minz_Url::display (array ('c' => 'configure', 'a' => 'importExport', 'params' => array ('q' => 'import'))); ?>" enctype="multipart/form-data"> + <legend><?php echo Minz_Translate::t ('import_export_opml'); ?></legend> <div class="form-group"> - <label class="group-name" for="file"><?php echo Translate::t ('file_to_import'); ?></label> + <label class="group-name" for="file"><?php echo Minz_Translate::t ('file_to_import'); ?></label> <div class="group-controls"> <input type="file" name="file" id="file" /> </div> @@ -27,9 +27,9 @@ <div class="form-group form-actions"> <div class="group-controls"> - <button type="submit" class="btn btn-important"><?php echo Translate::t ('import'); ?></button> - <?php echo Translate::t ('or'); ?> - <a target="_blank" class="btn btn-important" href="<?php echo _url ('configure', 'importExport', 'q', 'export'); ?>"><?php echo Translate::t ('export'); ?></a> + <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('import'); ?></button> + <?php echo Minz_Translate::t ('or'); ?> + <a target="_blank" class="btn btn-important" href="<?php echo _url ('configure', 'importExport', 'q', 'export'); ?>"><?php echo Minz_Translate::t ('export'); ?></a> </div> </div> </form> diff --git a/app/views/configure/sharing.phtml b/app/views/configure/sharing.phtml new file mode 100644 index 000000000..825537fc9 --- /dev/null +++ b/app/views/configure/sharing.phtml @@ -0,0 +1,64 @@ +<?php $this->partial ('aside_configure'); ?> + +<div class="post"> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> + + <form method="post" action="<?php echo _url ('configure', 'sharing'); ?>"> + <legend><?php echo Minz_Translate::t ('sharing'); ?></legend> + <div class="form-group"> + <label class="group-name" for="shaarli"> + <?php echo Minz_Translate::t ('your_shaarli'); ?> + </label> + <div class="group-controls"> + <input type="url" id="shaarli" name="shaarli" value="<?php echo $this->conf->sharing ('shaarli'); ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>" size="64" /> + + <?php echo FreshRSS_Themes::icon('help'); ?> <a target="_blank" href="http://sebsauvage.net/wiki/doku.php?id=php:shaarli"><?php echo Minz_Translate::t ('more_information'); ?></a> + </div> + </div> + + <div class="form-group"> + <label class="group-name" for="poche"> + <?php echo Minz_Translate::t ('your_poche'); ?> + </label> + <div class="group-controls"> + <input type="url" id="poche" name="poche" value="<?php echo $this->conf->sharing ('poche'); ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>" size="64" /> + + <?php echo FreshRSS_Themes::icon('help'); ?> <a target="_blank" href="http://www.inthepoche.com/"><?php echo Minz_Translate::t ('more_information'); ?></a> + </div> + </div> + + <div class="form-group"> + <label class="group-name" for="diaspora"> + <?php echo Minz_Translate::t ('your_diaspora_pod'); ?> + </label> + <div class="group-controls"> + <input type="url" id="diaspora" name="diaspora" value="<?php echo $this->conf->sharing ('diaspora'); ?>" placeholder="<?php echo Minz_Translate::t ('blank_to_disable'); ?>" size="64" /> + + <?php echo FreshRSS_Themes::icon('help'); ?> <a target="_blank" href="https://diasporafoundation.org/"><?php echo Minz_Translate::t ('more_information'); ?></a> + </div> + </div> + + <div class="form-group"> + <label class="group-name"><?php echo Minz_Translate::t ('activate_sharing'); ?></label> + <div class="group-controls"> + <?php + $services = array ('twitter', 'g+', 'facebook', 'email', 'print'); + + foreach ($services as $service) { + ?> + <label class="checkbox" for="<?php echo $service; ?>"> + <input type="checkbox" name="<?php echo $service; ?>" id="<?php echo $service; ?>" value="yes"<?php echo $this->conf->sharing ($service) ? ' checked="checked"' : ''; ?> /> + <?php echo Minz_Translate::t ($service); ?> + </label> + <?php } ?> + </div> + </div> + + <div class="form-group form-actions"> + <div class="group-controls"> + <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button> + <button type="reset" class="btn"><?php echo Minz_Translate::t ('cancel'); ?></button> + </div> + </div> + </form> +</div> diff --git a/app/views/configure/shortcut.phtml b/app/views/configure/shortcut.phtml index 01e66adb4..e78d91820 100644 --- a/app/views/configure/shortcut.phtml +++ b/app/views/configure/shortcut.phtml @@ -1,7 +1,7 @@ <?php $this->partial ('aside_configure'); ?> <div class="post"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> <datalist id="keys"> <?php foreach ($this->list_keys as $key) { ?> @@ -12,52 +12,66 @@ <?php $s = $this->conf->shortcuts (); ?> <form method="post" action="<?php echo _url ('configure', 'shortcut'); ?>"> - <legend><?php echo Translate::t ('shortcuts_management'); ?></legend> + <legend><?php echo Minz_Translate::t ('shortcuts_management'); ?></legend> - <noscript><p class="alert alert-error"><?php echo Translate::t ('javascript_for_shortcuts'); ?></p></noscript> + <noscript><p class="alert alert-error"><?php echo Minz_Translate::t ('javascript_for_shortcuts'); ?></p></noscript> <div class="form-group"> - <label class="group-name" for="mark_read"><?php echo Translate::t ('mark_read'); ?></label> + <label class="group-name" for="mark_read"><?php echo Minz_Translate::t ('mark_read'); ?></label> <div class="group-controls"> <input type="text" id="mark_read" name="shortcuts[mark_read]" list="keys" value="<?php echo $s['mark_read']; ?>" /> - <?php echo Translate::t ('shift_for_all_read'); ?> + <?php echo Minz_Translate::t ('shift_for_all_read'); ?> </div> </div> <div class="form-group"> - <label class="group-name" for="mark_favorite"><?php echo Translate::t ('mark_favorite'); ?></label> + <label class="group-name" for="mark_favorite"><?php echo Minz_Translate::t ('mark_favorite'); ?></label> <div class="group-controls"> <input type="text" id="mark_favorite" name="shortcuts[mark_favorite]" list="keys" value="<?php echo $s['mark_favorite']; ?>" /> </div> </div> <div class="form-group"> - <label class="group-name" for="go_website"><?php echo Translate::t ('see_on_website'); ?></label> + <label class="group-name" for="go_website"><?php echo Minz_Translate::t ('see_on_website'); ?></label> <div class="group-controls"> <input type="text" id="go_website" name="shortcuts[go_website]" list="keys" value="<?php echo $s['go_website']; ?>" /> </div> </div> <div class="form-group"> - <label class="group-name" for="next_entry"><?php echo Translate::t ('next_article'); ?></label> + <label class="group-name" for="next_entry"><?php echo Minz_Translate::t ('next_article'); ?></label> <div class="group-controls"> <input type="text" id="next_entry" name="shortcuts[next_entry]" list="keys" value="<?php echo $s['next_entry']; ?>" /> - <?php echo Translate::t ('shift_for_last'); ?> + <?php echo Minz_Translate::t ('shift_for_last'); ?> </div> </div> <div class="form-group"> - <label class="group-name" for="prev_entry"><?php echo Translate::t ('previous_article'); ?></label> + <label class="group-name" for="prev_entry"><?php echo Minz_Translate::t ('previous_article'); ?></label> <div class="group-controls"> <input type="text" id="prev_entry" name="shortcuts[prev_entry]" list="keys" value="<?php echo $s['prev_entry']; ?>" /> - <?php echo Translate::t ('shift_for_first'); ?> + <?php echo Minz_Translate::t ('shift_for_first'); ?> + </div> + </div> + + <div class="form-group"> + <label class="group-name" for="collapse_entry"><?php echo Minz_Translate::t ('collapse_article'); ?></label> + <div class="group-controls"> + <input type="text" id="collapse_entry" name="shortcuts[collapse_entry]" list="keys" value="<?php echo $s['collapse_entry']; ?>" /> + </div> + </div> + + <div class="form-group"> + <label class="group-name" for="load_more_shortcut"><?php echo Minz_Translate::t ('load_more'); ?></label> + <div class="group-controls"> + <input type="text" id="load_more_shortcut" name="shortcuts[load_more]" list="keys" value="<?php echo $s['load_more']; ?>" /> </div> </div> <div class="form-group form-actions"> <div class="group-controls"> - <button type="submit" class="btn btn-important"><?php echo Translate::t ('save'); ?></button> - <button type="reset" class="btn"><?php echo Translate::t ('cancel'); ?></button> + <button type="submit" class="btn btn-important"><?php echo Minz_Translate::t ('save'); ?></button> + <button type="reset" class="btn"><?php echo Minz_Translate::t ('cancel'); ?></button> </div> </div> </form> diff --git a/app/views/entry/bookmark.phtml b/app/views/entry/bookmark.phtml index 1ff1c220c..55b2d3d3d 100755 --- a/app/views/entry/bookmark.phtml +++ b/app/views/entry/bookmark.phtml @@ -1,15 +1,16 @@ <?php +header('Content-Type: application/json; charset=UTF-8'); -if (Request::param ('is_favorite')) { - Request::_param ('is_favorite', 0); +if (Minz_Request::param ('is_favorite')) { + Minz_Request::_param ('is_favorite', 0); } else { - Request::_param ('is_favorite', 1); + Minz_Request::_param ('is_favorite', 1); } -$url = Url::display (array ( - 'c' => Request::controllerName (), - 'a' => Request::actionName (), - 'params' => Request::params (), +$url = Minz_Url::display (array ( + 'c' => Minz_Request::controllerName (), + 'a' => Minz_Request::actionName (), + 'params' => Minz_Request::params (), )); -echo json_encode (array ('url' => str_ireplace ('&', '&', $url))); +echo json_encode (array ('url' => str_ireplace ('&', '&', $url), 'icon' => FreshRSS_Themes::icon(Minz_Request::param ('is_favorite') ? 'non-starred' : 'starred'))); diff --git a/app/views/entry/read.phtml b/app/views/entry/read.phtml index 6d3313a89..d063ba3d5 100755 --- a/app/views/entry/read.phtml +++ b/app/views/entry/read.phtml @@ -1,15 +1,16 @@ <?php +header('Content-Type: application/json; charset=UTF-8'); -if (Request::param ('is_read')) { - Request::_param ('is_read', 0); +if (Minz_Request::param ('is_read')) { + Minz_Request::_param ('is_read', 0); } else { - Request::_param ('is_read', 1); + Minz_Request::_param ('is_read', 1); } -$url = Url::display (array ( - 'c' => Request::controllerName (), - 'a' => Request::actionName (), - 'params' => Request::params (), +$url = Minz_Url::display (array ( + 'c' => Minz_Request::controllerName (), + 'a' => Minz_Request::actionName (), + 'params' => Minz_Request::params (), )); -echo json_encode (array ('url' => str_ireplace ('&', '&', $url))); +echo json_encode (array ('url' => str_ireplace ('&', '&', $url), 'icon' => FreshRSS_Themes::icon(Minz_Request::param ('is_read') ? 'unread' : 'read'))); diff --git a/app/views/error/index.phtml b/app/views/error/index.phtml index d5d090c72..36fcb56f9 100644 --- a/app/views/error/index.phtml +++ b/app/views/error/index.phtml @@ -3,8 +3,8 @@ <h1 class="alert-head"><?php echo $this->code; ?></h1> <p> - <?php echo Translate::t ('page_not_found'); ?><br /> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <?php echo Minz_Translate::t ('page_not_found'); ?><br /> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> </p> </div> </div> diff --git a/app/views/helpers/javascript_vars.phtml b/app/views/helpers/javascript_vars.phtml index 58cb3c5ac..0c1af45fc 100644 --- a/app/views/helpers/javascript_vars.phtml +++ b/app/views/helpers/javascript_vars.phtml @@ -2,12 +2,12 @@ echo '"use strict";', "\n"; $mark = $this->conf->markWhen (); echo 'var ', - 'hide_posts=', ($this->conf->displayPosts () === 'yes' || Request::param ('output') === 'reader') ? 'false' : 'true', + 'hide_posts=', ($this->conf->displayPosts () === 'yes' || Minz_Request::param ('output') === 'reader') ? 'false' : 'true', ',auto_mark_article=', $mark['article'] === 'yes' ? 'true' : 'false', ',auto_mark_site=', $mark['site'] === 'yes' ? 'true' : 'false', ',auto_mark_scroll=', $mark['scroll'] === 'yes' ? 'true' : 'false', ',auto_load_more=', $this->conf->autoLoadMore () === 'yes' ? 'true' : 'false', - ',full_lazyload=', $this->conf->lazyload () === 'yes' && ($this->conf->displayPosts () === 'yes' || Request::param ('output') === 'reader') ? 'true' : 'false', + ',full_lazyload=', $this->conf->lazyload () === 'yes' && ($this->conf->displayPosts () === 'yes' || Minz_Request::param ('output') === 'reader') ? 'true' : 'false', ',does_lazyload=', $this->conf->lazyload() === 'yes' ? 'true' : 'false'; $s = $this->conf->shortcuts (); @@ -16,10 +16,16 @@ 'mark_favorite:"', $s['mark_favorite'], '",', 'go_website:"', $s['go_website'], '",', 'prev_entry:"', $s['prev_entry'], '",', - 'next_entry:"', $s['next_entry'], '"', + 'next_entry:"', $s['next_entry'], '",', + 'collapse_entry:"', $s['collapse_entry'], '",', + 'load_more:"', $s['load_more'], '"', "},\n"; - $mail = Session::param ('mail', 'null'); + if (Minz_Request::param ('output') === 'global') { + echo "iconClose='", FreshRSS_Themes::icon('close'), "',\n"; + } + + $mail = Minz_Session::param ('mail', 'null'); if ($mail != 'null') { $mail = '"' . $mail . '"'; } @@ -29,11 +35,11 @@ 'url_logout="', _url ('index', 'logout'), '",', 'current_user_mail=', $mail, ",\n"; - echo 'load_shortcuts=', Request::controllerName () === 'index' && Request::actionName () === 'index' ? 'true' : 'false', ",\n"; + echo 'load_shortcuts=', Minz_Request::controllerName () === 'index' && Minz_Request::actionName () === 'index' ? 'true' : 'false', ",\n"; - echo 'str_confirmation="', Translate::t('confirm_action'), '"', ",\n"; + echo 'str_confirmation="', Minz_Translate::t('confirm_action'), '"', ",\n"; - echo 'auto_actualize_feeds=', Session::param('actualize_feeds', false) ? 'true' : 'false', ";\n"; - if (Session::param('actualize_feeds', false)) { - Session::_param('actualize_feeds'); + echo 'auto_actualize_feeds=', Minz_Session::param('actualize_feeds', false) ? 'true' : 'false', ";\n"; + if (Minz_Session::param('actualize_feeds', false)) { + Minz_Session::_param('actualize_feeds'); } diff --git a/app/views/helpers/logs_pagination.phtml b/app/views/helpers/logs_pagination.phtml index 9f1d6cb23..e3d14810e 100755 --- a/app/views/helpers/logs_pagination.phtml +++ b/app/views/helpers/logs_pagination.phtml @@ -1,7 +1,7 @@ <?php - $c = Request::controllerName (); - $a = Request::actionName (); - $params = Request::params (); + $c = Minz_Request::controllerName (); + $a = Minz_Request::actionName (); + $params = Minz_Request::params (); ?> <?php if ($this->nbPage > 1) { ?> @@ -9,14 +9,14 @@ <?php $params[$getteur] = 1; ?> <li class="item pager-first"> <?php if ($this->currentPage > 1) { ?> - <a href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>">« <?php echo Translate::t('first'); ?></a> + <a href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>">« <?php echo Minz_Translate::t('first'); ?></a> <?php } ?> </li> <?php $params[$getteur] = $this->currentPage - 1; ?> <li class="item pager-previous"> <?php if ($this->currentPage > 1) { ?> - <a href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>">‹ <?php echo Translate::t('previous'); ?></a> + <a href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>">‹ <?php echo Minz_Translate::t('previous'); ?></a> <?php } ?> </li> @@ -24,7 +24,7 @@ <?php if($i > 0 && $i <= $this->nbPage) { ?> <?php if ($i != $this->currentPage) { ?> <?php $params[$getteur] = $i; ?> - <li class="item pager-item"><a href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo $i; ?></a></li> + <li class="item pager-item"><a href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo $i; ?></a></li> <?php } else { ?> <li class="item pager-current"><?php echo $i; ?></li> <?php } ?> @@ -34,13 +34,13 @@ <?php $params[$getteur] = $this->currentPage + 1; ?> <li class="item pager-next"> <?php if ($this->currentPage < $this->nbPage) { ?> - <a href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Translate::t('next'); ?> ›</a> + <a href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Minz_Translate::t('next'); ?> ›</a> <?php } ?> </li> <?php $params[$getteur] = $this->nbPage; ?> <li class="item pager-last"> <?php if ($this->currentPage < $this->nbPage) { ?> - <a href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Translate::t('last'); ?> »</a> + <a href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Minz_Translate::t('last'); ?> »</a> <?php } ?> </li> </ul> diff --git a/app/views/helpers/pagination.phtml b/app/views/helpers/pagination.phtml index 0018a951e..d4983a32e 100755 --- a/app/views/helpers/pagination.phtml +++ b/app/views/helpers/pagination.phtml @@ -1,20 +1,26 @@ <?php - $c = Request::controllerName (); - $a = Request::actionName (); - $params = Request::params (); + $c = Minz_Request::controllerName (); + $a = Minz_Request::actionName (); + $params = Minz_Request::params (); + $markReadUrl = Minz_Session::param ('markReadUrl'); + Minz_Session::_param ('markReadUrl', false); ?> <ul class="pagination"> <li class="item pager-next"> - <?php if ($this->next != '') { ?> - <?php $params[$getteur] = $this->next; ?> - <a id="load_more" href="<?php echo Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Translate::t ('load_more'); ?></a> + <?php if (!empty($this->nextId)) { ?> + <?php $params['next'] = $this->nextId; ?> + <a id="load_more" href="<?php echo Minz_Url::display (array ('c' => $c, 'a' => $a, 'params' => $params)); ?>"><?php echo Minz_Translate::t ('load_more'); ?></a> + <?php } elseif ($markReadUrl) { ?> + <a id="bigMarkAsRead" href="<?php echo $markReadUrl; ?>"> + <?php echo Minz_Translate::t ('nothing_to_load'); ?><br /> + <span class="bigTick">✔</span><br /> + <?php echo Minz_Translate::t ('mark_all_read'); ?> + </a> <?php } else { ?> - <div class="bigMarkAsRead"> - <p><?php echo Translate::t ('nothing_to_load'); ?></p> - <p class="bigTick">✔</p> - <p><?php echo Translate::t ('mark_all_read'); ?></p> - </div> + <a id="bigMarkAsRead" href="."> + <?php echo Minz_Translate::t ('nothing_to_load'); ?><br /> + </a> <?php } ?> </li> </ul> diff --git a/app/views/helpers/view/global_view.phtml b/app/views/helpers/view/global_view.phtml index ae3bae9bc..bc6e24e37 100644 --- a/app/views/helpers/view/global_view.phtml +++ b/app/views/helpers/view/global_view.phtml @@ -9,18 +9,16 @@ <div class="box-category"> <div class="category"> <a data-unread="<?php echo $cat->nbNotRead (); ?>" class="btn" href="<?php echo _url ('index', 'index', 'get', 'c_' . $cat->id (), 'output', 'normal'); ?>"> - <?php echo htmlspecialchars($cat->name(), ENT_NOQUOTES, 'UTF-8'); ?> + <?php echo $cat->name(); ?> </a> </div> - <ul class="feeds"> <?php foreach ($feeds as $feed) { ?> <?php $not_read = $feed->nbNotRead (); ?> <li id="f_<?php echo $feed->id (); ?>" class="item<?php echo $feed->inError () ? ' error' : ''; ?><?php echo $feed->nbEntries () == 0 ? ' empty' : ''; ?>"> <img class="favicon" src="<?php echo $feed->favicon (); ?>" alt="✇" /> - <a class="feed" data-unread="<?php echo $feed->nbNotRead (); ?>" data-priority="<?php echo $feed->priority (); ?>" href="<?php echo _url ('index', 'index', 'get', 'f_' . $feed->id (), 'output', 'normal'); ?>"> - <?php echo htmlspecialchars($feed->name(), ENT_NOQUOTES, 'UTF-8'); ?> + <?php echo $feed->name(); ?> </a> </li> <?php } ?> @@ -34,5 +32,5 @@ <div id="overlay"></div> <div id="panel"<?php echo $this->conf->displayPosts () === 'no' ? ' class="hide_posts"' : ''; ?>> - <a class="close" href="#"><i class="icon i_close"></i></a> + <a class="close" href="#"><?php echo FreshRSS_Themes::icon('close'); ?></a> </div>
\ No newline at end of file diff --git a/app/views/helpers/view/normal_view.phtml b/app/views/helpers/view/normal_view.phtml index ad6154163..4307c2113 100644 --- a/app/views/helpers/view/normal_view.phtml +++ b/app/views/helpers/view/normal_view.phtml @@ -3,53 +3,72 @@ $this->partial ('aside_flux'); $this->partial ('nav_menu'); -if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { - $items = $this->entryPaginator->items (); +if (!empty($this->entries)) { + $display_today = true; + $display_yesterday = true; + $display_others = true; + + $logged = !login_is_conf ($this->conf) || is_logged (); + $shaarli = $this->conf->sharing ('shaarli'); + $poche = $this->conf->sharing ('poche'); + $diaspora = $this->conf->sharing ('diaspora'); + $twitter = $this->conf->sharing ('twitter'); + $google_plus = $this->conf->sharing ('g+'); + $facebook = $this->conf->sharing ('facebook'); + $email = $this->conf->sharing ('email'); + $print = $this->conf->sharing ('print'); + $today = $this->today; + $hidePosts = $this->conf->displayPosts() === 'no'; + $lazyload = $this->conf->lazyload() === 'yes'; ?> -<div id="stream" class="normal<?php echo $this->conf->displayPosts () === 'no' ? ' hide_posts' : ''; ?>"> - <?php - $display_today = true; - $display_yesterday = true; - $display_others = true; - ?> - <?php foreach ($items as $item) { ?> +<div id="stream" class="normal<?php echo $hidePosts ? ' hide_posts' : ''; ?>"> + <?php foreach ($this->entries as $item) { ?> - <?php if ($display_today && $item->isDay (Days::TODAY)) { ?> + <?php if ($display_today && $item->isDay (FreshRSS_Days::TODAY, $today)) { ?> <div class="day" id="day_today"> - <?php echo Translate::t ('today'); ?> + <?php echo Minz_Translate::t ('today'); ?> <span class="date"> - <?php echo timestamptodate (time (), false); ?></span> <span class="name"><?php echo $this->currentName; ?></span> </div> <?php $display_today = false; } ?> - <?php if ($display_yesterday && $item->isDay (Days::YESTERDAY)) { ?> + <?php if ($display_yesterday && $item->isDay (FreshRSS_Days::YESTERDAY, $today)) { ?> <div class="day" id="day_yesterday"> - <?php echo Translate::t ('yesterday'); ?> + <?php echo Minz_Translate::t ('yesterday'); ?> <span class="date"> - <?php echo timestamptodate (time () - 86400, false); ?></span> <span class="name"><?php echo $this->currentName; ?></span> </div> <?php $display_yesterday = false; } ?> - <?php if ($display_others && $item->isDay (Days::BEFORE_YESTERDAY)) { ?> + <?php if ($display_others && $item->isDay (FreshRSS_Days::BEFORE_YESTERDAY, $today)) { ?> <div class="day" id="day_before_yesterday"> - <?php echo Translate::t ('before_yesterday'); ?> + <?php echo Minz_Translate::t ('before_yesterday'); ?> <span class="name"><?php echo $this->currentName; ?></span> </div> <?php $display_others = false; } ?> <div class="flux<?php echo !$item->isRead () ? ' not_read' : ''; ?><?php echo $item->isFavorite () ? ' favorite' : ''; ?>" id="flux_<?php echo $item->id (); ?>"> - <ul class="horizontal-list flux_header"> - <?php if (!login_is_conf ($this->conf) || is_logged ()) { ?> - <?php if ($this->conf->toplineRead ()) { ?><li class="item manage"><a class="read" href="<?php echo _url ('entry', 'read', 'id', $item->id (), 'is_read', $item->isRead () ? 0 : 1); ?>"> </a></li><?php } ?> - <?php if ($this->conf->toplineFavorite ()) { ?><li class="item manage"><a class="bookmark" href="<?php echo _url ('entry', 'bookmark', 'id', $item->id (), 'is_favorite', $item->isFavorite () ? 0 : 1); ?>"> </a></li><?php } ?> - <?php + <ul class="horizontal-list flux_header"><?php + if ($logged) { + if ($this->conf->toplineRead ()) { + ?><li class="item manage"><?php + ?><a class="read" href="<?php echo _url ('entry', 'read', 'id', $item->id (), 'is_read', $item->isRead () ? 0 : 1); ?>"><?php + echo FreshRSS_Themes::icon($item->isRead () ? 'read' : 'unread'); ?></a><?php + ?></li><?php + } + if ($this->conf->toplineFavorite ()) { + ?><li class="item manage"><?php + ?><a class="bookmark" href="<?php echo _url ('entry', 'bookmark', 'id', $item->id (), 'is_favorite', $item->isFavorite () ? 0 : 1); ?>"><?php + echo FreshRSS_Themes::icon($item->isFavorite () ? 'starred' : 'non-starred'); ?></a><?php + ?></li><?php } - $feed = HelperCategory::findFeed($this->cat_aside, $item->feed ()); //We most likely already have the feed object in cache - if (empty($feed)) $feed = $item->feed (true); + } + $feed = FreshRSS_CategoryDAO::findFeed($this->cat_aside, $item->feed ()); //We most likely already have the feed object in cache + if (empty($feed)) $feed = $item->feed (true); ?> - <li class="item website"><a href="<?php echo _url ('index', 'index', 'get', 'f_' . $feed->id ()); ?>"><img class="favicon" src="<?php echo $feed->favicon (); ?>" alt="✇" /> <span><?php echo htmlspecialchars($feed->name(), ENT_NOQUOTES, 'UTF-8'); ?></span></a></li> + <li class="item website"><a href="<?php echo _url ('index', 'index', 'get', 'f_' . $feed->id ()); ?>"><img class="favicon" src="<?php echo $feed->favicon (); ?>" alt="✇" /> <span><?php echo $feed->name(); ?></span></a></li> <li class="item title"><a target="_blank" href="<?php echo $item->link (); ?>"><?php echo $item->title (); ?></a></li> - <?php if ($this->conf->toplineDate ()) { ?><li class="item date"><?php echo $item->date (); ?> </li><?php } ?> - <?php if ($this->conf->toplineLink ()) { ?><li class="item link"><a target="_blank" href="<?php echo $item->link (); ?>"> </a></li><?php } ?> + <?php if ($this->conf->toplineDate ()) { ?><li class="item date"><?php echo $item->date (); ?> </li><?php } ?> + <?php if ($this->conf->toplineLink ()) { ?><li class="item link"><a target="_blank" href="<?php echo $item->link (); ?>"><?php echo FreshRSS_Themes::icon('link'); ?></a></li><?php } ?> </ul> <div class="flux_content"> @@ -57,64 +76,99 @@ if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { <h1 class="title"><?php echo $item->title (); ?></h1> <?php $author = $item->author (); - echo $author != '' ? '<div class="author">' . Translate::t ('by_author', $author) . '</div>' : ''; - if($this->conf->lazyload() == 'yes') { - echo lazyimg($item->content ()); + echo $author != '' ? '<div class="author">' . Minz_Translate::t ('by_author', $author) . '</div>' : ''; + if ($lazyload) { + echo $hidePosts ? lazyIframe(lazyimg($item->content())) : lazyimg($item->content()); } else { echo $item->content(); } ?> </div> - - <ul class="horizontal-list bottom"> - <?php if (!login_is_conf ($this->conf) || is_logged ()) { ?> - <?php if ($this->conf->bottomlineRead ()) { ?><li class="item manage"><a class="read" href="<?php echo _url ('entry', 'read', 'id', $item->id (), 'is_read', $item->isRead () ? 0 : 1); ?>"> </a></li><?php } ?> - <?php if ($this->conf->bottomlineFavorite ()) { ?><li class="item manage"><a class="bookmark" href="<?php echo _url ('entry', 'bookmark', 'id', $item->id (), 'is_favorite', $item->isFavorite () ? 0 : 1); ?>"> </a></li><?php } ?> - <?php } ?> + <ul class="horizontal-list bottom"><?php + if ($logged) { + if ($this->conf->bottomlineRead ()) { + ?><li class="item manage"><?php + ?><a class="read" href="<?php echo _url ('entry', 'read', 'id', $item->id (), 'is_read', $item->isRead () ? 0 : 1); ?>"><?php + echo FreshRSS_Themes::icon($item->isRead () ? 'read' : 'unread'); ?></a><?php + ?></li><?php + } + if ($this->conf->bottomlineFavorite ()) { + ?><li class="item manage"><?php + ?><a class="bookmark" href="<?php echo _url ('entry', 'bookmark', 'id', $item->id (), 'is_favorite', $item->isFavorite () ? 0 : 1); ?>"><?php + echo FreshRSS_Themes::icon($item->isFavorite () ? 'starred' : 'non-starred'); ?></a><?php + ?></li><?php + } + } ?> <li class="item"> <?php - if ($this->conf->bottomlineSharing ()) { + if ($this->conf->bottomlineSharing () && ( + $shaarli || $poche || $diaspora || $twitter || + $google_plus || $facebook || $email + )) { $link = urlencode ($item->link ()); $title = urlencode ($item->title () . ' - ' . $feed->name ()); ?> - <div class="dropdown"> + <div class="dropdown"> <div id="dropdown-share-<?php echo $item->id ();?>" class="dropdown-target"></div> - <i class="icon i_share"></i> <a class="dropdown-toggle" href="#dropdown-share-<?php echo $item->id ();?>"><?php echo Translate::t ('share'); ?></a> + <a class="dropdown-toggle" href="#dropdown-share-<?php echo $item->id ();?>"> + <?php echo FreshRSS_Themes::icon('share'); ?> + <?php echo Minz_Translate::t ('share'); ?> + </a> <ul class="dropdown-menu"> - <li class="dropdown-close"><a href="#close"> </a></li> - <?php - $shaarli = $this->conf->urlShaarli (); - if ((!login_is_conf ($this->conf) || is_logged ()) && $shaarli) { - ?> + <li class="dropdown-close"><a href="#close">❌</a></li> + <?php if ($logged && $shaarli) { ?> <li class="item"> - <a target="_blank" href="<?php echo $shaarli . '?post=' . $link . '&title=' . $title . '&source=bookmarklet'; ?>"> - Shaarli + <a target="_blank" href="<?php echo $shaarli . '?post=' . $link . '&title=' . $title . '&source=FreshRSS'; ?>"> + <?php echo Minz_Translate::t ('shaarli'); ?> </a> </li> - <?php } ?> + <?php } if ($logged && $poche) { ?> <li class="item"> - <a href="mailto:?subject=<?php echo urldecode($title); ?>&body=<?php echo $link; ?>"> - <?php echo Translate::t ('by_email'); ?> + <a target="_blank" href="<?php echo $poche . '?action=add&url=' . base64_encode (urldecode($link)); ?>"> + <?php echo Minz_Translate::t ('poche'); ?> + </a> + </li> + <?php } if ($logged && $diaspora) { ?> + <li class="item"> + <a target="_blank" href="<?php echo $diaspora . '/bookmarklet?url=' . $link . '&title=' . $title; ?>"> + <?php echo Minz_Translate::t ('diaspora'); ?> </a> </li> + <?php } if ($twitter) { ?> <li class="item"> <a target="_blank" href="https://twitter.com/share?url=<?php echo $link; ?>&text=<?php echo $title; ?>"> - Twitter + <?php echo Minz_Translate::t ('twitter'); ?> </a> </li> + <?php } if ($google_plus) { ?> + <li class="item"> + <a target="_blank" href="https://plus.google.com/share?url=<?php echo $link; ?>"> + <?php echo Minz_Translate::t ('g+'); ?> + </a> + </li> + <?php } if ($facebook) { ?> <li class="item"> <a target="_blank" href="https://www.facebook.com/sharer.php?u=<?php echo $link; ?>&t=<?php echo $title; ?>"> - Facebook + <?php echo Minz_Translate::t ('facebook'); ?> </a> </li> + <?php } if ($email) { ?> <li class="item"> - <a target="_blank" href="https://plus.google.com/share?url=<?php echo $link; ?>"> - Google+ + <a href="mailto:?subject=<?php echo urldecode($title); ?>&body=<?php echo $link; ?>"> + <?php echo Minz_Translate::t ('by_email'); ?> </a> </li> + <?php } if ($print) { ?> + <li class="item"> + <a href="#" class="print-article"> + <?php echo Minz_Translate::t ('print'); ?> + </a> + </li> + <?php } ?> </ul> - </div><?php } ?> + </div> + <?php } ?> </li> <?php $tags = $this->conf->bottomlineTags () ? $item->tags() : null; @@ -123,9 +177,12 @@ if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { <li class="item"> <div class="dropdown"> <div id="dropdown-tags-<?php echo $item->id ();?>" class="dropdown-target"></div> - <i class="icon i_tag"></i> <a class="dropdown-toggle" href="#dropdown-tags-<?php echo $item->id ();?>"><?php echo Translate::t ('related_tags'); ?></a> + <a class="dropdown-toggle" href="#dropdown-tags-<?php echo $item->id ();?>"> + <?php echo FreshRSS_Themes::icon('tag'); ?> + <?php echo Minz_Translate::t ('related_tags'); ?> + </a> <ul class="dropdown-menu"> - <li class="dropdown-close"><a href="#close"> </a></li> + <li class="dropdown-close"><a href="#close">❌</a></li> <?php foreach($tags as $tag) { ?> <li class="item"><a href="<?php echo _url ('index', 'index', 'search', urlencode ('#' . $tag)); ?>"><?php echo $tag; ?></a></li> <?php } ?> @@ -133,20 +190,20 @@ if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { </div> </li> <?php } ?> - <?php if ($this->conf->bottomlineDate ()) { ?><li class="item date"><?php echo $item->date (); ?> </li><?php } ?> - <?php if ($this->conf->bottomlineLink ()) { ?><li class="item link"><a target="_blank" href="<?php echo $item->link (); ?>"> </a></li><?php } ?> + <?php if ($this->conf->bottomlineDate ()) { ?><li class="item date"><?php echo $item->date (); ?> </li><?php } ?> + <?php if ($this->conf->bottomlineLink ()) { ?><li class="item link"><a target="_blank" href="<?php echo $item->link (); ?>"><?php echo FreshRSS_Themes::icon('link'); ?></a></li><?php } ?> </ul> </div> </div> <?php } ?> - <?php $this->entryPaginator->render ('pagination.phtml', 'next'); ?> + <?php $this->renderHelper('pagination'); ?> </div> <?php $this->partial ('nav_entries'); ?> <?php } else { ?> <div id="stream" class="alert alert-warn normal"> - <span class="alert-head"><?php echo Translate::t ('no_feed_to_display'); ?></span> + <span class="alert-head"><?php echo Minz_Translate::t ('no_feed_to_display'); ?></span> </div> <?php } ?>
\ No newline at end of file diff --git a/app/views/helpers/view/reader_view.phtml b/app/views/helpers/view/reader_view.phtml index f808990f7..47254f74e 100644 --- a/app/views/helpers/view/reader_view.phtml +++ b/app/views/helpers/view/reader_view.phtml @@ -1,33 +1,33 @@ <?php $this->partial ('nav_menu'); -if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { - $items = $this->entryPaginator->items (); +if (!empty($this->entries)) { + $lazyload = $this->conf->lazyload() === 'yes'; ?> <div id="stream" class="reader"> - <?php foreach ($items as $item) { ?> + <?php foreach ($this->entries as $item) { ?> <div class="flux<?php echo !$item->isRead () ? ' not_read' : ''; ?><?php echo $item->isFavorite () ? ' favorite' : ''; ?>" id="flux_<?php echo $item->id (); ?>"> <div class="flux_content"> <div class="content"> <?php - $feed = HelperCategory::findFeed($this->cat_aside, $item->feed ()); //We most likely already have the feed object in cache + $feed = FreshRSS_CategoryDAO::findFeed($this->cat_aside, $item->feed ()); //We most likely already have the feed object in cache if (empty($feed)) $feed = $item->feed (true); ?> <a href="<?php echo $item->link (); ?>"> - <img class="favicon" src="<?php echo $feed->favicon (); ?>" alt="✇" /> <span><?php echo htmlspecialchars($feed->name(), ENT_NOQUOTES, 'UTF-8'); ?></span> + <img class="favicon" src="<?php echo $feed->favicon (); ?>" alt="✇" /> <span><?php echo $feed->name(); ?></span> </a> <h1 class="title"><?php echo $item->title (); ?></h1> <div class="author"> <?php $author = $item->author (); ?> - <?php echo $author != '' ? Translate::t ('by_author', $author) . ' - ' : ''; ?> + <?php echo $author != '' ? Minz_Translate::t ('by_author', $author) . ' - ' : ''; ?> <?php echo $item->date (); ?> </div> <?php - if($this->conf->lazyload() == 'yes') { + if ($lazyload) { echo lazyimg($item->content ()); } else { echo $item->content(); @@ -38,11 +38,11 @@ if (isset ($this->entryPaginator) && !$this->entryPaginator->isEmpty ()) { </div> <?php } ?> - <?php $this->entryPaginator->render ('pagination.phtml', 'next'); ?> + <?php $this->renderHelper('pagination'); ?> </div> <?php } else { ?> <div id="stream" class="alert alert-warn reader"> - <span class="alert-head"><?php echo Translate::t ('no_feed_to_display'); ?></span> + <span class="alert-head"><?php echo Minz_Translate::t ('no_feed_to_display'); ?></span> </div> <?php } ?>
\ No newline at end of file diff --git a/app/views/helpers/view/rss_view.phtml b/app/views/helpers/view/rss_view.phtml index 9358ef2a5..620bf1388 100755 --- a/app/views/helpers/view/rss_view.phtml +++ b/app/views/helpers/view/rss_view.phtml @@ -2,17 +2,16 @@ <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/"> <channel> <title><?php echo $this->rss_title; ?></title> - <link><?php echo Url::display(null, 'html', true); ?></link> - <description><?php echo Translate::t ('rss_feeds_of', $this->rss_title); ?></description> + <link><?php echo Minz_Url::display(null, 'html', true); ?></link> + <description><?php echo Minz_Translate::t ('rss_feeds_of', $this->rss_title); ?></description> <pubDate><?php echo date('D, d M Y H:i:s O'); ?></pubDate> <lastBuildDate><?php echo gmdate('D, d M Y H:i:s'); ?> GMT</lastBuildDate> - <atom:link href="<?php echo Url::display ($this->rss_url, 'html', true); ?>" rel="self" type="application/rss+xml" /> + <atom:link href="<?php echo Minz_Url::display ($this->rss_url, 'html', true); ?>" rel="self" type="application/rss+xml" /> <?php -$items = $this->entryPaginator->items (); -foreach ($items as $item) { +foreach ($this->entries as $item) { ?> <item> - <title><?php echo htmlspecialchars(html_entity_decode($item->title (), ENT_NOQUOTES, 'UTF-8'), ENT_NOQUOTES, 'UTF-8'); ?></title> + <title><?php echo $item->title (); ?></title> <link><?php echo $item->link (); ?></link> <?php $author = $item->author (); ?> <?php if ($author != '') { ?> diff --git a/app/views/index/about.phtml b/app/views/index/about.phtml index ca1254053..b5c00a1ed 100644 --- a/app/views/index/about.phtml +++ b/app/views/index/about.phtml @@ -1,24 +1,24 @@ <div class="post content"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> - <h1><?php echo Translate::t ('about_freshrss'); ?></h1> + <h1><?php echo Minz_Translate::t ('about_freshrss'); ?></h1> <dl class="infos"> - <dt><?php echo Translate::t ('project_website'); ?></dt> - <dd><a href="http://marienfressinaud.github.io/FreshRSS/">http://marienfressinaud.github.io/FreshRSS/</a></dd> + <dt><?php echo Minz_Translate::t ('project_website'); ?></dt> + <dd><a href="<?php echo FRESHRSS_WEBSITE; ?>"><?php echo FRESHRSS_WEBSITE; ?></a></dd> - <dt><?php echo Translate::t ('lead_developer'); ?></dt> - <dd><a href="mailto:contact@marienfressinaud.fr">Marien Fressinaud</a> - <a href="http://marienfressinaud.fr"><?php echo Translate::t ('website'); ?></a></dd> + <dt><?php echo Minz_Translate::t ('lead_developer'); ?></dt> + <dd><a href="mailto:contact@marienfressinaud.fr">Marien Fressinaud</a> - <a href="http://marienfressinaud.fr"><?php echo Minz_Translate::t ('website'); ?></a></dd> - <dt><?php echo Translate::t ('bugs_reports'); ?></dt> - <dd><?php echo Translate::t ('github_or_email'); ?></dd> + <dt><?php echo Minz_Translate::t ('bugs_reports'); ?></dt> + <dd><?php echo Minz_Translate::t ('github_or_email'); ?></dd> - <dt><?php echo Translate::t ('license'); ?></dt> - <dd><?php echo Translate::t ('agpl3'); ?></dd> + <dt><?php echo Minz_Translate::t ('license'); ?></dt> + <dd><?php echo Minz_Translate::t ('agpl3'); ?></dd> </dl> - <p><?php echo Translate::t ('freshrss_description'); ?></p> + <p><?php echo Minz_Translate::t ('freshrss_description'); ?></p> - <h1><?php echo Translate::t ('credits'); ?></h1> - <p><?php echo Translate::t ('credits_content'); ?></p> + <h1><?php echo Minz_Translate::t ('credits'); ?></h1> + <p><?php echo Minz_Translate::t ('credits_content'); ?></p> </div> diff --git a/app/views/index/index.phtml b/app/views/index/index.phtml index bd18d2d77..cf98060c4 100644 --- a/app/views/index/index.phtml +++ b/app/views/index/index.phtml @@ -1,8 +1,8 @@ <?php -$output = Request::param ('output', 'normal'); +$output = Minz_Request::param ('output', 'normal'); $token = $this->conf->token(); -$token_param = Request::param ('token', ''); +$token_param = Minz_Request::param ('token', ''); $token_is_ok = ($token != '' && $token == $token_param); if(!login_is_conf ($this->conf) || @@ -21,9 +21,9 @@ if(!login_is_conf ($this->conf) || } else { ?> <div class="post content"> - <h1><?php echo Translate::t ('forbidden_access'); ?></h1> - <p><?php echo Translate::t ('forbidden_access_description'); ?></p> - <p><a href="<?php echo _url ('index', 'about'); ?>"><?php echo Translate::t ('about_freshrss'); ?></a></p> + <h1><?php echo Minz_Translate::t ('forbidden_access'); ?></h1> + <p><?php echo Minz_Translate::t ('forbidden_access_description'); ?></p> + <p><a href="<?php echo _url ('index', 'about'); ?>"><?php echo Minz_Translate::t ('about_freshrss'); ?></a></p> </div> <?php }
\ No newline at end of file diff --git a/app/views/index/logs.phtml b/app/views/index/logs.phtml index 09f0c4ecd..1b77b39af 100644 --- a/app/views/index/logs.phtml +++ b/app/views/index/logs.phtml @@ -1,21 +1,25 @@ <div class="post content"> - <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Translate::t ('back_to_rss_feeds'); ?></a> + <a href="<?php echo _url ('index', 'index'); ?>"><?php echo Minz_Translate::t ('back_to_rss_feeds'); ?></a> - <h1><?php echo Translate::t ('logs'); ?></h1> + <h1><?php echo Minz_Translate::t ('logs'); ?></h1> + <form method="post" action="<?php echo _url ('index', 'logs'); ?>"><p> + <input type="hidden" name="clearLogs" /> + <button type="submit" class="btn"><?php echo Minz_Translate::t ('clear_logs'); ?></button> + </p></form> <?php $items = $this->logsPaginator->items (); ?> <?php if (!empty ($items)) { ?> <div class="logs"> <?php $this->logsPaginator->render ('logs_pagination.phtml', 'page'); ?> - + <?php foreach ($items as $log) { ?> - <div class="log <?php echo $log->level (); ?>"><span class="date"><?php echo date ('d/m/Y - H:i:s', strtotime ($log->date ())); ?></span><?php echo htmlspecialchars ($log->info (), ENT_NOQUOTES, 'UTF-8'); ?></div> + <div class="log <?php echo $log->level (); ?>"><span class="date"><?php echo @date ('Y-m-d H:i:s', @strtotime ($log->date ())); ?></span><?php echo htmlspecialchars ($log->info (), ENT_NOQUOTES, 'UTF-8'); ?></div> <?php } ?> - + <?php $this->logsPaginator->render ('logs_pagination.phtml','page'); ?> </div> <?php } else { ?> - <p class="alert alert-warn"><?php echo Translate::t ('logs_empty'); ?></p> + <p class="alert alert-warn"><?php echo Minz_Translate::t ('logs_empty'); ?></p> <?php } ?> </div> diff --git a/app/views/javascript/actualize.phtml b/app/views/javascript/actualize.phtml index f39540a9a..69689133c 100644 --- a/app/views/javascript/actualize.phtml +++ b/app/views/javascript/actualize.phtml @@ -1,12 +1,12 @@ var feeds = new Array (); <?php foreach ($this->feeds as $feed) { ?> -feeds.push ("<?php echo Url::display (array ('c' => 'feed', 'a' => 'actualize', 'params' => array ('id' => $feed->id (), 'ajax' => '1')), 'php'); ?>"); +feeds.push ("<?php echo Minz_Url::display (array ('c' => 'feed', 'a' => 'actualize', 'params' => array ('id' => $feed->id (), 'ajax' => '1')), 'php'); ?>"); <?php } ?> function initProgressBar (init) { if (init) { $("body").after ("\<div id=\"actualizeProgress\" class=\"actualizeProgress\">\ - <?php echo Translate::t ('refresh'); ?> <span class=\"progress\">0 / " + feeds.length + "</span><br />\ + <?php echo Minz_Translate::t ('refresh'); ?> <span class=\"progress\">0 / " + feeds.length + "</span><br />\ <progress id=\"actualizeProgressBar\" value=\"0\" max=\"" + feeds.length + "\"></progress>\ </div>"); } else { |
