当前位置: 首页>>代码示例>>PHP>>正文


PHP DashletGeneric::display方法代码示例

本文整理汇总了PHP中DashletGeneric::display方法的典型用法代码示例。如果您正苦于以下问题:PHP DashletGeneric::display方法的具体用法?PHP DashletGeneric::display怎么用?PHP DashletGeneric::display使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DashletGeneric的用法示例。


在下文中一共展示了DashletGeneric::display方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: display

 /**
  *
  * @return the fully rendered dashlet
  */
 function display()
 {
     $listview = parent::display();
     $GLOBALS['current_sugarfeed'] = $this;
     $listview = preg_replace_callback('/\\{([^\\^ }]+)\\.([^\\}]+)\\}/', create_function('$matches', 'if($matches[1] == "this"){$var = $matches[2]; return $GLOBALS[\'current_sugarfeed\']->$var;}else{return translate($matches[2], $matches[1]);}'), $listview);
     $listview = preg_replace('/\\[(\\w+)\\:([\\w\\-\\d]*)\\:([^\\]]*)\\]/', '<a href="index.php?module=$1&action=DetailView&record=$2"><img src="themes/default/images/$1.gif" border=0>$3</a>', $listview);
     return $listview . '</div></div>';
 }
开发者ID:nickpro,项目名称:sugarcrm_dev,代码行数:12,代码来源:SugarFeedDashlet.php

示例2: display

 /**
  *
  * @return the fully rendered dashlet
  */
 function display()
 {
     $listview = parent::display();
     $GLOBALS['current_sugarfeed'] = $this;
     $listview = preg_replace_callback('/\\{([^\\^ }]+)\\.([^\\}]+)\\}/', create_function('$matches', 'if($matches[1] == "this"){$var = $matches[2]; return $GLOBALS[\'current_sugarfeed\']->$var;}else{return translate($matches[2], $matches[1]);}'), $listview);
     //grab each token and store the module for later processing
     preg_match_all('/\\[(\\w+)\\:/', $listview, $alt_modules);
     //now process each token to create the proper url and image tags in feed, leaving a string for the alt to be replaced in next step
     $listview = preg_replace('/\\[(\\w+)\\:([\\w\\-\\d]*)\\:([^\\]]*)\\]/', '<a href="index.php?module=$1&action=DetailView&record=$2"><img src="themes/default/images/$1.gif" border=0 REPLACE_ALT>$3</a>', $listview);
     /*SKIP_IMAGE_TAG*/
     //process each module for the singular version so we can populate the alt tag on the image
     $altStrings = array();
     foreach ($alt_modules[1] as $alt) {
         //create the alt string and replace the alt token
         $altString = 'alt="' . translate('LBL_VIEW', 'SugarFeed') . ' ' . $GLOBALS['app_list_strings']['moduleListSingular'][$alt] . '"';
         $listview = preg_replace('/REPLACE_ALT/', $altString, $listview, 1);
     }
     return $listview . '</div></div>';
 }
开发者ID:netconstructor,项目名称:sugarcrm_dev,代码行数:23,代码来源:SugarFeedDashlet.php

示例3: display

 /**
  * 
  * @return the fully rendered dashlet
  */
 function display()
 {
     $listview = parent::display();
     $GLOBALS['current_groupmessage'] = $this;
     $listview = preg_replace_callback('/\\{([^\\}]+)\\.([^\\}]+)\\}/', create_function('$matches', 'if($matches[1] == "this"){$var = $matches[2]; return $GLOBALS[\'current_groupmessage\']->$var;}else{return translate($matches[2], $matches[1]);}'), $listview);
     $listview = preg_replace('/\\[(\\w+)\\:([\\w\\-\\d]*)\\:([^\\]]*)\\]/', '<a href="index.php?module=$1&action=DetailView&record=$2"><img src="themes/default/images/$1.gif" border=0>$3</a>', $listview);
     // Make this dashlet scroll if it gets too large
     $listview = '<div class="sugarFeedDashlet">' . $listview . '</div>';
     return $listview;
 }
开发者ID:sysraj86,项目名称:carnivalcrm,代码行数:14,代码来源:MessageDashlet.php


注:本文中的DashletGeneric::display方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。