function connect_node_functions_form() { drupal_add_css(drupal_get_path('module', 'connect') . '/connect.css'); $child = array(); $options = array(); $p_nid = arg(1); $parent = node_load($p_nid); // determine possible and enabled actions $requirements_OK = TRUE; $actions = connect_get_actions($parent->nid); $action_list = module_invoke_all('connect'); unset($action_list['connect_action_basic']); foreach ($action_list as $function => $action) { $status = ''; if (in_array($function, $actions)) { if (TRUE === _connect_hook_check_requirements($parent, $child, $function, 'parent')) { $status = ' ' . theme_image(drupal_get_path('module', 'connect') . '/images/accept.png', '(ACTIVE)', 'This function is active.'); } else { $requirements_OK = FALSE; $status = ' ' . theme_image(drupal_get_path('module', 'connect') . '/images/exclamation.png', '(INACTIVE)', 'This function is not active. Please check the settings tab.'); } } $options[$function] = $action['title'] . $status . '<p class="connect-comment">' . $action['desc'] . '</p>'; } if (!$requirements_OK) { drupal_set_message('One or more of your selected functions requires additional settings to be configured.<br />Please check the settings tab for details.', 'error'); } $form = array(); $form['parent_id'] = array('#type' => 'value', '#value' => $parent->nid); $form['connect_actions'] = array('#type' => 'fieldset', '#title' => 'Choose functions to apply to this campaign'); $form['connect_actions']['actions'] = array('#type' => 'checkboxes', '#title' => '', '#options' => $options, '#default_value' => $actions); $form['submit'] = array('#type' => 'submit', '#value' => t('Submit')); return $form; }
function hook_article_button($line) { if (!get_pref($this->link, "COMBINED_DISPLAY_MODE")) { $rv = "<img src=\"" . theme_image($this->link, 'plugins/close_button/button.png') . "\"\n\t\t\t\tclass='tagsPic' style=\"cursor : pointer\"\n\t\t\t\tonclick=\"closeArticlePanel()\"\n\t\t\t\ttitle='" . __('Close article') . "'>"; } return $rv; }
function blocnotes($typeBlocNote = "shared", $nomBlocNote = "", $largeur = "100%", $nblBlocNote = "5", $gifbgcolor = "", $affiche = true) { global $REQUEST_URI; if ($typeBlocNote == "shared") { if ($nomBlocNote == "\$username") { global $cookie; $nomBlocNote = $cookie[1]; } $bouton = ""; $bnid = md5($nomBlocNote); } elseif ($typeBlocNote == "context") { if ($nomBlocNote == "\$username") { global $cookie, $admin; $nomBlocNote = $cookie[1]; $cur_admin = explode(":", base64_decode($admin)); if ($cur_admin) { $nomBlocNote = $cur_admin[0]; } } if (stristr($REQUEST_URI, "article.php")) { $bnid = md5($nomBlocNote . substr($REQUEST_URI, 0, strpos($REQUEST_URI, "&"))); } else { $bnid = md5($nomBlocNote . $REQUEST_URI); } } else { $nomBlocNote = ""; } if ($nomBlocNote) { global $theme; if ($affiche) { $aff = "<style type=\"text/css\">"; if (@file_exists("themes/{$theme}/style/bloc-note.css")) { $aff .= file_get_contents("themes/{$theme}/style/bloc-note.css"); } else { $aff .= file_get_contents("modules/bloc-notes/bloc-note.css"); } $aff .= "</style>"; } else { $aff = ""; } $aff .= "<table width=\"" . $largeur . "\" border=\"0\" cellspacing=\"1\" cellpadding=\"1\"><tr align=\"center\" valign=\"middle\"><td>"; $aff .= "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">"; if ($affiche) { $aff .= "\n <tr>\n <td class=\"bn_head_g\" valign=\"middle\"> {$nomBlocNote}</td>\n <td width=\"51\" height=\"20\">"; if ($ibid = theme_image("modules/bloc-note.gif")) { $imgtmpPI = $ibid; } else { $imgtmpPI = "modules/bloc-notes/bloc-note.gif"; } $aff .= "<img src=\"{$imgtmpPI}\" alt=\"\"></td>\n </tr>"; } $aff .= "\n <tr valign=\"top\">\n <td colspan=\"2\" class=\"bn_corps\">\n <form method=\"post\" action=\"modules.php?ModPath=bloc-notes&ModStart=blocnotes\" name=\"A" . $bnid . "\">" . "<textarea class=\"bn_textbox_no_mceEditor\" cols=\"20\" rows=\"" . $nblBlocNote . "\" name=\"texteBlocNote\" ></textarea><br />\n <input type=\"hidden\" name=\"uriBlocNote\" value=\"" . urlencode($REQUEST_URI) . "\" />\n <input type=\"hidden\" name=\"typeBlocNote\" value=\"" . $typeBlocNote . "\" />\n <input type=\"hidden\" name=\"nomBlocNote\" value=\"" . $nomBlocNote . "\" />\n <input type=\"submit\" name=\"okBlocNote\" value=\"Ok\" class=\"bouton_standard bn_bouton_standard\" /> <input type=\"submit\" name=\"supBlocNote\" value=\"RAZ\" class=\"bouton_standard bn_bouton_standard\" />\n </form><script type=\"text/javascript\" src=\"modules.php?ModPath=bloc-notes&ModStart=blocnotes-read&bnid=" . $bnid . "\"></script>\n </td>\n </tr><tr><td colspan=\"2\" class=\"bn_foot\"> </td></tr>\n </table>\n"; $aff .= "</td></tr></table>"; } if ($affiche) { themesidebox("no-title", $aff); } else { return $aff; } }
function theme_header($pageid, $title, $include_menu, $mode, $user_id) { global $PHP_SELF; global $HTTP_VARS; global $ADMIN_TYPE; if ($pageid == 'install') { $pageTitle = get_opendb_title_and_version() . " Installation"; } else { $pageTitle = get_opendb_title(); } echo "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">" . "\n<html>" . "\n<head>" . "\n<title>" . $pageTitle . (!empty($title) ? " - {$title}" : "") . "</title>" . "\n<meta http-equiv=\"Content-Type\" content=\"" . get_content_type_charset() . "\">" . "\n<link rel=\"icon\" href=\"" . theme_image_src("icon-16x16.png") . "\" type=\"image/png\" />" . "\n<link rel=\"search\" type=\"application/opensearchdescription+xml\" title=\"" . get_opendb_title() . " Title Search\" href=\"./searchplugins.php?type=title\">" . "\n<link rel=\"search\" type=\"application/opensearchdescription+xml\" title=\"" . get_opendb_title() . " UPC Search\" href=\"./searchplugins.php?type=upc\">" . get_theme_css($pageid, $mode) . get_opendb_rss_feeds_links() . get_theme_javascript($pageid) . "</head>" . "\n<body>"; echo "<div id=\"header\">"; echo "<h1><a href=\"index.php\">" . $pageTitle . "</a></h1>"; if ($include_menu) { echo "<ul class=\"headerLinks\">"; $help_page = get_opendb_help_page($pageid); if ($help_page != NULL) { echo "<li class=\"help\"><a href=\"help.php?page=" . $help_page . "\" target=\"_new\" title=\"" . get_opendb_lang_var('help') . "\">" . theme_image("help.png") . "</a></li>"; } $printable_page_url = get_printable_page_url($pageid); if ($printable_page_url != NULL) { echo "<li><a href=\"" . $printable_page_url . "\" target=\"_new\" title=\"" . get_opendb_lang_var('printable_version') . "\">" . theme_image("printable.gif") . "</a></li>"; } if (is_exists_my_reserve_basket($user_id)) { echo "<li><a href=\"borrow.php?op=my_reserve_basket\">" . theme_image("basket.png", get_opendb_lang_var('item_reserve_list')) . "</a></li>"; } if (is_user_granted_permission(PERM_VIEW_LISTINGS, NULL, TRUE)) { echo "<li><form class=\"quickSearch\" action=\"listings.php\">" . "<input type=\"hidden\" name=\"search_list\" value=\"y\">" . "<input type=\"hidden\" name=\"title_match\" value=\"partial\">" . "<input type=\"text\" class=\"text\" name=\"title\" size=\"10\" value=\"Title Search\" onfocus=\"if(this.value=='Title Search'){this.value='';this.style.color='black';}\" onblur=\"if(this.value==''){this.value='Title Search';this.style.color='gray';}\">" . "</form></li>"; } if (is_user_granted_permission(PERM_VIEW_ADVANCED_SEARCH, NULL, TRUE)) { echo "<li><a href=\"search.php\" title=\"" . get_opendb_lang_var('advanced_search') . "\">" . get_opendb_lang_var('advanced') . "</a></li>"; } if (strlen($user_id) > 0) { echo "<li class=\"login\"><a href=\"logout.php\">" . get_opendb_lang_var('logout', 'user_id', $user_id) . "</a></li>"; } else { echo "<li class=\"login\"><a href=\"login.php?op=login\">" . get_opendb_lang_var('login') . "</a></li>"; } echo "</ul>"; } echo "</div>"; echo "<div id=\"content\" class=\"{$pageid}Content\">"; if ($include_menu) { if ($pageid == 'admin') { echo "\n<div id=\"admin-menu\" class=\"menuContainer toggleContainer\" onclick=\"return toggleVisible('admin-menu');\">\r\n <span id=\"admin-menu-toggle\" class=\"menuToggle toggleHidden\">" . get_opendb_lang_var('admin_tools') . "</span>\r\n <div id=\"admin-menu-content\" class=\"menuContent elementHidden\">\r\n <h2 class=\"menu\">Admin Tools</h2>"; $menu_options_rs = get_system_admin_tools_menu(); echo get_menu_options_list($menu_options_rs); echo "\n</div>"; echo "\n</div>"; } echo "\n<div id=\"menu\" class=\"menuContainer toggleContainer\" onclick=\"return toggleVisible('menu');\">"; echo "<span id=\"menu-toggle\" class=\"menuToggle toggleHidden\">" . get_opendb_lang_var('main_menu') . "</span>"; echo "<div id=\"menu-content\" class=\"menuContent elementHidden\">"; echo "<h2 class=\"menu\">" . get_opendb_lang_var('main_menu') . '</h2>'; echo get_menu_options_list(get_menu_options($user_id)); echo "\n</div>"; echo "\n</div>"; } }
function marquetapage() { global $cookie; if ($cookie[0] != '') { global $REQUEST_URI, $title, $post, $NPDS_Prefix; if ($ibid = theme_image("modules/add.gif")) { $add = $ibid; } else { $add = "modules/marquetapage/add.gif"; } if ($ibid = theme_image("modules/addj.gif")) { $addj = $ibid; } else { $addj = "modules/marquetapage/addj.gif"; } $result = sql_query("SELECT uri, topic FROM " . $NPDS_Prefix . "marquetapage WHERE uid='{$cookie['0']}' ORDER BY topic ASC"); if (sql_num_rows($result)) { $tmp_toggle = '<a class="tog" id="show_fav" title="' . translate("Show list") . '"><i id="i_lst_fav" class="fa fa-caret-right fa-2x" ></i></a>'; $content = "\n <script type=\"text/javascript\">\n //<![CDATA[\n tog = function(lst,sho,hid){\n \$(document).on('click', 'a.tog', function() {\n var buttonID = \$(this).attr('id');\n lst_id = \$('#'+lst);\n i_id=\$('#i_'+lst);\n btn_show=\$('#'+sho);\n btn_hide=\$('#'+hid);\n if (buttonID == sho) {\n lst_id.fadeIn(1000);//show();\n btn_show.attr('id',hid)\n btn_show.attr('title','" . translate("Hide list") . "');\n i_id.attr('class','fa fa-caret-up fa-2x');\n } else if (buttonID == hid) {\n lst_id.fadeOut(1000);//hide();\n btn_hide=\$('#'+hid);\n btn_hide.attr('id',sho);\n btn_hide.attr('title','" . translate("Show list") . "');\n i_id.attr('class','fa fa-caret-down fa-2x');\n }\n });\n };\n //]]>\n </script>"; $content .= ' <h6> <a class="tog" id="show_fav" title="' . translate("Show list") . '"><i id="i_lst_fav" class="fa fa-caret-right fa-2x" ></i> Bookmarks </a><span class="tag tag-pill tag-default pull-right">' . sql_num_rows($result) . '</span> </h6> <ul id="lst_fav" style="display:none;" > <a href="modules.php?ModPath=marquetapage&ModStart=marquetapage&op=supp_all&uri=' . $_SERVER['PHP_SELF'] . '"><i class="fa fa-trash-o text-danger" title="' . translate("Delete") . '" data-toggle="tooltip"></i></a>'; while (list($uri, $topic) = sql_fetch_row($result)) { $content .= ' <li><a href="' . $uri . '" style="font-size:.7rem;">' . $topic . '</a> <span class="float-xs-right"><a href="modules.php?ModPath=marquetapage&ModStart=marquetapage&op=supp&uri=' . urlencode($uri) . '"><i class="fa fa-trash-o text-danger" title="' . translate("Delete") . '" data-toggle="tooltip"></i></a></span></li>'; } $content .= ' </ul> <script type="text/javascript"> //<![CDATA[ tog("lst_fav","show_fav","hide_fav"); //]]> </script>'; } global $block_title; $uri = urlencode($REQUEST_URI); if ($post) { $title .= "/" . $post; } if ($title == '') { $title_MTP = basename(urldecode($uri)); } else { $title_MTP = $title; } $boxTitle = '<span><a href="modules.php?ModPath=marquetapage&ModStart=marquetapage&op=add&uri=' . $uri . '&topic=' . urlencode($title_MTP) . '"><i class="fa fa-bookmark-o " title="' . translate("Add") . ' ' . translate("favourite") . '" data-toggle="tooltip"></i></a></span>'; if ($block_title == '') { $boxTitle .= ' MarqueTaPage'; } else { $boxTitle .= ' ' . $block_title; } themesidebox($boxTitle, $content); } }
/** * Implements theme_preprocess(). */ function ec_resp_17_preprocess(&$variables) { if (isset($variables['form']['#form_id'])) { switch ($variables['form']['#form_id']) { case 'feature_set_admin_form': // Display feature set on two columns. $output_right = $output_left = ''; $first_column = 1; foreach ($variables['feature_set_category']['category'] as $category => $features) { $output = ''; $output .= '<li>'; $output .= '<a class="list-group-item feature-set-category">' . $category . '</a>'; $output .= '<table class="feature-set-content table table-striped table-hover">'; $output .= '<tbody>'; foreach ($features as $key => $item) { // Get the icon if available. if (!empty($item['#featuresetinfo']['font'])) { $feature_icon = '<span class="' . $item['#featuresetinfo']['font'] . '"></span>'; } elseif (!empty($item['#featuresetinfo']['icon'])) { $image = array('path' => $item['#featuresetinfo']['icon'], 'alt' => t('@feature-set icon', array('@feature-set' => $item['#featuresetinfo']['featureset'])), 'attributes' => array()); $feature_icon = theme_image($image); } else { $feature_icon = ''; } // Get the feature name and description. $feature_content = '<blockquote>'; $feature_content .= '<p>' . $item['#featuresetinfo']['featureset'] . '</p>'; if (!empty($item['#featuresetinfo']['description'])) { $feature_content .= '<small>' . $item['#featuresetinfo']['description'] . '</small>'; } $feature_content .= '</blockquote>'; $output .= '<tr>'; $output .= '<td class="feature-set-image">' . $feature_icon . '</td>'; $output .= '<td class="feature_set_content">' . $feature_content . '</td>'; $output .= '<td class="feature_set_switcher">' . render($item) . '</td>'; $output .= '</tr>'; } $output .= '</tbody>'; $output .= '</table>'; $output .= '</li>'; if ($first_column) { $output_left .= $output; } else { $output_right .= $output; } $first_column = 1 - $first_column; } $variables['feature_set_output_left'] = $output_left; $variables['feature_set_output_right'] = $output_right; break; } } }
/** * Implements template_preprocess(). */ function ec_resp_preprocess_feature_set_admin_form(&$variables) { // Add specific javascript. drupal_add_js(drupal_get_path('theme', 'ec_resp') . '/scripts/feature-set.js', array('scope' => 'footer', 'weight' => 13)); $categories_list = ''; $features_list = ''; foreach ($variables['feature_set_category']['category'] as $category => $features) { $table = array('header' => NULL, 'rows' => array(), 'attributes' => array('class' => array('feature-set-content table table-striped table-hover'))); // Create category id. $category_id = preg_replace("/[^a-z0-9_\\s-]/", "", strtolower($category)); $category_id = preg_replace("/[\\s-]+/", " ", $category_id); $category_id = preg_replace("/[\\s_]/", "-", $category_id); // Format categories. $categories_list .= theme('html_tag', array('element' => array('#tag' => 'li', '#attributes' => array('class' => 'feature-set__category', 'role' => 'presentation'), '#value' => l($category . ' (' . count($features) . ')', '', array('fragment' => $category_id, 'external' => TRUE))))); // Format features. $feature_full = ''; foreach ($features as $key => $item) { // Get the icon if available. if (!empty($item['#featuresetinfo']['font'])) { $feature_icon = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => array('feature-set__icon', $item['#featuresetinfo']['font'])), '#value' => ''))); } elseif (!empty($item['#featuresetinfo']['icon'])) { $image = array('path' => $item['#featuresetinfo']['icon'], 'alt' => t('@feature-set icon', array('@feature-set' => $item['#featuresetinfo']['featureset'])), 'attributes' => array('class' => 'feature-set__icon')); $feature_icon = theme_image($image); } else { $feature_icon = ''; } // Format feature name. $feature_name = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__name'), '#value' => $item['#featuresetinfo']['featureset']))); // Format feature documentation. $feature_documentation = !empty($item['#featuresetinfo']['documentation']) ? l(t('See @name documentation', array('@name' => $item['#featuresetinfo']['featureset'])), $item['#featuresetinfo']['documentation'], array('attributes' => array('target' => '_blank'))) : ''; // Format feature description. $feature_description_value = ''; $feature_description_value .= !empty($item['#featuresetinfo']['description']) ? $item['#featuresetinfo']['description'] : ''; $feature_description_value .= !empty($feature_documentation) ? theme('html_tag', array('element' => array('#tag' => 'footer', '#attributes' => array('class' => 'feature-set__doc'), '#value' => $feature_documentation))) : ''; $feature_description = theme('html_tag', array('element' => array('#tag' => 'blockquote', '#attributes' => array('class' => 'feature-set__desc'), '#value' => $feature_description_value))); // Format feature requirements. $feature_require = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__doc'), '#value' => !empty($item['#featuresetinfo']['require']) ? $item['#featuresetinfo']['require'] : ''))); // Format switcher. $feature_switcher = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__switch'), '#value' => render($item)))); // Group content. $feature_header = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__header'), '#value' => $feature_icon . $feature_name . $feature_switcher))); $feature_content = theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__content'), '#value' => $feature_description . $feature_require))); $feature_full .= theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('class' => 'feature-set__feature'), '#value' => $feature_header . $feature_content))); } // Update feature list. $features_list .= theme('html_tag', array('element' => array('#tag' => 'div', '#attributes' => array('id' => $category_id, 'class' => 'feature-set__feature-group'), '#value' => $feature_full))); } $variables['feature_set_categories_list'] = $categories_list; $variables['feature_set_features_list'] = $features_list; }
function MM_img($ibid) { $ibid = arg_filter($ibid); $ibidX = theme_image($ibid); if ($ibidX) { $ret = "<img src=\"{$ibidX}\" border=\"0\" alt=\"\" />"; } else { if (@file_exists("images/{$ibid}")) { $ret = "<img src=\"images/{$ibid}\" border=\"0\" alt=\"\" />"; } else { $ret = false; } } return $ret; }
function marquetapage() { global $cookie; if ($cookie[0] != "") { global $REQUEST_URI, $title, $post, $NPDS_Prefix; if ($ibid = theme_image("modules/add.gif")) { $add = $ibid; } else { $add = "modules/marquetapage/add.gif"; } if ($ibid = theme_image("modules/addj.gif")) { $addj = $ibid; } else { $addj = "modules/marquetapage/addj.gif"; } $result = sql_query("select uri, topic from " . $NPDS_Prefix . "marquetapage where uid='{$cookie['0']}' order by topic ASC"); if (sql_num_rows($result)) { $tmp_toggle = '<span id="show_fav" title="' . translate("Show list") . '"><img src="images/admin/ws/toggle_plus.gif" style="vertical-align:middle;" alt="' . translate("Show list") . '" /></span>'; $content = "<script type=\"text/javascript\" src=\"lib/yui/build/yui/yui-min.js\"></script>"; $content .= "<script type=\"text/javascript\">\n //<![CDATA[\n tog =function(lst,sho,hid){\n YUI().use('transition', 'node-event-delegate', function (Y) {\n Y.delegate('click', function(e) {\n var buttonID = e.currentTarget.get('id'),\n lst_id = Y.one('#'+lst);\n btn_show=Y.one('#'+sho);\n btn_hide=Y.one('#'+hid);\n if (buttonID === sho) {\n lst_id.show(true);\n btn_show.set('id',hid);\n btn_show.set('title','" . translate("Hide list") . "');\n btn_show.setContent('<img src=\"images/admin/ws/toggle_minus.gif\" style=\"vertical-align:middle;\" alt=\"" . translate("Hide list") . "\" />');\n } else if (buttonID == hid) {\n lst_id.transition({\n duration: 0.2,\n easing: 'ease-out',\n opacity: 0\n });\n btn_hide=Y.one('#'+hid);\n lst_id.hide(true);\n btn_hide.set('id',sho);\n btn_hide.set('title','" . translate("Show list") . "');\n btn_hide.setContent('<img src=\"images/admin/ws/toggle_plus.gif\" style=\"vertical-align:middle;\" alt=\"" . translate("Show list") . "\" />');\n }\n }, document, 'span');\n });\n }\n //]]>\n </script>"; $content .= "\n<table width=\"100%\" id=\"lst_fav\" border=\"0\" cellspacing=\"1\" cellpadding=\"2\" style=\"display:none;\" >\n<thead>\n<tr>\n<th><img src=\"{$addj}\" border=\"0\" style=\"vertical-align:middle\" alt=\"" . translate("Add") . " " . translate("favourite") . "\" title=\"" . translate("Add") . " " . translate("favourite") . "\" /> Bookmarks [" . sql_num_rows($result) . "]</th><th align=\"right\"><a href=\"modules.php?ModPath=marquetapage&ModStart=marquetapage&op=supp_all&uri=" . $_SERVER['PHP_SELF'] . "\"><img src=\"modules/marquetapage/del.gif\" border=\"0\" alt=\"" . translate("Delete") . "\" title=\"" . translate("Delete") . "\" style=\"vertical-align: middle;\" /></a></th>\n</tr>\n</thead>\n<tbody>"; while (list($uri, $topic) = sql_fetch_row($result)) { $content .= "\n<tr>\n<td align=\"left\" width=\"95%\"><a href=\"{$uri}\" style=\"font-size: 10px;\">" . $topic . "</a></td>\n"; $content .= "<td align=\"right\"><a href=\"modules.php?ModPath=marquetapage&ModStart=marquetapage&op=supp&uri=" . urlencode($uri) . "\"><img src=\"modules/marquetapage/del.gif\" border=\"0\" alt=\"" . translate("Delete") . "\" title=\"" . translate("Delete") . "\" style=\"vertical-align: middle;\" /></a></td>\n</tr>\n"; } $content .= "</tbody>\n</table>\n"; $content .= "\n<script type=\"text/javascript\">\n //<![CDATA[\n tog('lst_fav','show_fav','hide_fav');\n //]]>\n </script>\n"; } global $block_title; $uri = urlencode($REQUEST_URI); if ($post) { $title .= "/" . $post; } if ($title == "") { $title_MTP = basename(urldecode($uri)); } else { $title_MTP = $title; } $boxTitle = "<span><a href=\"modules.php?ModPath=marquetapage&ModStart=marquetapage&op=add&uri={$uri}&topic=" . urlencode($title_MTP) . "\"><img src=\"{$add}\" name=\"image\" onmouseover=\"image.src='{$addj}';\" onmouseout=\"image.src='{$add}';\" border=\"0\" style=\"vertical-align:middle\" alt=\"" . translate("Add") . " " . translate("favourite") . "\" title=\"" . translate("Add") . " " . translate("favourite") . "\" /></a></span>"; if ($block_title == "") { $boxTitle .= " MarqueTaPage " . $tmp_toggle; } else { $boxTitle .= " " . $block_title . " " . $tmp_toggle; } themesidebox($boxTitle, $content); } }
function Affiche_Extention($Format = "IMG") { $this->Extention(); switch ($Format) { case "IMG": if ($ibid = theme_image("upload/file_types/" . $this->Extention . ".gif")) { $imgtmp = $ibid; } else { $imgtmp = "images/upload/file_types/" . $this->Extention . ".gif"; } if (@file_exists($imgtmp)) { return $imgtmp; } else { return "images/upload/file_types/unknown.gif"; } break; } }
function display_edit_site_plugin($record_r, $HTTP_VARS = NULL) { if (is_array($record_r)) { echo get_input_field('site_type', NULL, 'Site Type', 'readonly', 'Y', $record_r['site_type']); } else { echo get_input_field('site_type', NULL, 'Site Type', 'text(10,10)', 'Y', $record_r['site_type']); } echo get_input_field('classname', NULL, 'Class Name', 'text(50,50)', 'Y', $record_r['classname']); echo get_input_field('title', NULL, 'Title', 'text(25,50)', 'Y', $record_r['title']); $field = get_input_field('image', NULL, 'Image', 'url(25,*,"gif,jpg,png",N)', 'N', $record_r['image'], FALSE); if (strlen($record_r['image']) > 0) { $image_src = "images/site/" . $record_r['image']; } if ($image_src !== FALSE && strlen($image_src) > 0 && file_exists($image_src)) { $field .= theme_image("images/site/" . $image_src, NULL, NULL); } echo format_field('Image', $field); echo get_input_field('description', NULL, 'Description', 'text(50,255)', 'Y', $record_r['description']); echo get_input_field('external_url', NULL, 'External URL', 'text(50,255)', 'Y', $record_r['external_url']); echo get_input_field('more_info_url', NULL, 'More Info URL', 'text(50,255)', 'N', $record_r['more_info_url']); echo get_input_field('items_per_page', NULL, 'Items Per Page', 'number(3)', 'N', $record_r['items_per_page']); }
function hook_article_button($line) { $rv = ""; $article_link = $line['link']; if ($article_link) { $encoded = urlencode($article_link); $r = file_get_contents("https://api.flattr.com/rest/v2/things/lookup/?url={$encoded}"); $response = json_decode($r, true); $image = "<img src=\"" . theme_image($this->link, 'plugins/flattr/flattr.png') . "\"\n class='tagsPic' style=\"cursor : pointer\"\n title='" . __('Flattr this article.') . "'>"; // if Flattr has it in the catalogue, we display the button if ($response and array_key_exists('link', $response)) { $rv = "<a id='flattr' target='_blank' href='" . $response['link'] . "'> . {$image} . </a>"; } else { // We can't submit a thing to the catalogue without giving a Flattr user id (who would be the owner) // see http://developers.flattr.net/auto-submit //$rv = "<a id='flattr' href='https://flattr.com/submit/auto?url=" . $encoded . "'>" . $image . "</a>"; $rv = ''; // Another useful thing would be any rel=payment link (which would have the user id as well), // but tt-rss is not checking that (yet), I believe. See http://developers.flattr.net/feed } } return $rv; }
function hook_article_button($line) { $article_id = $line["id"]; $rv = "<img src=\"" . theme_image($this->link, 'plugins/pocket/pocket.png') . "\"\n\t\t\tclass='tagsPic' style=\"cursor : pointer\"\n\t\t\tonclick=\"shareArticleToPocket({$article_id})\"\n\t\t\ttitle='" . __('Pocket') . "'>"; return $rv; }
// Header Content ?> <div class="row"> <div class="col-md-3"> <div class="site-title"> <a href="<?php echo home_url(); ?> " title="<?php echo get_bloginfo('name', 'display'); ?> " rel="home"> <?php theme_image('logo.png', get_bloginfo('name', 'display')); ?> </a> </div> </div> <div class="col-md-9"> <nav role="navigation"> <?php theme_menu('topmenu'); ?> </nav> </div> </div>
function previewAdminStory($subject, $hometext, $bodytext, $topic, $catid, $ihome, $members, $Mmembers, $deb_day, $deb_month, $deb_year, $deb_hour, $deb_min, $fin_day, $fin_month, $fin_year, $fin_hour, $fin_min, $epur) { global $NPDS_Prefix, $tipath, $hlpfile, $language, $aid, $radminsuper, $adminimg, $topicimage; $hlpfile = "manuels/{$language}/newarticle.html"; $subject = stripslashes(str_replace('"', '"', $subject)); $hometext = stripslashes($hometext); $bodytext = stripslashes($bodytext); if ($topic < 1) { $topic = 1; } $affiche = false; $result2 = sql_query("SELECT topictext, topicimage, topicadmin FROM " . $NPDS_Prefix . "topics WHERE topicid='{$topic}'"); list($topictext, $topicimage, $topicadmin) = sql_fetch_row($result2); if ($radminsuper) { $affiche = true; } else { $topicadminX = explode(',', $topicadmin); for ($i = 0; $i < count($topicadminX); $i++) { if (trim($topicadminX[$i]) == $aid) { $affiche = true; } } } if (!$affiche) { header("location: admin.php"); } $f_meta_nom = 'adminStory'; $f_titre = adm_translate("Nouvel Article"); //==> controle droit // admindroits($aid,$f_meta_nom); // à voir l'intégrationavec les droits sur les topics ... //<== controle droit $topiclogo = '<span class="label label-default pull-right"><strong>' . aff_langue($topictext) . '</strong></span>'; include 'header.php'; GraphicAdmin($hlpfile); global $local_user_language; adminhead($f_meta_nom, $f_titre, $adminimg); echo ' <h3>' . adm_translate("Prévisualiser l'Article") . '</h3> <form action="admin.php" method="post" name="adminForm"> <label class="form-control-label">' . adm_translate("Langue de Prévisualisation") . '</label> ' . aff_localzone_langue("local_user_language"); echo '<div class="card card-block">'; if ($topicimage !== '') { if (!($imgtmp = theme_image('topics/' . $topicimage))) { $imgtmp = $tipath . $topicimage; } $timage = $imgtmp; if (file_exists($imgtmp)) { $topiclogo = '<img class="img-fluid " src="' . $timage . '" align="right" alt="" />'; } } code_aff('<h3>' . $subject . $topiclogo . '</h3>', '<div class="text-muted">' . $hometext . '</div>', $bodytext, ''); echo ' </div> <div class="form-group row"> <label class="col-sm-4 form-control-label" for="subject">' . adm_translate("Titre") . '</label> <div class="col-sm-8"> <input class="form-control" type="text" name="subject" value="' . $subject . '" /> </div> </div> <div class="form-group row"> <label class="col-sm-4 form-control-label" for="topic">' . adm_translate("Sujet") . '</label> <div class="col-sm-8"> <select class="c-select form-control" name="topic">'; $toplist = sql_query("SELECT topicid, topictext, topicadmin FROM " . $NPDS_Prefix . "topics ORDER BY topictext"); if ($radminsuper) { echo ' <option value="">' . adm_translate("Tous les Sujets") . '</option>'; } while (list($topicid, $topics, $topicadmin) = sql_fetch_row($toplist)) { $affiche = false; if ($radminsuper) { $affiche = true; } else { $topicadminX = explode(",", $topicadmin); for ($i = 0; $i < count($topicadminX); $i++) { if (trim($topicadminX[$i]) == $aid) { $affiche = true; } } } if ($affiche) { if ($topicid == $topic) { $sel = 'selected="selected"'; } echo ' <option ' . $sel . ' value="' . $topicid . '">' . aff_langue($topics) . '</option>'; $sel = ''; } } echo ' </select> </div> </div>'; $cat = $catid; SelectCategory($catid); echo "<br />"; if ($members == 1 and $Mmembers == "") { $ihome = "-127"; } if ($members == 1 and ($Mmembers > 1 and $Mmembers <= 127)) { $ihome = $Mmembers; } puthome($ihome); echo ' <div class="form-group row"> <label class="form-control-label col-xs-12" for="hometext">' . adm_translate("Texte d'introduction") . '</label> <div class="col-xs-12"> <textarea class="tin form-control" rows="25" name="hometext">' . $hometext . '</textarea> </div> </div>'; echo aff_editeur("hometext", "true"); echo ' <div class="form-group row"> <label class="form-control-label col-xs-12" for="bodytext">' . adm_translate("Texte étendu") . '</label> <div class="col-xs-12"> <textarea class="tin form-control" rows="25" name="bodytext" >' . $bodytext . '</textarea> </div> </div>'; echo aff_editeur('bodytext', ''); publication($deb_day, $deb_month, $deb_year, $deb_hour, $deb_min, $fin_day, $fin_month, $fin_year, $fin_hour, $fin_min, $epur); echo ' <div class="form-group row"> <input type="hidden" name="author" value="' . $aid . '" /> <div class="col-xs-7"> <select class="c-select form-control" name="op"> <option value="PreviewAdminStory" selected>' . adm_translate("Prévisualiser") . '</option> <option value="PostStory">' . adm_translate("Poster un Article Admin") . '</option> </select> </div> <div class="col-xs-5"> <input class="btn btn-primary" type="submit" value="' . adm_translate("Ok") . '" /> </div> </div> </form>'; include 'footer.php'; }
function format_article($link, $id, $mark_as_read = true, $zoom_mode = false, $owner_uid = false) { if (!$owner_uid) { $owner_uid = $_SESSION["uid"]; } $rv = array(); $rv['id'] = $id; /* we can figure out feed_id from article id anyway, why do we * pass feed_id here? let's ignore the argument :( */ $result = db_query($link, "SELECT feed_id FROM ttrss_user_entries\n\t\t\tWHERE ref_id = '{$id}'"); $feed_id = (int) db_fetch_result($result, 0, "feed_id"); $rv['feed_id'] = $feed_id; //if (!$zoom_mode) { print "<article id='$id'><![CDATA["; }; if ($mark_as_read) { $result = db_query($link, "UPDATE ttrss_user_entries\n\t\t\t\tSET unread = false,last_read = NOW()\n\t\t\t\tWHERE ref_id = '{$id}' AND owner_uid = {$owner_uid}"); ccache_update($link, $feed_id, $owner_uid); } $result = db_query($link, "SELECT id,title,link,content,feed_id,comments,int_id,\n\t\t\t" . SUBSTRING_FOR_DATE . "(updated,1,16) as updated,\n\t\t\t(SELECT site_url FROM ttrss_feeds WHERE id = feed_id) as site_url,\n\t\t\tnum_comments,\n\t\t\ttag_cache,\n\t\t\tauthor,\n\t\t\torig_feed_id,\n\t\t\tnote,\n\t\t\tcached_content\n\t\t\tFROM ttrss_entries,ttrss_user_entries\n\t\t\tWHERE\tid = '{$id}' AND ref_id = id AND owner_uid = {$owner_uid}"); if ($result) { $line = db_fetch_assoc($result); $tag_cache = $line["tag_cache"]; $line["tags"] = get_article_tags($link, $id, $owner_uid, $line["tag_cache"]); unset($line["tag_cache"]); $line["content"] = sanitize($link, $line["content"], false, $owner_uid, $line["site_url"]); global $pluginhost; foreach ($pluginhost->get_hooks($pluginhost::HOOK_RENDER_ARTICLE) as $p) { $line = $p->hook_render_article($line); } $num_comments = $line["num_comments"]; $entry_comments = ""; if ($num_comments > 0) { if ($line["comments"]) { $comments_url = htmlspecialchars($line["comments"]); } else { $comments_url = htmlspecialchars($line["link"]); } $entry_comments = "<a target='_blank' href=\"{$comments_url}\">{$num_comments} comments</a>"; } else { if ($line["comments"] && $line["link"] != $line["comments"]) { $entry_comments = "<a target='_blank' href=\"" . htmlspecialchars($line["comments"]) . "\">comments</a>"; } } if ($zoom_mode) { header("Content-Type: text/html"); $rv['content'] .= "<html><head>\n\t\t\t\t\t\t<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"/>\n\t\t\t\t\t\t<title>Tiny Tiny RSS - " . $line["title"] . "</title>\n\t\t\t\t\t\t<link rel=\"stylesheet\" type=\"text/css\" href=\"tt-rss.css\">\n\t\t\t\t\t</head><body>"; } $title_escaped = htmlspecialchars($line['title']); $rv['content'] .= "<div id=\"PTITLE-FULL-{$id}\" style=\"display : none\">" . strip_tags($line['title']) . "</div>"; $rv['content'] .= "<div class=\"postReply\" id=\"POST-{$id}\">"; $rv['content'] .= "<div class=\"postHeader\" id=\"POSTHDR-{$id}\">"; $entry_author = $line["author"]; if ($entry_author) { $entry_author = __(" - ") . $entry_author; } $parsed_updated = make_local_datetime($link, $line["updated"], true, $owner_uid, true); $rv['content'] .= "<div class=\"postDate\">{$parsed_updated}</div>"; if ($line["link"]) { $rv['content'] .= "<div class='postTitle'><a target='_blank'\n\t\t\t\t\ttitle=\"" . htmlspecialchars($line['title']) . "\"\n\t\t\t\t\thref=\"" . htmlspecialchars($line["link"]) . "\">" . $line["title"] . "<span class='author'>{$entry_author}</span></a></div>"; } else { $rv['content'] .= "<div class='postTitle'>" . $line["title"] . "{$entry_author}</div>"; } $tags_str = format_tags_string($line["tags"], $id); $tags_str_full = join(", ", $line["tags"]); if (!$tags_str_full) { $tags_str_full = __("no tags"); } if (!$entry_comments) { $entry_comments = " "; } # placeholder $rv['content'] .= "<div class='postTags' style='float : right'>\n\t\t\t\t<img src='" . theme_image($link, 'images/tag.png') . "'\n\t\t\t\tclass='tagsPic' alt='Tags' title='Tags'> "; if (!$zoom_mode) { $rv['content'] .= "<span id=\"ATSTR-{$id}\">{$tags_str}</span>\n\t\t\t\t\t<a title=\"" . __('Edit tags for this article') . "\"\n\t\t\t\t\thref=\"#\" onclick=\"editArticleTags({$id}, {$feed_id})\">(+)</a>"; $rv['content'] .= "<div dojoType=\"dijit.Tooltip\"\n\t\t\t\t\tid=\"ATSTRTIP-{$id}\" connectId=\"ATSTR-{$id}\"\n\t\t\t\t\tposition=\"below\">{$tags_str_full}</div>"; global $pluginhost; foreach ($pluginhost->get_hooks($pluginhost::HOOK_ARTICLE_BUTTON) as $p) { $rv['content'] .= $p->hook_article_button($line); } } else { $tags_str = strip_tags($tags_str); $rv['content'] .= "<span id=\"ATSTR-{$id}\">{$tags_str}</span>"; } $rv['content'] .= "</div>"; $rv['content'] .= "<div clear='both'>{$entry_comments}</div>"; if ($line["orig_feed_id"]) { $tmp_result = db_query($link, "SELECT * FROM ttrss_archived_feeds\n\t\t\t\t\tWHERE id = " . $line["orig_feed_id"]); if (db_num_rows($tmp_result) != 0) { $rv['content'] .= "<div clear='both'>"; $rv['content'] .= __("Originally from:"); $rv['content'] .= " "; $tmp_line = db_fetch_assoc($tmp_result); $rv['content'] .= "<a target='_blank'\n\t\t\t\t\t\thref=' " . htmlspecialchars($tmp_line['site_url']) . "'>" . $tmp_line['title'] . "</a>"; $rv['content'] .= " "; $rv['content'] .= "<a target='_blank' href='" . htmlspecialchars($tmp_line['feed_url']) . "'>"; $rv['content'] .= "<img title='" . __('Feed URL') . "'class='tinyFeedIcon' src='images/pub_set.svg'></a>"; $rv['content'] .= "</div>"; } } $rv['content'] .= "</div>"; $rv['content'] .= "<div id=\"POSTNOTE-{$id}\">"; if ($line['note']) { $rv['content'] .= format_article_note($id, $line['note'], !$zoom_mode); } $rv['content'] .= "</div>"; $rv['content'] .= "<div class=\"postContent\">"; // N-grams if (DB_TYPE == "pgsql" and defined('_NGRAM_TITLE_RELATED_THRESHOLD')) { $ngram_result = db_query($link, "SELECT id,title FROM\n\t\t\t\t\t\tttrss_entries,ttrss_user_entries\n\t\t\t\t\tWHERE ref_id = id AND updated >= NOW() - INTERVAL '7 day'\n\t\t\t\t\t\tAND similarity(title, '{$title_escaped}') >= " . _NGRAM_TITLE_RELATED_THRESHOLD . "\n\t\t\t\t\t\tAND title != '{$title_escaped}'\n\t\t\t\t\t\tAND owner_uid = {$owner_uid}"); if (db_num_rows($ngram_result) > 0) { $rv['content'] .= "<div dojoType=\"dijit.form.DropDownButton\">" . "<span>" . __('Related') . "</span>"; $rv['content'] .= "<div dojoType=\"dijit.Menu\" style=\"display: none;\">"; while ($nline = db_fetch_assoc($ngram_result)) { $rv['content'] .= "<div onclick=\"hlOpenInNewTab(null," . $nline['id'] . ")\"\n\t\t\t\t\t\t\tdojoType=\"dijit.MenuItem\">" . $nline['title'] . "</div>"; } $rv['content'] .= "</div></div><br/"; } } if ($cache_content && $line["cached_content"] != "") { $line["content"] =& $line["cached_content"]; } $rv['content'] .= $line["content"]; $rv['content'] .= format_article_enclosures($link, $id, $always_display_enclosures, $line["content"]); $rv['content'] .= "</div>"; $rv['content'] .= "</div>"; } if ($zoom_mode) { $rv['content'] .= "\n\t\t\t\t<div style=\"text-align : center\">\n\t\t\t\t<button onclick=\"return window.close()\">" . __("Close this window") . "</button></div>"; $rv['content'] .= "</body></html>"; } return $rv; }
if ($ibid = theme_image("forum/avatar/" . $posterdata['user_avatar'])) { $imgtmp = $ibid; } else { $imgtmp = "images/forum/avatar/" . $posterdata['user_avatar']; } } if ($posterdata['mns']) { echo "<p align=\"center\"><a href=\"minisite.php?op=" . $posterdata['uname'] . "\" target=\"_blank\"><img src=\"{$imgtmp}\" alt=\"\" border=\"0\" /></a></p>"; } else { echo "<p align=\"center\"><img src=\"{$imgtmp}\" border=\"0\" alt=\"\" /></p>"; } } } echo "</td><td valign=\"top\" width=\"100%\" height=\"100%\">"; if ($myrow['image'] != '') { if ($ibid = theme_image("forum/subject/" . $myrow['image'])) { $imgtmp = $ibid; } else { $imgtmp = "images/forum/subject/" . $myrow['image']; } echo "<img src=\"{$imgtmp}\" border=\"0\" alt=\"\" />"; } else { echo "<img src=\"{$imgtmpPI}\" border=\"0\" alt=\"\" />"; } echo " " . translate("Posted: ") . convertdate($myrow['post_time']); echo "<br /><br />\n"; $message = stripslashes($myrow['post_text']); if ($allow_bbcode) { $message = smilie($message); $message = str_replace("[video_yt]", "http://www.youtube.com/watch?v=", $message); $message = str_replace("[/video_yt]", "", $message);
function autoEdit($anid) { global $aid, $hlpfile, $tipath, $radminsuper, $NPDS_Prefix, $adminimg; $f_meta_nom = 'autoStory'; $f_titre = adm_translate("Editer un Article"); //==> controle droit admindroits($aid, $f_meta_nom); //<== controle droit $result = sql_query("SELECT catid, title, time, hometext, bodytext, topic, informant, notes, ihome, date_debval,date_finval,auto_epur FROM " . $NPDS_Prefix . "autonews WHERE anid='{$anid}'"); list($catid, $title, $time, $hometext, $bodytext, $topic, $informant, $notes, $ihome, $date_debval, $date_finval, $epur) = sql_fetch_row($result); sql_free_result($result); $titre = stripslashes($title); $hometext = stripslashes($hometext); $bodytext = stripslashes($bodytext); $notes = stripslashes($notes); if ($topic < 1) { $topic = 1; } $affiche = false; $result2 = sql_query("SELECT topictext, topicimage, topicadmin FROM " . $NPDS_Prefix . "topics WHERE topicid='{$topic}'"); list($topictext, $topicimage, $topicadmin) = sql_fetch_row($result2); if ($radminsuper) { $affiche = true; } else { $topicadminX = explode(',', $topicadmin); for ($i = 0; $i < count($topicadminX); $i++) { if (trim($topicadminX[$i]) == $aid) { $affiche = true; } } } if (!$affiche) { header("location: admin.php?op=autoStory"); } $topiclogo = '<span class="label label-default pull-right"><strong>' . aff_langue($topictext) . '</strong></span>'; include 'header.php'; GraphicAdmin($hlpfile); adminhead($f_meta_nom, $f_titre, $adminimg); echo '<h3>' . adm_translate("Editer l'Article Automatique") . '</h3>'; echo aff_local_langue(adm_translate("Langue de Prévisualisation"), '', 'local_user_language'); echo '<div class="card card-block">'; if ($topicimage !== '') { if (!($imgtmp = theme_image('topics/' . $topicimage))) { $imgtmp = $tipath . $topicimage; } $timage = $imgtmp; if (file_exists($imgtmp)) { $topiclogo = '<img class="img-fluid " src="' . $timage . '" align="right" alt="" />'; } } // $no_img=false; // if ((file_exists("$tipath$topicimage")) and ($topicimage!="")) { // echo "<img src=\"$tipath$topicimage\" border=\"0\" align=\"right\" alt=\"\" />"; // } else { // $no_img=true; // } code_aff('<h3>' . $subject . $topiclogo . '</h3>', '<div class="text-muted">' . $hometext . '</div>', $bodytext, $notes); if ($no_img) { echo "<b>" . aff_langue($topictext) . "</b>"; } echo '<b>' . adm_translate("Utilisateur") . '</b>' . $informant . '<br /><br />'; echo ' </div> <form action="admin.php" method="post" name="adminForm"> <div class="form-group row"> <label class="form-control-label col-sm-4" for="title">' . adm_translate("Titre") . '</label> <div class="col-sm-8"> <input class="form-control" type="text" name="title" size="50" value="' . $titre . '" /> </div> </div> <div class="form-group row"> <label class="form-control-label col-sm-4" for="topic">' . adm_translate("Sujet") . '</label> <div class="col-sm-8"> <select class="c-select form-control" name="topic">'; $toplist = sql_query("SELECT topicid, topictext, topicadmin FROM " . $NPDS_Prefix . "topics ORDER BY topictext"); if ($radminsuper) { echo ' <option value="">' . adm_translate("Tous les Sujets") . '</option>'; } while (list($topicid, $topics, $topicadmin) = sql_fetch_row($toplist)) { $affiche = false; if ($radminsuper) { $affiche = true; } else { $topicadminX = explode(",", $topicadmin); for ($i = 0; $i < count($topicadminX); $i++) { if (trim($topicadminX[$i]) == $aid) { $affiche = true; } } } if ($affiche) { if ($topicid == $topic) { $sel = 'selected="selected" '; } echo "<option {$sel} value=\"{$topicid}\">" . aff_langue($topics) . "</option>\n"; $sel = ''; } } echo ' </select> </div> </div>'; SelectCategory($catid); echo "<br />"; puthome($ihome); echo ' <div class="form-group row"> <label class="form-control-label col-sm-12" for="hometext">' . adm_translate("Texte d'introduction") . '</label> <div class="col-sm-12"> <textarea class="tin form-control" rows="25" name="hometext" >' . $hometext . '</textarea> </div> </div> ' . aff_editeur('hometext', '') . ' <div class="form-group row"> <label class="form-control-label col-sm-12" for="bodytext">' . adm_translate("Texte étendu") . '</label> <div class="col-sm-12"> <textarea class="tin form-control" rows="25" name="bodytext" >' . $bodytext . '</textarea> </div> </div> ' . aff_editeur('bodytext', ''); if ($aid != $informant) { echo ' <div class="form-group row"> <label class="form-control-label col-sm-12" for="notes">' . adm_translate("Notes") . '</label> <div class="col-sm-12"> <textarea class="tin form-control" rows="7" name="notes">' . $notes . '</textarea> </div> </div> ' . aff_editeur('notes', ''); } $deb_day = substr($date_debval, 8, 2); $deb_month = substr($date_debval, 5, 2); $deb_year = substr($date_debval, 0, 4); $deb_hour = substr($date_debval, 11, 2); $deb_min = substr($date_debval, 14, 2); // $fin_day = substr($date_finval, 8, 2); $fin_month = substr($date_finval, 5, 2); $fin_year = substr($date_finval, 0, 4); $fin_hour = substr($date_finval, 11, 2); $fin_min = substr($date_finval, 14, 2); // publication($deb_day, $deb_month, $deb_year, $deb_hour, $deb_min, $fin_day, $fin_month, $fin_year, $fin_hour, $fin_min, $epur); echo ' <div class="form-group row"> <div class="col-sm-12"> <input type="hidden" name="anid" value="' . $anid . '" /> <input type="hidden" name="op" value="autoSaveEdit" /> <input class="btn btn-primary" type="submit" value="' . adm_translate("Sauver les modifications") . '" /> </div> </div> </form>'; adminfoot('fv', '', '', ''); }
<button id="net-alert" dojoType="dijit.form.Button" style="display : none" disabled="true" title="<?php echo __("Communication problem with server."); ?> "> <img src="<?php echo theme_image($link, 'images/alert.png'); ?> " /> </button> <button id="newVersionIcon" dojoType="dijit.form.Button" style="display : none"> <img onclick="newVersionDlg()" src="<?php echo theme_image($link, 'images/new_version.png'); ?> " title="<?php echo __('New version of Tiny Tiny RSS is available!'); ?> " /> </button> <div dojoType="dijit.form.DropDownButton"> <span><?php echo __('Actions...'); ?> </span> <div dojoType="dijit.Menu" style="display: none">
<span class="submitted"><?php print $submitted; ?> </span> <?php } ?> <div class="content swContentWrap clearfix"<?php print $content_attributes; ?> > <div class="about"> <div class="col-sm-5" > <?php print theme_image(array('path' => $node->field_image['und'][0]['uri'], 'attributes' => array('class' => array('swImg')))); ?> </div> <p>I'm father, husband, and front end web developer, with a passion for delivering great user experiences on mobile and desktop. I have over nine years of experience programming applications for the web.</p> <p>I love experimenting with new technologies and learning new languages. When not writing code I enjoying hanging out with my wife and son, hiking, playing bass and reading/watching science fiction.</p> <div class="clearfix myStatus"> <h2 class="swTitle">My Status</h2> <ul> <li>I'm working part-time for Northern Arizona University.</li> <li>I'm wrapping up development on Windwalker Expeditions new Drupal 7 web site.</li>
function sub_forum_folder($forum) { global $user, $NPDS_Prefix; if ($user) { $userX = base64_decode($user); $userR = explode(':', $userX); } $result = sql_query("SELECT COUNT(topic_id) AS total FROM " . $NPDS_Prefix . "forumtopics WHERE forum_id='{$forum}'"); list($totalT) = sql_fetch_row($result); $result = sql_query("SELECT COUNT(DISTINCT topicid) AS total FROM " . $NPDS_Prefix . "forum_read WHERE uid='{$userR['0']}' AND topicid>'0' AND status!='0' AND forum_id='{$forum}'"); list($totalF) = sql_fetch_row($result); if ($ibid = theme_image("forum/icons/red_sub_folder.gif")) { $imgtmpR = $ibid; } else { $imgtmpR = "images/forum/icons/red_sub_folder.gif"; } if ($ibid = theme_image("forum/icons/sub_folder.gif")) { $imgtmp = $ibid; } else { $imgtmp = "images/forum/icons/sub_folder.gif"; } if ($totalT - $totalF > 0) { $ibid = '<img src="' . $imgtmpR . '" alt="" />'; } else { $ibid = '<img src="' . $imgtmp . '" alt="" />'; } return $ibid; }
if (file_exists("static/{$op}")) { if (!$metalang and !$nl) { include "static/{$op}"; } else { ob_start(); include "static/{$op}"; $remp = ob_get_contents(); ob_end_clean(); if ($metalang) { $remp = meta_lang(aff_code(aff_langue($remp))); } if ($nl) { $remp = nl2br(str_replace(' ', ' ', htmlentities($remp, ENT_QUOTES, cur_charset))); } echo $remp; } if (!($imgtmp = theme_image("box/print.gif"))) { $imgtmp = "images/print.gif"; } echo '<p><a href="print.php?sid=static:' . $op . '&metalang=' . $metalang . '&nl=' . $nl . '" title="' . translate("Printer Friendly Page") . '"><i class="fa fa-2x fa-print"></i></a></p>'; // Si vous voulez tracer les appels au pages statiques : supprimer les // devant la ligne ci-dessous // Ecr_Log("security", "static/$op", ""); } else { echo "<p class=\"text-danger text-xs-center\">" . translate("Please enter information according to the specifications") . "</p>"; } } else { echo "<p class=\"text-danger text-xs-center\">" . translate("Please enter information according to the specifications") . "</p>"; } } echo '</div>'; include "footer.php";
private function format_headlines_list($feed, $method, $view_mode, $limit, $cat_view, $next_unread_feed, $offset, $vgr_last_feed = false, $override_order = false, $include_children = false) { $disable_cache = false; $reply = array(); $timing_info = getmicrotime(); $topmost_article_ids = array(); if (!$offset) { $offset = 0; } if ($method == "undefined") { $method = ""; } $method_split = explode(":", $method); if ($method == "ForceUpdate" && $feed && is_numeric($feed) > 0) { include "rssfuncs.php"; update_rss_feed($this->link, $feed, true); } if ($method_split[0] == "MarkAllReadGR") { catchup_feed($this->link, $method_split[1], false); } // FIXME: might break tag display? if (is_numeric($feed) && $feed > 0 && !$cat_view) { $result = db_query($this->link, "SELECT id FROM ttrss_feeds WHERE id = '{$feed}' LIMIT 1"); if (db_num_rows($result) == 0) { $reply['content'] = "<div align='center'>" . __('Feed not found.') . "</div>"; } } if (is_numeric($feed) && $feed > 0) { $result = db_query($this->link, "SELECT rtl_content FROM ttrss_feeds\r\n\t\t\t\tWHERE id = '{$feed}' AND owner_uid = " . $_SESSION["uid"]); if (db_num_rows($result) == 1) { $rtl_content = sql_bool_to_bool(db_fetch_result($result, 0, "rtl_content")); } else { $rtl_content = false; } if ($rtl_content) { $rtl_tag = "dir=\"RTL\""; } else { $rtl_tag = ""; } } else { $rtl_tag = ""; $rtl_content = false; } @($search = db_escape_string($_REQUEST["query"])); if ($search) { $disable_cache = true; } @($search_mode = db_escape_string($_REQUEST["search_mode"])); @($match_on = db_escape_string($_REQUEST["match_on"])); if (!$match_on) { $match_on = "both"; } if ($_REQUEST["debug"]) { $timing_info = print_checkpoint("H0", $timing_info); } // error_log("format_headlines_list: [" . $feed . "] method [" . $method . "]"); if ($search_mode == '' && $method != '') { $search_mode = $method; } // error_log("search_mode: " . $search_mode); $qfh_ret = queryFeedHeadlines($this->link, $feed, $limit, $view_mode, $cat_view, $search, $search_mode, $match_on, $override_order, $offset, 0, false, 0, $include_children); if ($_REQUEST["debug"]) { $timing_info = print_checkpoint("H1", $timing_info); } $result = $qfh_ret[0]; $feed_title = $qfh_ret[1]; $feed_site_url = $qfh_ret[2]; $last_error = $qfh_ret[3]; $vgroup_last_feed = $vgr_last_feed; // if (!$offset) { if (db_num_rows($result) > 0) { $reply['toolbar'] = $this->format_headline_subtoolbar($feed_site_url, $feed_title, $feed, $cat_view, $search, $match_on, $search_mode, $view_mode, $last_error); } // } $headlines_count = db_num_rows($result); if (get_pref($this->link, 'COMBINED_DISPLAY_MODE')) { $button_plugins = array(); foreach (explode(",", ARTICLE_BUTTON_PLUGINS) as $p) { $pclass = trim("button_{$p}"); if (class_exists($pclass)) { $plugin = new $pclass($link); array_push($button_plugins, $plugin); } } } if (db_num_rows($result) > 0) { $lnum = $offset; $num_unread = 0; $cur_feed_title = ''; $fresh_intl = get_pref($this->link, "FRESH_ARTICLE_MAX_AGE") * 60 * 60; if ($_REQUEST["debug"]) { $timing_info = print_checkpoint("PS", $timing_info); } while ($line = db_fetch_assoc($result)) { $class = $lnum % 2 ? "even" : "odd"; $id = $line["id"]; $feed_id = $line["feed_id"]; $label_cache = $line["label_cache"]; $labels = false; if ($label_cache) { $label_cache = json_decode($label_cache, true); if ($label_cache) { if ($label_cache["no-labels"] == 1) { $labels = array(); } else { $labels = $label_cache; } } } if (!is_array($labels)) { $labels = get_article_labels($this->link, $id); } $labels_str = "<span id=\"HLLCTR-{$id}\">"; $labels_str .= format_article_labels($labels, $id); $labels_str .= "</span>"; if (count($topmost_article_ids) < 3) { array_push($topmost_article_ids, $id); } if ($line["last_read"] == "" && !sql_bool_to_bool($line["unread"])) { $update_pic = "<img id='FUPDPIC-{$id}' src=\"" . theme_image($this->link, 'images/updated.png') . "\"\r\n\t\t\t\t\t\talt=\"Updated\">"; } else { $update_pic = "<img id='FUPDPIC-{$id}' src=\"images/blank_icon.gif\"\r\n\t\t\t\t\t\talt=\"Updated\">"; } if (sql_bool_to_bool($line["unread"]) && time() - strtotime($line["updated_noms"]) < $fresh_intl) { $update_pic = "<img id='FUPDPIC-{$id}' src=\"" . theme_image($this->link, 'images/fresh_sign.png') . "\" alt=\"Fresh\">"; } if ($line["unread"] == "t" || $line["unread"] == "1") { $class .= " Unread"; ++$num_unread; $is_unread = true; } else { $is_unread = false; } if ($line["marked"] == "t" || $line["marked"] == "1") { $marked_pic = "<img id=\"FMPIC-{$id}\"\r\n\t\t\t\t\t\tsrc=\"" . theme_image($this->link, 'images/mark_set.png') . "\"\r\n\t\t\t\t\t\tclass=\"markedPic\" alt=\"Unstar article\"\r\n\t\t\t\t\t\tonclick='javascript:toggleMark({$id})'>"; } else { $marked_pic = "<img id=\"FMPIC-{$id}\"\r\n\t\t\t\t\t\tsrc=\"" . theme_image($this->link, 'images/mark_unset.png') . "\"\r\n\t\t\t\t\t\tclass=\"markedPic\" alt=\"Star article\"\r\n\t\t\t\t\t\tonclick='javascript:toggleMark({$id})'>"; } if ($line["published"] == "t" || $line["published"] == "1") { $published_pic = "<img id=\"FPPIC-{$id}\" src=\"" . theme_image($this->link, 'images/pub_set.png') . "\"\r\n\t\t\t\t\t\tclass=\"markedPic\"\r\n\t\t\t\t\t\talt=\"Unpublish article\" onclick='javascript:togglePub({$id})'>"; } else { $published_pic = "<img id=\"FPPIC-{$id}\" src=\"" . theme_image($this->link, 'images/pub_unset.png') . "\"\r\n\t\t\t\t\t\tclass=\"markedPic\"\r\n\t\t\t\t\t\talt=\"Publish article\" onclick='javascript:togglePub({$id})'>"; } # $content_link = "<a target=\"_blank\" href=\"".$line["link"]."\">" . # $line["title"] . "</a>"; # $content_link = "<a # href=\"" . htmlspecialchars($line["link"]) . "\" # onclick=\"view($id,$feed_id);\">" . # $line["title"] . "</a>"; # $content_link = "<a href=\"javascript:viewContentUrl('".$line["link"]."');\">" . # $line["title"] . "</a>"; $updated_fmt = make_local_datetime($this->link, $line["updated_noms"], false); if (get_pref($this->link, 'SHOW_CONTENT_PREVIEW')) { $content_preview = truncate_string(strip_tags($line["content_preview"]), 100); } $score = $line["score"]; $score_pic = theme_image($this->link, "images/" . get_score_pic($score)); /* $score_title = __("(Click to change)"); $score_pic = "<img class='hlScorePic' src=\"images/$score_pic\" onclick=\"adjustArticleScore($id, $score)\" title=\"$score $score_title\">"; */ $score_pic = "<img class='hlScorePic' src=\"{$score_pic}\"\r\n\t\t\t\t\ttitle=\"{$score}\">"; if ($score > 500) { $hlc_suffix = "H"; } else { if ($score < -100) { $hlc_suffix = "L"; } else { $hlc_suffix = ""; } } $entry_author = $line["author"]; if ($entry_author) { $entry_author = " - {$entry_author}"; } $has_feed_icon = feed_has_icon($feed_id); if ($has_feed_icon) { $feed_icon_img = "<img class=\"tinyFeedIcon\" src=\"" . ICONS_URL . "/{$feed_id}.ico\" alt=\"\">"; } else { $feed_icon_img = "<img class=\"tinyFeedIcon\" src=\"images/feed-icon-12x12.png\" alt=\"\">"; } if (!get_pref($this->link, 'COMBINED_DISPLAY_MODE')) { if (get_pref($this->link, 'VFEED_GROUP_BY_FEED')) { if ($feed_id != $vgroup_last_feed && $line["feed_title"]) { $cur_feed_title = $line["feed_title"]; $vgroup_last_feed = $feed_id; $cur_feed_title = htmlspecialchars($cur_feed_title); $vf_catchup_link = "(<a onclick='catchupFeedInGroup({$feed_id});' href='#'>" . __('mark as read') . "</a>)"; $reply['content'] .= "<div class='cdmFeedTitle'>" . "<div style=\"float : right\">{$feed_icon_img}</div>" . "<a href=\"#\" onclick=\"viewfeed({$feed_id})\">" . $line["feed_title"] . "</a> {$vf_catchup_link}</div>"; } } $mouseover_attrs = "onmouseover='postMouseIn({$id})'\r\n\t\t\t\t\t\tonmouseout='postMouseOut({$id})'"; $reply['content'] .= "<div class='{$class}' id='RROW-{$id}' {$mouseover_attrs}>"; $reply['content'] .= "<div class='hlUpdPic'>{$update_pic}</div>"; $reply['content'] .= "<div class='hlLeft'>"; $reply['content'] .= "<input type=\"checkbox\" onclick=\"tSR(this)\"\r\n\t\t\t\t\t\t\tid=\"RCHK-{$id}\">"; $reply['content'] .= "{$marked_pic}"; $reply['content'] .= "{$published_pic}"; $reply['content'] .= "</div>"; $reply['content'] .= "<div onclick='return hlClicked(event, {$id})'\r\n\t\t\t\t\t\tclass=\"hlTitle\"><span class='hlContent{$hlc_suffix}'>"; $reply['content'] .= "<a id=\"RTITLE-{$id}\"\r\n\t\t\t\t\t\thref=\"" . htmlspecialchars($line["link"]) . "\"\r\n\t\t\t\t\t\tonclick=\"\">" . truncate_string($line["title"], 200); if (get_pref($this->link, 'SHOW_CONTENT_PREVIEW')) { if ($content_preview) { $reply['content'] .= "<span class=\"contentPreview\"> - {$content_preview}</span>"; } } $reply['content'] .= "</a></span>"; $reply['content'] .= $labels_str; if (!get_pref($this->link, 'VFEED_GROUP_BY_FEED') && defined('_SHOW_FEED_TITLE_IN_VFEEDS')) { if (@$line["feed_title"]) { $reply['content'] .= "<span class=\"hlFeed\">\r\n\t\t\t\t\t\t\t\t(<a href=\"#\" onclick=\"viewfeed({$feed_id})\">" . $line["feed_title"] . "</a>)\r\n\t\t\t\t\t\t\t</span>"; } } $reply['content'] .= "</div>"; $reply['content'] .= "<span class=\"hlUpdated\">{$updated_fmt}</span>"; $reply['content'] .= "<div class=\"hlRight\">"; $reply['content'] .= $score_pic; if ($line["feed_title"] && !get_pref($this->link, 'VFEED_GROUP_BY_FEED')) { $reply['content'] .= "<span onclick=\"viewfeed({$feed_id})\"\r\n\t\t\t\t\t\t\tstyle=\"cursor : pointer\"\r\n\t\t\t\t\t\t\ttitle=\"" . htmlspecialchars($line['feed_title']) . "\">\r\n\t\t\t\t\t\t\t{$feed_icon_img}<span>"; } $reply['content'] .= "</div>"; $reply['content'] .= "</div>"; } else { if (get_pref($this->link, 'VFEED_GROUP_BY_FEED') && $line["feed_title"]) { if ($feed_id != $vgroup_last_feed) { $cur_feed_title = $line["feed_title"]; $vgroup_last_feed = $feed_id; $cur_feed_title = htmlspecialchars($cur_feed_title); $vf_catchup_link = "(<a onclick='javascript:catchupFeedInGroup({$feed_id});' href='#'>" . __('mark as read') . "</a>)"; $has_feed_icon = feed_has_icon($feed_id); if ($has_feed_icon) { $feed_icon_img = "<img class=\"tinyFeedIcon\" src=\"" . ICONS_URL . "/{$feed_id}.ico\" alt=\"\">"; } else { //$feed_icon_img = "<img class=\"tinyFeedIcon\" src=\"images/blank_icon.gif\" alt=\"\">"; } $reply['content'] .= "<div class='cdmFeedTitle'>" . "<div style=\"float : right\">{$feed_icon_img}</div>" . "<a href=\"#\" onclick=\"viewfeed({$feed_id})\">" . $line["feed_title"] . "</a> {$vf_catchup_link}</div>"; } } $expand_cdm = get_pref($this->link, 'CDM_EXPANDED'); $mouseover_attrs = "onmouseover='postMouseIn({$id})'\r\n\t\t\t\t\t\tonmouseout='postMouseOut({$id})'"; $reply['content'] .= "<div class=\"{$class}\"\r\n\t\t\t\t\t\tid=\"RROW-{$id}\" {$mouseover_attrs}'>"; $reply['content'] .= "<div class=\"cdmHeader\">"; $reply['content'] .= "<div>"; $reply['content'] .= "<input type=\"checkbox\" onclick=\"toggleSelectRowById(this,\r\n\t\t\t\t\t\t\t'RROW-{$id}')\" id=\"RCHK-{$id}\"/>"; $reply['content'] .= "{$marked_pic}"; $reply['content'] .= "{$published_pic}"; $reply['content'] .= "</div>"; $reply['content'] .= "<div id=\"PTITLE-FULL-{$id}\" style=\"display : none\">" . strip_tags($line['title']) . "</div>"; $reply['content'] .= "<span id=\"RTITLE-{$id}\"\r\n\t\t\t\t\t\tonclick=\"return cdmClicked(event, {$id});\"\r\n\t\t\t\t\t\tclass=\"titleWrap{$hlc_suffix}\">\r\n\t\t\t\t\t\t<a class=\"title\"\r\n\t\t\t\t\t\ttitle=\"" . htmlspecialchars($line['title']) . "\"\r\n\t\t\t\t\t\ttarget=\"_blank\" href=\"" . htmlspecialchars($line["link"]) . "\">" . truncate_string($line["title"], 100) . " {$entry_author}</a>"; $reply['content'] .= $labels_str; if (!get_pref($this->link, 'VFEED_GROUP_BY_FEED') && defined('_SHOW_FEED_TITLE_IN_VFEEDS')) { if (@$line["feed_title"]) { $reply['content'] .= "<span class=\"hlFeed\">\r\n\t\t\t\t\t\t\t\t(<a href=\"#\" onclick=\"viewfeed({$feed_id})\">" . $line["feed_title"] . "</a>)\r\n\t\t\t\t\t\t\t</span>"; } } if (!$expand_cdm) { $content_hidden = "style=\"display : none\""; } else { $excerpt_hidden = "style=\"display : none\""; } $reply['content'] .= "<span {$excerpt_hidden}\r\n\t\t\t\t\t\tid=\"CEXC-{$id}\" class=\"cdmExcerpt\"> - {$content_preview}</span>"; $reply['content'] .= "</span>"; $reply['content'] .= "<div>"; $reply['content'] .= "<span class='updated'>{$updated_fmt}</span>"; $reply['content'] .= "{$score_pic}"; if (!get_pref($this->link, "VFEED_GROUP_BY_FEED") && $line["feed_title"]) { $reply['content'] .= "<span style=\"cursor : pointer\"\r\n\t\t\t\t\t\t\ttitle=\"" . htmlspecialchars($line["feed_title"]) . "\"\r\n\t\t\t\t\t\t\tonclick=\"viewfeed({$feed_id})\">{$feed_icon_img}</span>"; } $reply['content'] .= "<div class=\"updPic\">{$update_pic}</div>"; $reply['content'] .= "</div>"; $reply['content'] .= "</div>"; $reply['content'] .= "<div class=\"cdmContent\" {$content_hidden}\r\n\t\t\t\t\t\tonclick=\"return cdmClicked(event, {$id});\"\r\n\t\t\t\t\t\tid=\"CICD-{$id}\">"; $reply['content'] .= "<div class=\"cdmContentInner\">"; if ($line["orig_feed_id"]) { $tmp_result = db_query($this->link, "SELECT * FROM ttrss_archived_feeds\r\n\t\t\t\t\tWHERE id = " . $line["orig_feed_id"]); if (db_num_rows($tmp_result) != 0) { $reply['content'] .= "<div clear='both'>"; $reply['content'] .= __("Originally from:"); $reply['content'] .= " "; $tmp_line = db_fetch_assoc($tmp_result); $reply['content'] .= "<a target='_blank'\r\n\t\t\t\t\t\t\t\thref=' " . htmlspecialchars($tmp_line['site_url']) . "'>" . $tmp_line['title'] . "</a>"; $reply['content'] .= " "; $reply['content'] .= "<a target='_blank' href='" . htmlspecialchars($tmp_line['feed_url']) . "'>"; $reply['content'] .= "<img title='" . __('Feed URL') . "'class='tinyFeedIcon' src='images/pub_set.png'></a>"; $reply['content'] .= "</div>"; } } $feed_site_url = $line["site_url"]; $article_content = sanitize($this->link, $line["content_preview"], false, false, $feed_site_url); $reply['content'] .= "<div id=\"POSTNOTE-{$id}\">"; if ($line['note']) { $reply['content'] .= format_article_note($id, $line['note']); } $reply['content'] .= "</div>"; $reply['content'] .= "<span id=\"CWRAP-{$id}\">"; $reply['content'] .= $expand_cdm ? $article_content : ''; $reply['content'] .= "</span>"; /* $tmp_result = db_query($this->link, "SELECT always_display_enclosures FROM ttrss_feeds WHERE id = ". (($line['feed_id'] == null) ? $line['orig_feed_id'] : $line['feed_id'])." AND owner_uid = ".$_SESSION["uid"]); $always_display_enclosures = sql_bool_to_bool(db_fetch_result($tmp_result, 0, "always_display_enclosures")); */ $always_display_enclosures = sql_bool_to_bool($line["always_display_enclosures"]); $reply['content'] .= format_article_enclosures($this->link, $id, $always_display_enclosures, $article_content); $reply['content'] .= "</div>"; $reply['content'] .= "<div class=\"cdmFooter\">"; $tag_cache = $line["tag_cache"]; $tags_str = format_tags_string(get_article_tags($this->link, $id, $_SESSION["uid"], $tag_cache), $id); $reply['content'] .= "<img src='" . theme_image($this->link, 'images/tag.png') . "' alt='Tags' title='Tags'>\r\n\t\t\t\t\t\t<span id=\"ATSTR-{$id}\">{$tags_str}</span>\r\n\t\t\t\t\t\t<a title=\"" . __('Edit tags for this article') . "\"\r\n\t\t\t\t\t\thref=\"#\" onclick=\"editArticleTags({$id}, {$feed_id}, true)\">(+)</a>"; $num_comments = $line["num_comments"]; $entry_comments = ""; if ($num_comments > 0) { if ($line["comments"]) { $comments_url = $line["comments"]; } else { $comments_url = $line["link"]; } $entry_comments = "<a target='_blank' href=\"{$comments_url}\">{$num_comments} comments</a>"; } else { if ($line["comments"] && $line["link"] != $line["comments"]) { $entry_comments = "<a target='_blank' href=\"" . $line["comments"] . "\">comments</a>"; } } if ($entry_comments) { $reply['content'] .= " ({$entry_comments})"; } $reply['content'] .= "<div style=\"float : right\">"; $reply['content'] .= "<img src=\"images/art-zoom.png\"\r\n\t\t\t\t\t\tonclick=\"zoomToArticle(event, {$id})\"\r\n\t\t\t\t\t\tstyle=\"cursor : pointer\"\r\n\t\t\t\t\t\talt='Zoom'\r\n\t\t\t\t\t\ttitle='" . __('Open article in new tab') . "'>"; //$note_escaped = htmlspecialchars($line['note'], ENT_QUOTES); foreach ($button_plugins as $p) { $reply['content'] .= $p->render($id, $line); } $reply['content'] .= "<img src=\"images/digest_checkbox.png\"\r\n\t\t\t\t\t\tstyle=\"cursor : pointer\" style=\"cursor : pointer\"\r\n\t\t\t\t\t\tonclick=\"dismissArticle({$id})\"\r\n\t\t\t\t\t\ttitle='" . __('Close article') . "'>"; $reply['content'] .= "</div>"; $reply['content'] .= "</div>"; $reply['content'] .= "</div>"; $reply['content'] .= "</div>"; } ++$lnum; } if ($_REQUEST["debug"]) { $timing_info = print_checkpoint("PE", $timing_info); } } else { $message = ""; switch ($view_mode) { case "unread": $message = __("No unread articles found to display."); break; case "updated": $message = __("No updated articles found to display."); break; case "marked": $message = __("No starred articles found to display."); break; default: if ($feed < -10) { $message = __("No articles found to display. You can assign articles to labels manually (see the Actions menu above) or use a filter."); } else { $message = __("No articles found to display."); } } if (!$offset && $message) { $reply['content'] .= "<div class='whiteBox'>{$message}"; $reply['content'] .= "<p class=\"small\"><span class=\"insensitive\">"; $result = db_query($this->link, "SELECT " . SUBSTRING_FOR_DATE . "(MAX(last_updated), 1, 19) AS last_updated FROM ttrss_feeds\r\n\t\t\t\t\tWHERE owner_uid = " . $_SESSION['uid']); $last_updated = db_fetch_result($result, 0, "last_updated"); $last_updated = make_local_datetime($this->link, $last_updated, false); $reply['content'] .= sprintf(__("Feeds last updated at %s"), $last_updated); $result = db_query($this->link, "SELECT COUNT(id) AS num_errors\r\n\t\t\t\t\tFROM ttrss_feeds WHERE last_error != '' AND owner_uid = " . $_SESSION["uid"]); $num_errors = db_fetch_result($result, 0, "num_errors"); if ($num_errors > 0) { $reply['content'] .= "<br/>"; $reply['content'] .= "<a class=\"insensitive\" href=\"#\" onclick=\"showFeedsWithErrors()\">" . __('Some feeds have update errors (click for details)') . "</a>"; } $reply['content'] .= "</span></p></div>"; } } if ($_REQUEST["debug"]) { $timing_info = print_checkpoint("H2", $timing_info); } return array($topmost_article_ids, $headlines_count, $feed, $disable_cache, $vgroup_last_feed, $reply); }
echo ' <a style="position:absolute; top:1rem;" tabindex="0" data-toggle="popover" data-html="true" data-title="' . $theposterdata['uname'] . '" data-content=\'' . member_qualif($theposterdata['uname'], $theposterdata['posts'], $theposterdata['rank']) . '\'><img class=" btn-secondary img-thumbnail img-fluid n-ava" src="' . $imgtmp . '" alt="' . $theposterdata['uname'] . '" /></a>'; } } echo ' <span style="position:absolute; left:6rem;" class="text-muted"><strong>' . $userdatat[1] . '</strong></span> <span class="float-xs-right">'; if (isset($image_subject)) { if ($ibid = theme_image("forum/subject/{$image_subject}")) { $imgtmp = $ibid; } else { $imgtmp = "images/forum/subject/{$image_subject}"; } echo '<img class="n-smil" src="' . $imgtmp . '" alt="" />'; } else { if ($ibid = theme_image("forum/icons/posticon.gif")) { $imgtmpP = $ibid; } else { $imgtmpP = "images/forum/icons/posticon.gif"; } echo '<img class="n-smil" src="' . $imgtmpP . '" alt="" />'; } echo '</span> </div> <div class="card-block"> <span class="text-muted float-xs-right small" style="margin-top:-1rem;">' . translate("Posted: ") . $time . '</span> <div id="post_preview" class="card-text pt-2">'; $messageP = stripslashes($messageP); if ($forum_type == '6' or $forum_type == '5') { highlight_string(stripslashes($messageP)); } else {
if ($ibid = theme_image("stats/sections.png")) { $imgtmpS = $ibid; } else { $imgtmpS = "images/admin/sections.png"; } echo ' <li class="list-group-item"><img src="' . $imgtmpS . '" alt="" /> ' . translate("Special Sections: ") . ' <span class="tag tag-default float-xs-right">' . wrh($secnum) . ' </span></li>'; if ($ibid = theme_image("stats/sections.png")) { $imgtmp = $ibid; } else { $imgtmp = "images/admin/sections.png"; } echo ' <li class="list-group-item"><img src="' . $imgtmp . '" alt="" /> ' . translate("Articles in Sections: ") . ' <span class="tag tag-default float-xs-right">' . wrh($secanum) . ' </span></li>'; echo ' <li class="list-group-item"><i class="fa fa-link fa-2x text-muted"></i> ' . translate("Links in Web Links: ") . ' <span class="tag tag-default float-xs-right">' . wrh($links) . ' </span></li> <li class="list-group-item"><i class="fa fa-link fa-2x text-muted"></i> ' . translate("Categories in Web Links: ") . ' <span class="tag tag-default float-xs-right">' . wrh($cat) . ' </span></li>'; if ($ibid = theme_image("stats/submissions.png")) { $imgtmp = $ibid; } else { $imgtmp = "images/admin/submissions.png"; } echo ' <li class="list-group-item"><img src="' . $imgtmp . '" alt="" /> ' . translate("News Waiting to be Published: ") . ' <span class="tag tag-default float-xs-right">' . wrh($subnum) . ' </span></li> <li class="list-group-item"><i class="fa fa-cogs fa-2x text-muted"></i> Version Num <span class="tag tag-danger float-xs-right">' . $Version_Num . '</span></li> <li class="list-group-item"><i class="fa fa-cogs fa-2x text-muted"></i> Version Id <span class="tag tag-danger float-xs-right">' . $Version_Id . '</span></li> <li class="list-group-item"><i class="fa fa-cogs fa-2x text-muted"></i> Version Sub <span class="tag tag-danger float-xs-right">' . $Version_Sub . '</span></li> </ul> <br /> <p align="center"><a href="http://www.npds.org" >http://www.npds.org</a> - French Portal Generator Gnu/Gpl Licence</p><br />'; include "footer.php";
function hook_article_button($line) { return "<img src=\"" . theme_image($link, 'plugins/mail/mail.png') . "\"\n\t\t\t\t\tclass='tagsPic' style=\"cursor : pointer\"\n\t\t\t\t\tonclick=\"emailArticle(" . $line["id"] . ")\"\n\t\t\t\t\talt='Zoom' title='" . __('Forward by email') . "'>"; }
<?php } ?> <?php if ($mission != "") { ?> <div id="mission"><?php print $mission; ?> </div> <?php } ?> <?php print theme_image(path_to_theme() . '/images/slogan.gif', '', '', array('class' => 'slogan-img')); ?> </div> <div class="head-row2"> <div class="col1"> <?php if (isset($primary_links)) { ?> <div class="pr-menu"> <?php print theme('links', $primary_links, array('class' => 'links primary-links')); ?> </div> <?php } ?>
function get_item_image($s_item_type, $item_id = NULL) { if (strlen($s_item_type) > 0 || ($s_item_type = fetch_item_type($item_id))) { $item_type_r = fetch_item_type_r($s_item_type); if (is_array($item_type_r)) { // default $imagetext = $s_item_type; // Get image block. if (strlen($item_type_r['image']) > 0) { if (strlen($item_type_r['description']) > 0) { $title_text = htmlspecialchars($item_type_r['description']); } else { $title_text = NULL; } $imagetext = theme_image($item_type_r['image'], $title_text, 's_item_type'); } return $imagetext; } } return FALSE; }
print $classes; ?> clearfix"<?php print $attributes; ?> > <div class="content"<?php print $content_attributes; ?> > <div class="resume-photo"> <?php if (!empty($content['field_resume_photo'])) { print render($content['field_resume_photo']); } else { print theme_image(array('path' => drupal_get_path('theme', 'cloudy') . '/images/recruiter/resume_default.jpg', 'attributes' => array())); } ?> </div> <div class="resume-info clearfix"> <?php if (isset($content['full_name'])) { ?> <div class="field field-name clearfix"> <div class="field__label">Name: </div> <div class="field-items"><div class="field-item even"><?php print render($content['full_name']); ?> </div></div> </div> <?php
function setScore() { $ids = db_escape_string($_REQUEST['id']); $score = (int) db_escape_string($_REQUEST['score']); db_query($this->link, "UPDATE ttrss_user_entries SET\n\t\t\tscore = '{$score}' WHERE ref_id IN ({$ids}) AND owner_uid = " . $_SESSION["uid"]); print json_encode(array("id" => $id, "score_pic" => theme_image($link, get_score_pic($score)))); }