diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2010-01-28 09:27:27 -0800 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2010-01-28 09:27:27 -0800 |
commit | c51fe9682075c961972c344f4888a4adceabe3eb (patch) | |
tree | 85edb38d8dae86812e4b6c420f16b0027827ccce /modules/gallery | |
parent | 75aec29350442351299c5ecadfa07042b857c558 (diff) |
Make the varible for the profile name more descriptive and clean the label
Diffstat (limited to 'modules/gallery')
-rw-r--r-- | modules/gallery/helpers/gallery_event.php | 4 | ||||
-rw-r--r-- | modules/gallery/tests/xss_data.txt | 1 | ||||
-rw-r--r-- | modules/gallery/views/user_profile_info.html.php | 4 |
3 files changed, 4 insertions, 5 deletions
diff --git a/modules/gallery/helpers/gallery_event.php b/modules/gallery/helpers/gallery_event.php index 9b252f61..b3d4daab 100644 --- a/modules/gallery/helpers/gallery_event.php +++ b/modules/gallery/helpers/gallery_event.php @@ -404,14 +404,14 @@ class gallery_event_Core { if (!$data->display_all) { $fields = array("name" => t("Name"), "full_name" => t("Full name"), "url" => "Web site"); } - $v->fields = array(); + $v->user_profile_data = array(); foreach ($fields as $field => $label) { if (!empty($data->user->$field)) { $value = $data->user->$field; if ($field == "locale") { $value = locales::display_name($value); } - $v->fields[(string) $label] = $value; + $v->user_profile_data[(string) $label] = $value; } } $data->content[] = (object) array("title" => t("User information"), "view" => $v); diff --git a/modules/gallery/tests/xss_data.txt b/modules/gallery/tests/xss_data.txt index 04add4c7..663080a0 100644 --- a/modules/gallery/tests/xss_data.txt +++ b/modules/gallery/tests/xss_data.txt @@ -224,7 +224,6 @@ modules/gallery/views/upgrader.html.php 102 DIRTY_ATTR $don modules/gallery/views/user_languages_block.html.php 2 DIRTY form::dropdown("g-select-session-locale",$installed_locales,$selected) modules/gallery/views/user_profile.html.php 35 DIRTY_ATTR $user->avatar_url(40,$theme->url(,true)) modules/gallery/views/user_profile.html.php 46 DIRTY $info->view -modules/gallery/views/user_profile_info.html.php 5 DIRTY $field modules/image_block/views/image_block_block.html.php 3 DIRTY_JS $item->url() modules/image_block/views/image_block_block.html.php 4 DIRTY $item->thumb_img(array("class"=>"g-thumbnail")) modules/info/views/info_block.html.php 22 DIRTY date("M j, Y H:i:s",$item->captured) diff --git a/modules/gallery/views/user_profile_info.html.php b/modules/gallery/views/user_profile_info.html.php index 2f2d68d3..58e134bb 100644 --- a/modules/gallery/views/user_profile_info.html.php +++ b/modules/gallery/views/user_profile_info.html.php @@ -1,8 +1,8 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> <table> - <? foreach ($fields as $field => $value): ?> + <? foreach ($user_profile_data as $label => $value): ?> <tr> - <td><?= $field ?></td> + <td><?= html::clean($label) ?></td> <td><?= html::purify($value) ?></td> </tr> <? endforeach ?> |