Commit 7214871d authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Make homepage info text translatable


Signed-off-by: default avatarRichard Mansfield <richardm@catalyst.net.nz>
parent c3aeed30
......@@ -87,6 +87,19 @@ else {
$smarty = smarty();
}
// Assign urls used in homeinfo.tpl
$wwwroot = get_config('wwwroot');
$urls = array(
'profile' => $wwwroot . 'artefact/internal',
'files' => $wwwroot . 'artefact/file',
'resume' => $wwwroot . 'artefact/resume',
'blog' => $wwwroot . 'artefact/blog',
'views' => $wwwroot . 'view',
'friends' => $wwwroot . 'user/find.php',
'groups' => $wwwroot . 'group/find.php',
);
$smarty->assign('url', $urls);
$smarty->assign('page_content', get_site_page_content($pagename));
$smarty->display('index.tpl');
......
......@@ -905,4 +905,21 @@ $string['pleasedonotreplytothismessage'] = "Please do not reply to this message.
$string['deleteduser'] = 'Deleted user';
$string['theme'] = 'Theme';
// Home page info block
$string['Hide'] = 'Hide';
$string['createcollect'] = 'Create and Collect';
$string['createcollectsubtitle'] = 'Develop your portfolio';
$string['updateyourprofile'] = 'Update your <a href="%s">Profile</a>';
$string['uploadyourfiles'] = 'Upload your <a href="%s">Files</a>';
$string['createyourresume'] = 'Create your <a href="%s">Resume</a>';
$string['publishablog'] = 'Publish a <a href="%s">Blog</a>';
$string['Organise'] = 'Organise';
$string['organisesubtitle'] = 'Showcase your portfolio with views';
$string['organisedescription'] = 'Organise your portfolio into <a href="%s">Views.</a> Create different views for different audiences - you choose the elements to include.';
$string['sharenetwork'] = 'Share and Network';
$string['sharenetworksubtitle'] = 'Meet friends and join groups';
$string['findfriends'] = 'Find <a href="%s">Friends</a>';
$string['joingroups'] = 'Join <a href="%s">Groups</a>';
$string['sharenetworkdescription'] = 'You can fine-tune who has access to each view, and for how long.';
?>
......@@ -2,62 +2,54 @@
<tr>
<td>
{if $USER->is_logged_in()}
<a id="hideinfo" title="Hide"><img src="{theme_url filename='images/icon_close.gif'}" alt="[x]" /></a>
<a id="hideinfo" title="{str tag=Hide}"><img src="{theme_url filename='images/icon_close.gif'}" alt="[x]" /></a>
{/if}
<div class="home-info">
<h3>Create and Collect</h3>
<p class="subtitle">Develop your portfolio</p>
<h3>{str tag=createcollect}</h3>
<p class="subtitle">{str tag=createcollectsubtitle}</p>
<table>
<tr>
<td>
{if $USER->is_logged_in()}<a href="/artefact/internal">{/if}
{if $USER->is_logged_in()}<a href="{$url.profile}">{/if}
<img src="{theme_url filename='images/profile.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
<td>
{if $USER->is_logged_in()}<a href="/artefact/file">{/if}
{if $USER->is_logged_in()}<a href="{$url.files}">{/if}
<img src="{theme_url filename='images/files.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
</tr>
<tr class="caption">
<td>
Update your
{if $USER->is_logged_in()}<a href="/artefact/internal">{/if}
Profile
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="updateyourprofile"|str:mahara:$url.profile}
{if $USER->is_logged_in()}{$s}{else}{strip_tags($s)}{/if}
</td>
<td>
Upload your
{if $USER->is_logged_in()}<a href="/artefact/file">{/if}
Files
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="uploadyourfiles"|str:mahara:$url.files}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</td>
</tr>
<tr>
<td>
{if $USER->is_logged_in()}<a href="/artefact/resume">{/if}
{if $USER->is_logged_in()}<a href="{$url.resume}">{/if}
<img src="{theme_url filename='images/resume.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
<td>
{if $USER->is_logged_in()}<a href="/artefact/blog">{/if}
{if $USER->is_logged_in()}<a href="{$url.blog}">{/if}
<img src="{theme_url filename='images/blog.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
</tr>
<tr class="caption">
<td>
Create your
{if $USER->is_logged_in()}<a href="/artefact/resume">{/if}
Resume
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="createyourresume"|str:mahara:$url.resume}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</td>
<td>
Publish a
{if $USER->is_logged_in()}<a href="/artefact/blog">{/if}
Blog
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="publishablog"|str:mahara:$url.blog}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</td>
</tr>
</table>
......@@ -65,57 +57,48 @@
</td>
<td>
<div class="home-info">
<h3>Organise</h3>
<p class="subtitle">Showcase your portfolio with views</p>
<h3>{str tag=Organise}</h3>
<p class="subtitle">{str tag=organisesubtitle}</p>
<div>
{if $USER->is_logged_in()}<a href="/view">{/if}
{if $USER->is_logged_in()}<a href="{$url.views}">{/if}
<img class="organise" src="{theme_url filename='images/organise.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</div>
<p class="desc">
Organise your portfolio into
{if $USER->is_logged_in()}<a href="/view">{/if}
Views.
{if $USER->is_logged_in()}</a>{/if}
Create different views for different audiences - you choose the elements to include.
{assign var=s value="organisedescription"|str:mahara:$url.views}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</p>
</div>
</td>
<td>
<div class="home-info">
<h3>Share and Network</h3>
<p class="subtitle">Meet friends and join groups</p>
<h3>{str tag=sharenetwork}</h3>
<p class="subtitle">{str tag=sharenetworksubtitle}</p>
<table>
<tr>
<td>
{if $USER->is_logged_in()}<a href="/user/find.php">{/if}
{if $USER->is_logged_in()}<a href="{$url.friends}">{/if}
<img src="{theme_url filename='images/friends.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
<td>
{if $USER->is_logged_in()}<a href="/group/find.php">{/if}
{if $USER->is_logged_in()}<a href="{$url.groups}">{/if}
<img src="{theme_url filename='images/groups.png'}" alt="" />
{if $USER->is_logged_in()}</a>{/if}
</td>
</tr>
<tr>
<td>
Find
{if $USER->is_logged_in()}<a href="/user/find.php">{/if}
Friends
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="findfriends"|str:mahara:$url.friends}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</td>
<td>
Join
{if $USER->is_logged_in()}<a href="/group/find.php">{/if}
Groups
{if $USER->is_logged_in()}</a>{/if}
{assign var=s value="joingroups"|str:mahara:$url.groups}
{if $USER->is_logged_in()}{$s}{else}{$s|strip_tags}{/if}
</td>
</tr>
</table>
<p id="accessdesc" class="desc">
You can fine-tune who has access to each view, and for how long.
</p>
<p id="accessdesc" class="desc">{str tag=sharenetworkdescription}</p>
</div>
</td>
</tr>
......
{include file="header.tpl"}
{$page_content|clean_html}
{if get_config('homepageinfo') && (!$USER->is_logged_in() || $USER->get_account_preference('showhomeinfo'))}
{include file="homeinfo.tpl"}
{include file="homeinfo.tpl" url=$url}
{/if}
{if $dashboardview}
{include file="user/dashboard.tpl"}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment