Exemplo n.º 1
0
 /**
  * Displays the pagination links at the bottom of the page.
  *
  * @since	5.0
  * @access	public
  * @param	string
  * @return	
  */
 public function toHTML($view = 'index', $replace = false)
 {
     // Retrieve the pagination data.
     $data = $this->getData();
     // If there's no pagination at all, skip this
     if (count($data->pages) == $this->get('pages.total') && $this->get('pages.total') == 1 || $this->get('pages.total') == 0) {
         return false;
     }
     $queries = '';
     if (!empty($data) && $replace) {
         $currentPageLink = 'index.php?option=com_easyblog&view=' . $view . $queries;
         foreach ($data->pages as $page) {
             if (!empty($page->link)) {
                 $limitstart = !empty($page->base) ? '&limitstart=' . $page->base : '';
                 $page->link = EBR::_($currentPageLink . $limitstart);
             }
         }
         if (!empty($data->next->link)) {
             $limitstart = !empty($data->next->base) ? '&limitstart=' . $data->next->base : '';
             $data->next->link = EBR::_($currentPageLink . $limitstart);
         }
         if (!empyt($data->previous->link)) {
             $limitstart = !empty($data->previous->base) ? '&limitstart=' . $data->previous->base : '';
             $data->previous->link = EBR::_($currentPageLink . $limitstart);
         }
     }
     $template = EB::template();
     $template->set('data', $data);
     return $template->output('site/blogs/pagination/default');
 }
Exemplo n.º 2
0
 * Portions created by vtiger are Copyright (C) vtiger.
 * All Rights Reserved.
 ********************************************************************************/
require_once 'include/CustomFieldUtil.php';
require_once 'Smarty_setup.php';
global $mod_strings, $app_strings, $app_list_strings, $theme, $adb;
global $log;
$theme_path = "themes/" . $theme . "/";
$image_path = $theme_path . "images/";
$visible = vtlib_purify($_REQUEST['visible']);
$disable = vtlib_purify($_REQUEST['disable']);
$label = getTranslatedString(vtlib_purify($_REQUEST['label']));
require_once $theme_path . 'layout_utils.php';
$fieldModule = vtlib_purify($_REQUEST['fld_module']);
$fieldId = vtlib_purify($_REQUEST['fieldid']);
if (empty($fieldModule) || empyt($fieldId)) {
    exit;
}
$output .= '<div class="layerPopup" style="position:relative; display:block">' . '	<form action="index.php" method="post" name="fieldinfoform" onsubmit="VtigerJS_DialogBox.block();"> 
			<input type="hidden" name="module" value="Settings">
	  		<input type="hidden" name="action" value="SettingsAjax">
	  		<input type="hidden" name="fld_module" value="' . $fieldModule . '">
	  		<input type="hidden" name="parenttab" value="Settings">
          	<input type="hidden" name="file" value="UpdateMandatoryFields">
 			<input type="hidden" name="fieldid" value="' . $fieldId . '">
 			<table width="100%" border="0" cellpadding="5" cellspacing="0" class="layerHeadingULine">
				<tr>
					<td width="95%" align="left" class="layerPopupHeading">' . $label . '</td>
			
					<td width="5%" align="right"><a href="javascript:fninvsh(\'fieldInfo\');"><img src="' . vtiger_imageurl('editfield.gif', $theme) . '" border="0"  align="absmiddle" /></a></td>
				</tr>