Open Monograph Press  1.1
 All Classes Namespaces Functions Variables Groups Pages
AddThisStatisticsGridCellProvider.inc.php
1 <?php
2 
16 import('lib.pkp.classes.controllers.grid.DataObjectGridCellProvider');
17 
23  parent::DataObjectGridCellProvider();
24  }
25 
26  //
27  // Template methods from GridCellProvider
28  //
36  function getTemplateVarsFromRowColumn($row, $column) {
37  $element =& $row->getData();
38  $columnId = $column->getId();
39  assert(!empty($columnId));
40  switch ($columnId) {
41  case 'url':
42  return array('label' => '<a href="' . String::stripUnsafeHtml($element['url']) . '" target="_blank">' . String::stripUnsafeHtml($element['url']) . '</a>');
43  case 'shares':
44  return array('label' => $element['shares']);
45  }
46  }
47 }
48 
49 ?>
Base class for a cell provider that can retrieve labels for AddThis stats.
static stripUnsafeHtml($input)
Definition: String.inc.php:440
Base class for a cell provider that can retrieve simple labels from DataObjects. If you need more com...