Skip to content

Commit

Permalink
feat: Check session when users submit forms
Browse files Browse the repository at this point in the history
  • Loading branch information
live627 committed Mar 25, 2021
1 parent e00b3c6 commit bf7139a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/CustomForm.php
Expand Up @@ -99,6 +99,7 @@ function CustomForm()
// Do we need to submit this form?
if (isset($_GET['submit']))
{
checkSession();
$vars = array();
$replace = array();
$i = -1;
Expand Down
2 changes: 1 addition & 1 deletion src/CustomForm.template.php
Expand Up @@ -109,7 +109,7 @@ function form_template_submit_form()
</td>
</tr>
</table>
<input type="hidden" name="sc" value="', $context['session_id'], '" />
<input type="hidden" name="', $context['session_var'], '" value="', $context['session_id'], '">
</form>';
}

Expand Down

0 comments on commit bf7139a

Please sign in to comment.