diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2010-01-28 07:44:58 -0800 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2010-01-28 07:44:58 -0800 |
commit | cedbc82dccaf74a983f1f92846735b69391fdf10 (patch) | |
tree | 22e39f1f74d9ab6bbc6a2f4292f504b76109deea /modules/gallery/controllers/user_profile.php | |
parent | bbe70119ef99e77a57dbc5354bc348c7adaece46 (diff) |
Do all the html::clean|purify calls in the views and not the controller. Also clean the subject line and email message body of the contact user email.
Diffstat (limited to 'modules/gallery/controllers/user_profile.php')
-rw-r--r-- | modules/gallery/controllers/user_profile.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/gallery/controllers/user_profile.php b/modules/gallery/controllers/user_profile.php index a0e6619e..327d2ff1 100644 --- a/modules/gallery/controllers/user_profile.php +++ b/modules/gallery/controllers/user_profile.php @@ -53,11 +53,11 @@ class User_Profile_Controller extends Controller { if ($form->validate()) { Sendmail::factory() ->to($user->email) - ->subject($form->message->subject->value) + ->subject(html::clean($form->message->subject->value)) ->header("Mime-Version", "1.0") ->header("Content-type", "text/html; charset=iso-8859-1") ->reply_to($form->message->reply_to->value) - ->message($form->message->message->value) + ->message(html::purify($form->message->message->value)) ->send(); message::success(t("Sent message to %user_name", array("user_name" => $user->display_name()))); print json_encode(array("result" => "success")); |