From 8a73760babd122ece9a30c371007bb7f119d02e0 Mon Sep 17 00:00:00 2001
From: Eric Rasmussen <erasmussen2@unl.edu>
Date: Mon, 26 Apr 2010 20:54:17 +0000
Subject: [PATCH] flexprofile edit needs action tokens now for 1.7

---
 plugins/flexprofile_mj/views/default/profile/edit.php | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/plugins/flexprofile_mj/views/default/profile/edit.php b/plugins/flexprofile_mj/views/default/profile/edit.php
index 82883a0f..14c3b745 100755
--- a/plugins/flexprofile_mj/views/default/profile/edit.php
+++ b/plugins/flexprofile_mj/views/default/profile/edit.php
@@ -29,11 +29,16 @@ if ($_GET['firstlogin'] == 'yes'){
 </div>
 <?php 
 }
+
+$ts = time();
+$token = generate_action_token($ts); 
+
+
 /* import forms css */
 echo '<style type="text/css">@IMPORT url("/wdn/templates_3.0/css/content/forms.css");</style>';
 /* add 'cool' class to form */
 echo '<div id="formloading"><img src="/wdn/templates_3.0/css/header/images/colorbox/loading.gif" alt="Loading Form" /><noscript>Please enable JavaScript to use the profile editor.</noscript></div>';
-echo '<form style="margin-top: 24px" action="'.$vars['url'].'action/flexprofile/edit" method="post" enctype="multipart/form-data" class="cool">';
+echo '<form style="margin-top: 24px" action="'.$vars['url'].'action/flexprofile/edit?__elgg_ts='.$ts.'&__elgg_token='.$token.'" method="post" enctype="multipart/form-data" class="cool">';
 /* add fieldset and legend */
 echo '<fieldset><legend>Edit Information</legend><ol>';
 /* mjuhl: remove dynamic form by commenting out the following line: */
-- 
GitLab