summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/gallery/controllers/user_profile.php1
-rw-r--r--modules/gallery/helpers/user_profile.php3
-rw-r--r--modules/gallery/views/user_profile.html.php10
3 files changed, 9 insertions, 5 deletions
diff --git a/modules/gallery/controllers/user_profile.php b/modules/gallery/controllers/user_profile.php
index 53c76a48..a0e6619e 100644
--- a/modules/gallery/controllers/user_profile.php
+++ b/modules/gallery/controllers/user_profile.php
@@ -33,7 +33,6 @@ class User_Profile_Controller extends Controller {
$v->content->user = $user;
$v->content->not_current = !$is_current_active;
$v->content->editable = identity::is_writable() && $display_all;
- $v->content->return = SafeString::of(Input::instance()->get("return"));
$event_data = (object)array("user" => $user, "display_all" => $display_all, "content" => array());
module::event("show_user_profile", $event_data);
diff --git a/modules/gallery/helpers/user_profile.php b/modules/gallery/helpers/user_profile.php
index 018e1bd1..95a994bc 100644
--- a/modules/gallery/helpers/user_profile.php
+++ b/modules/gallery/helpers/user_profile.php
@@ -24,8 +24,7 @@ class user_profile_Core {
* @return url for the profile display
*/
static function url($user_id) {
- $return_url = urlencode(url::abs_current());
- return url::site("user_profile/show/{$user_id}?return=$return_url");
+ return url::site("user_profile/show/{$user_id}");
}
static function get_contact_form($user) {
diff --git a/modules/gallery/views/user_profile.html.php b/modules/gallery/views/user_profile.html.php
index bcfa5346..708b1613 100644
--- a/modules/gallery/views/user_profile.html.php
+++ b/modules/gallery/views/user_profile.html.php
@@ -21,8 +21,14 @@
border: none;
padding: 0;
}
-
</style>
+<script>
+ $(document).ready(function() {
+ $("#g-profile-return").click(function(event) {
+ history.go(-1);
+ })
+ });
+</script>
<div id="g-user-profile">
<h1>
<a href="#">
@@ -55,7 +61,7 @@
</a>
<? endif ?>
- <a class="g-button ui-icon-right ui-state-default ui-corner-all" href="<?= $return->for_html_attr() ?>">
+ <a id="g-profile-return" class="g-button ui-icon-right ui-state-default ui-corner-all" href="#">
<?= t("Return") ?>
</a>
</div>