From 5886aef3ade570f733ba4f870e8d19dfd0dbd651 Mon Sep 17 00:00:00 2001 From: Loic d'Anterroches Date: Sun, 7 Dec 2008 14:56:06 +0100 Subject: [PATCH] Added the terms and conditions. These are simple terms, just to allow people to adapt them later. --- src/IDF/Views.php | 6 +++++- src/IDF/templates/idf/register/index.html | 16 +++++++++++++-- src/IDF/templates/idf/terms.html | 24 +++++++++++++++++++++++ www/media/idf/css/style.css | 8 +++++++- 4 files changed, 50 insertions(+), 4 deletions(-) create mode 100644 src/IDF/templates/idf/terms.html diff --git a/src/IDF/Views.php b/src/IDF/Views.php index 2c846f4..4c0e7b0 100644 --- a/src/IDF/Views.php +++ b/src/IDF/Views.php @@ -95,9 +95,13 @@ class IDF_Views $init = (isset($request->GET['login'])) ? array('initial' => array('login' => $request->GET['login'])) : array(); $form = new IDF_Form_Register(null, $init); } + $context = new Pluf_Template_Context(array()); + $tmpl = new Pluf_Template('idf/terms.html'); + $terms = Pluf_Template::markSafe($tmpl->render($context)); return Pluf_Shortcuts_RenderToResponse('idf/register/index.html', array('page_title' => $title, - 'form' => $form), + 'form' => $form, + 'terms' => $terms), $request); } diff --git a/src/IDF/templates/idf/register/index.html b/src/IDF/templates/idf/register/index.html index 3972bbb..9799cc9 100644 --- a/src/IDF/templates/idf/register/index.html +++ b/src/IDF/templates/idf/register/index.html @@ -25,12 +25,16 @@ {$form.f.email.help_text} + +  +
{$terms}
+   {if $form.f.terms.errors}{$form.f.terms.fieldErrors}{/if} {$form.f.terms|unsafe} {$form.f.terms.labelTag}
-{blocktrans}Read the terms and conditions – basically "Please be nice, we respect you".{/blocktrans} +{blocktrans}Read the terms and conditions – basically "Please be nice, we respect you".{/blocktrans} @@ -51,7 +55,15 @@ {/block} {block javascript} {/block} diff --git a/src/IDF/templates/idf/terms.html b/src/IDF/templates/idf/terms.html new file mode 100644 index 0000000..4b25303 --- /dev/null +++ b/src/IDF/templates/idf/terms.html @@ -0,0 +1,24 @@ +

Terms and Conditions

+ +

Legal stuff

+ + + +

Technical stuff

+ + + +

Very important stuff

+ +

You are welcome!

+ diff --git a/www/media/idf/css/style.css b/www/media/idf/css/style.css index 3a8f0ac..99abc93 100644 --- a/www/media/idf/css/style.css +++ b/www/media/idf/css/style.css @@ -19,7 +19,7 @@ # # ***** END LICENSE BLOCK ***** */ -h2.top { +.top { margin-top: 0; } @@ -120,6 +120,12 @@ div.user-messages { width: 90%; } +div.theterms { + border: 1px solid rgb(229, 225, 169); + background-color: #fffde3; + padding: 1em 1em 0 1em; +} + /** * Recent issues