diff options
Diffstat (limited to 'views/php/export/entity.php')
| -rw-r--r-- | views/php/export/entity.php | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/views/php/export/entity.php b/views/php/export/entity.php index 161401620..d2bcc0d58 100644 --- a/views/php/export/entity.php +++ b/views/php/export/entity.php @@ -1,16 +1,19 @@ <?php - /** - * Elgg Entity export. - * Displays an entity as PHP serialised data - * - * @package Elgg - * @subpackage Core - * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2 - * @author Marcus Povey - * @copyright Curverider Ltd 2008 - * @link http://elgg.org/ - */ +/** + * Elgg Entity export. + * Displays an entity as PHP serialised data + * + * @package Elgg + * @subpackage Core + */ - $entity = $vars['entity']; - echo serialize($entity); -?>
\ No newline at end of file +$entity = $vars['entity']; + +$export = new stdClass; +$exportable_values = $entity->getExportableValues(); + +foreach ($exportable_values as $v) { + $export->$v = $entity->$v; +} + +echo serialize($export); |
