Update get_lang calls using full string.

pull/3016/head
Julio Montoya 6 years ago
parent 40b6234ef9
commit 714e169289
  1. 6
      main/social/friends.php
  2. 4
      main/social/group_add.php
  3. 4
      main/social/group_edit.php
  4. 22
      main/social/group_invitation.php
  5. 18
      main/social/group_members.php
  6. 2
      main/social/group_topics.php
  7. 40
      main/social/group_view.php
  8. 16
      main/social/group_waiting_list.php
  9. 24
      main/social/groups.php
  10. 8
      main/social/home.php
  11. 22
      main/social/invitations.php
  12. 8
      main/social/message_for_group_form.inc.php
  13. 10
      main/social/my_skills_report.php
  14. 12
      main/social/myfiles.php
  15. 24
      main/social/new_promoted_message.php
  16. 66
      main/social/personal_data.php
  17. 22
      main/social/profile.php
  18. 6
      main/social/profile_friends_and_groups.inc.php
  19. 4
      main/social/promoted_messages.php
  20. 12
      main/social/require_user_linking.php
  21. 20
      main/social/search.php
  22. 8
      main/social/skills_ranking.php
  23. 6
      main/social/skills_wheel.php
  24. 2
      main/social/terms.php
  25. 2
      main/social/view_promoted_message.php

@ -66,7 +66,7 @@ function hide_icon_delete(element_html) {
</script>';
$interbreadcrumb[] = ['url' => 'profile.php', 'name' => get_lang('SocialNetwork')];
$interbreadcrumb[] = ['url' => 'profile.php', 'name' => get_lang('Social network')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Friends')];
//Block Social Menu
@ -85,12 +85,12 @@ $social_right_content = '<div class="col-md-12">';
if (count($friends) == 0) {
$social_right_content .= Display::return_message(
Display::tag('p', get_lang('NoFriendsInYourContactList')),
Display::tag('p', get_lang('No friends in your contact list')),
'warning',
false
);
$social_right_content .= Display::toolbarButton(
get_lang('TryAndFindSomeFriends'),
get_lang('Try and find some friends'),
'search.php',
'search',
'success'

@ -30,12 +30,12 @@ if ($form->validate()) {
$values['relation_type'] = GROUP_USER_PERMISSION_ADMIN;
$groupId = $usergroup->save($values);
Display::addFlash(Display::return_message(get_lang('GroupAdded')));
Display::addFlash(Display::return_message(get_lang('Group added')));
header('Location: group_view.php?id='.$groupId);
exit();
}
$nameTools = get_lang('AddGroup');
$nameTools = get_lang('Add group');
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = ['url' => 'home.php', 'name' => get_lang('Social')];

@ -17,7 +17,7 @@ if (api_get_setting('allow_social_tool') !== 'true') {
$this_section = SECTION_SOCIAL;
$group_id = isset($_GET['id']) ? intval($_GET['id']) : intval($_POST['id']);
$tool_name = get_lang('GroupEdit');
$tool_name = get_lang('Edit group');
$usergroup = new UserGroup();
$group_data = $usergroup->get($group_id);
@ -49,7 +49,7 @@ if ($form->validate()) {
$group['id'] = $group_id;
$group['group_type'] = $usergroup::SOCIAL_CLASS;
$usergroup->update($group);
Display::addFlash(Display::return_message(get_lang('GroupUpdated')));
Display::addFlash(Display::return_message(get_lang('Class updated.')));
header('Location: group_view.php?id='.$group_id);
exit();
}

@ -22,7 +22,7 @@ $tbl_user = Database::get_main_table(TABLE_MAIN_USER);
$tbl_group_rel_user = Database::get_main_table(TABLE_USERGROUP_REL_USER);
// setting the name of the tool
$tool_name = get_lang('SubscribeUsersToGroup');
$tool_name = get_lang('Subscribe users to group');
$group_id = intval($_REQUEST['id']);
$usergroup = new UserGroup();
@ -43,7 +43,7 @@ if (empty($group_id)) {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => 'group_view.php?id='.$group_id, 'name' => $group_info['name']];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('SubscribeUsersToGroup')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Subscribe users to group')];
$form_sent = 0;
$errorMsg = $firstLetterUser = $firstLetterSession = '';
@ -67,9 +67,9 @@ if (isset($_POST['form_sent']) && $_POST['form_sent']) {
[$group_id],
GROUP_USER_PERMISSION_PENDING_INVITATION
);
$title = get_lang('YouAreInvitedToGroup').' '.$group_info['name'];
$content = get_lang('YouAreInvitedToGroupContent').' '.$group_info['name'].' <br />';
$content .= get_lang('ToSubscribeClickInTheLinkBelow').' <br />';
$title = get_lang('You are invited to group').' '.$group_info['name'];
$content = get_lang('You are invited to groupContent').' '.$group_info['name'].' <br />';
$content .= get_lang('To subscribe, click the link below').' <br />';
$content .= '<a href="'.api_get_path(WEB_CODE_PATH).'social/invitations.php?accept='.$group_id.'">'.
get_lang('Subscribe').'</a>';
@ -82,7 +82,7 @@ if (isset($_POST['form_sent']) && $_POST['form_sent']) {
$content
);
}
Display::addFlash(Display::return_message(get_lang('InvitationSent')));
Display::addFlash(Display::return_message(get_lang('Invitation sent')));
}
header('Location: '.api_get_self().'?id='.$group_id);
@ -149,12 +149,12 @@ $social_right_content = '<h3 class="group-title">'.Security::remove_XSS($group_i
if (count($nosessionUsersList) == 0) {
$friends = SocialManager::get_friends(api_get_user_id());
if ($friends == 0) {
$social_right_content .= Display::return_message(get_lang('YouNeedToHaveFriendsInYourSocialNetwork'), 'warning');
$social_right_content .= Display::return_message(get_lang('You need to have friends in your social network'), 'warning');
} else {
$social_right_content .= Display::return_message(get_lang('YouAlreadyInviteAllYourContacts'), 'info');
$social_right_content .= Display::return_message(get_lang('You already invite all your contacts'), 'info');
}
$social_right_content .= '<div>';
$social_right_content .= '<a href="search.php" class="btn btn-default btn-sm">'.Display::returnFontAwesomeIcon('search').' '.get_lang('TryAndFindSomeFriends').'</a>';
$social_right_content .= '<a href="search.php" class="btn btn-default btn-sm">'.Display::returnFontAwesomeIcon('search').' '.get_lang('Try and find some friends').'</a>';
$social_right_content .= '</div>';
$social_right_content .= '<br />';
}
@ -170,7 +170,7 @@ $group_members_element = $form->addElement(
$nosessionUsersList
);
$form->addButtonSave(get_lang('InviteUsersToGroup'));
$form->addButtonSave(get_lang('Invite users to group'));
$social_right_content .= $form->returnForm();
// Current group members
@ -196,7 +196,7 @@ if (is_array($members) && count($members) > 0) {
[true, false, true, false]
);
$social_right_content .= Display::panel($userList, get_lang('UsersAlreadyInvited'));
$social_right_content .= Display::panel($userList, get_lang('Users already invited'));
}
$tpl = new Template(null);

@ -48,7 +48,7 @@ if (empty($group_id)) {
$interbreadcrumb[] = ['url' => 'home.php', 'name' => get_lang('Social')];
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => 'group_view.php?id='.$group_id, 'name' => $group_info['name']];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('MemberList')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Members list')];
//if i'm a moderator
if (isset($_GET['action']) && $_GET['action'] == 'add') {
@ -57,7 +57,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'add') {
//if i'm a moderator
if ($userGroup->isGroupModerator($group_id)) {
$userGroup->update_user_role($user_join, $group_id);
Display::addFlash(Display::return_message(get_lang('UserAdded')));
Display::addFlash(Display::return_message(get_lang('The user has been added')));
}
}
@ -67,7 +67,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'delete') {
//if i'm a moderator
if ($userGroup->isGroupModerator($group_id)) {
$userGroup->delete_user_rel_group($user_join, $group_id);
Display::addFlash(Display::return_message(get_lang('UserDeleted')));
Display::addFlash(Display::return_message(get_lang('The user has been deleted')));
}
}
@ -81,7 +81,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'set_moderator') {
$group_id,
GROUP_USER_PERMISSION_MODERATOR
);
Display::addFlash(Display::return_message(get_lang('UserChangeToModerator')));
Display::addFlash(Display::return_message(get_lang('User updated to moderator')));
}
}
@ -95,7 +95,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'delete_moderator') {
$group_id,
GROUP_USER_PERMISSION_READER
);
Display::addFlash(Display::return_message(get_lang('UserChangeToReader')));
Display::addFlash(Display::return_message(get_lang('User updated to reader')));
}
}
@ -139,12 +139,12 @@ foreach ($users as $user) {
$user['link'] = '<a href="group_members.php?id='.$group_id.'&u='.$user['id'].'&action=delete">'.
Display::return_icon(
'delete.png',
get_lang('DeleteFromGroup')
get_lang('Delete from group')
).'</a>'.
'<a href="group_members.php?id='.$group_id.'&u='.$user['id'].'&action=set_moderator">'.
Display::return_icon(
'social_moderator_add.png',
get_lang('AddModerator')
get_lang('Add as moderator')
).'</a>';
}
break;
@ -152,7 +152,7 @@ foreach ($users as $user) {
$user['link'] = '<a href="group_members.php?id='.$group_id.'&u='.$user['id'].'&action=add">'.
Display::return_icon(
'pending_invitation.png',
get_lang('PendingInvitation')
get_lang('Pending invitation')
).'</a>';
break;
case GROUP_USER_PERMISSION_MODERATOR:
@ -165,7 +165,7 @@ foreach ($users as $user) {
$user['link'] .= '<a href="group_members.php?id='.$group_id.'&u='.$user['id'].'&action=delete_moderator">'.
Display::return_icon(
'social_moderator_delete.png',
get_lang('DeleteModerator')
get_lang('Remove moderator')
).'</a>';
}
break;

@ -121,7 +121,7 @@ function remove_image_form(id_elem1) {
if (filepaths.childNodes.length < 3) {
var link_attach = document.getElementById("link-more-attach");
if (link_attach) {
link_attach.innerHTML=\'<a href="javascript://" onclick="return add_image_form()">'.get_lang('AddOneMoreFile').'</a>\';
link_attach.innerHTML=\'<a href="javascript://" onclick="return add_image_form()">'.get_lang('Add one more file').'</a>\';
}
}
}

@ -43,7 +43,7 @@ function remove_image_form(id_elem1) {
if (filepaths.childNodes.length < 3) {
var link_attach = document.getElementById("link-more-attach");
if (link_attach) {
link_attach.innerHTML=\'<a href="javascript://" class="btn btn-default" onclick="return add_image_form()">'.get_lang('AddOneMoreFile').'</a>\';
link_attach.innerHTML=\'<a href="javascript://" class="btn btn-default" onclick="return add_image_form()">'.get_lang('Add one more file').'</a>\';
}
}
}
@ -84,7 +84,7 @@ $content = null;
if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
if ($_GET['view'] == 'mygroups') {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('MyGroups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('My groups')];
} elseif ($_GET['view'] == 'newest') {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Newest')];
@ -95,7 +95,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
} else {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
if (!isset($_GET['id'])) {
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('GroupList')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Groups list')];
} else {
//$interbreadcrumb[]= array ('url' =>'#','name' => get_lang('Group'));
}
@ -121,7 +121,7 @@ if ($group_id != 0) {
if (UserGroup::canLeave($groupInfo)) {
$usergroup->delete_user_rel_group($user_leaved, $group_id);
Display::addFlash(
Display::return_message(get_lang('UserIsNotSubscribedToThisGroup'), 'confirmation', false)
Display::return_message(get_lang('User is not subscribed to this group'), 'confirmation', false)
);
}
}
@ -135,7 +135,7 @@ if ($group_id != 0) {
if ($groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
$usergroup->add_user_to_group($user_join, $group_id);
Display::addFlash(
Display::return_message(get_lang('UserIsSubscribedToThisGroup'), 'confirmation', false)
Display::return_message(get_lang('User is subscribed to this group'), 'confirmation', false)
);
} else {
$usergroup->add_user_to_group(
@ -144,7 +144,7 @@ if ($group_id != 0) {
GROUP_USER_PERMISSION_PENDING_INVITATION_SENT_BY_USER
);
Display::addFlash(
Display::return_message(get_lang('InvitationSent'), 'confirmation', false)
Display::return_message(get_lang('Invitation sent'), 'confirmation', false)
);
}
}
@ -160,7 +160,7 @@ $groupInfo['description'] = Security::remove_XSS($groupInfo['description']);
//Loading group information
if (isset($_GET['status']) && $_GET['status'] == 'sent') {
$social_right_content .= Display::return_message(get_lang('MessageHasBeenSent'), 'confirmation', false);
$social_right_content .= Display::return_message(get_lang('Your message has been sent.'), 'confirmation', false);
}
$is_group_member = $usergroup->is_group_member($group_id);
@ -168,7 +168,7 @@ $role = $usergroup->get_user_group_role(api_get_user_id(), $group_id);
if (!$is_group_member && $groupInfo['visibility'] == GROUP_PERMISSION_CLOSED) {
if ($role == GROUP_USER_PERMISSION_PENDING_INVITATION_SENT_BY_USER) {
$social_right_content .= Display::return_message(get_lang('YouAlreadySentAnInvitation'));
$social_right_content .= Display::return_message(get_lang('You already sent an invitation'));
}
}
@ -181,7 +181,7 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
$social_right_content .= '<div class="group-tool">';
$social_right_content .= '<div class="pull-right">';
$social_right_content .= '<a class="btn btn-default btn-sm" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.
get_lang('JoinGroup').'</a>';
get_lang('Join group').'</a>';
$social_right_content .= '</div>';
$social_right_content .= '</div>';
} elseif ($role == GROUP_USER_PERMISSION_PENDING_INVITATION) {
@ -189,7 +189,7 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
$social_right_content .= '<div class="pull-right">';
$social_right_content .= '<a class="btn btn-default btn-sm" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.
Display::returnFontAwesomeIcon('envelope').' '.
get_lang('YouHaveBeenInvitedJoinNow').'</a>';
get_lang('You have been invited to join now').'</a>';
}
$social_right_content .= '</div>';
$social_right_content .= '</div>';
@ -207,12 +207,12 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
]);
$create_thread_link = Display::url(
Display::returnFontAwesomeIcon('commenting').' '.
get_lang('YouShouldCreateATopic'),
get_lang('You should create a topic'),
$createThreadUrl,
[
'class' => 'ajax btn btn-primary',
'title' => get_lang('ComposeMessage'),
'data-title' => get_lang('ComposeMessage'),
'title' => get_lang('Compose message'),
'data-title' => get_lang('Compose message'),
'data-size' => 'lg',
]
);
@ -227,12 +227,12 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
]);
$create_thread_link = Display::url(
Display::returnFontAwesomeIcon('commenting').' '.
get_lang('NewTopic'),
get_lang('Create thread'),
$createThreadUrl,
[
'class' => 'ajax btn btn-default',
'title' => get_lang('ComposeMessage'),
'data-title' => get_lang('ComposeMessage'),
'title' => get_lang('Compose message'),
'data-title' => get_lang('Compose message'),
'data-size' => 'lg',
]
);
@ -254,9 +254,9 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
$member_content .= '<div class="group-tool">';
$member_content .= '<div class="pull-right">';
$member_content .= Display::url(
Display::returnFontAwesomeIcon('pencil').' '.get_lang('EditMembersList'),
Display::returnFontAwesomeIcon('pencil').' '.get_lang('Edit members list'),
'group_members.php?id='.$group_id,
['class' => 'btn btn-default btn-sm', 'title' => get_lang('EditMembersList')]
['class' => 'btn btn-default btn-sm', 'title' => get_lang('Edit members list')]
);
$member_content .= '</div>';
$member_content .= '</div>';
@ -312,9 +312,9 @@ if ($is_group_member || $groupInfo['visibility'] == GROUP_PERMISSION_OPEN) {
GROUP_USER_PERMISSION_PENDING_INVITATION,
]
)) {
$social_right_content .= '<a class="btn" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.get_lang('JoinGroup').'</a>';
$social_right_content .= '<a class="btn" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.get_lang('Join group').'</a>';
} elseif ($role == GROUP_USER_PERMISSION_PENDING_INVITATION) {
$social_right_content .= '<a class="btn" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.get_lang('YouHaveBeenInvitedJoinNow').'</a>';
$social_right_content .= '<a class="btn" href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.get_lang('You have been invited to join now').'</a>';
}
}

@ -35,7 +35,7 @@ if (empty($group_id)) {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => 'group_view.php?id='.$group_id, 'name' => $group_info['name']];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('WaitingList')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Waiting list')];
// Group information
$admins = $usergroup->get_users_by_group(
@ -53,7 +53,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'accept') {
//if i'm a moderator
if ($usergroup->isGroupModerator($group_id)) {
$usergroup->update_user_role($user_join, $group_id);
Display::addFlash(Display::return_message(get_lang('UserAdded')));
Display::addFlash(Display::return_message(get_lang('The user has been added')));
}
}
@ -63,7 +63,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'deny') {
//if i'm a moderator
if ($usergroup->isGroupModerator($group_id)) {
$usergroup->delete_user_rel_group($user_join, $group_id);
Display::addFlash(Display::return_message(get_lang('UserDeleted')));
Display::addFlash(Display::return_message(get_lang('The user has been deleted')));
}
}
@ -73,7 +73,7 @@ if (isset($_GET['action']) && $_GET['action'] == 'set_moderator') {
//if i'm the admin
if ($usergroup->is_group_admin($group_id)) {
$usergroup->update_user_role($user_moderator, $group_id, GROUP_USER_PERMISSION_MODERATOR);
Display::addFlash(Display::return_message(get_lang('UserChangeToModerator')));
Display::addFlash(Display::return_message(get_lang('User updated to moderator')));
}
}
@ -94,11 +94,11 @@ foreach ($users as $user) {
switch ($user['relation_type']) {
case GROUP_USER_PERMISSION_PENDING_INVITATION_SENT_BY_USER:
$user['link'] = '<a href="group_waiting_list.php?id='.$group_id.'&u='.$userId.'&action=accept">'.
Display::return_icon('invitation_friend.png', get_lang('AddNormalUser')).'</a>';
Display::return_icon('invitation_friend.png', get_lang('Add as simple user')).'</a>';
$user['link'] .= '<a href="group_waiting_list.php?id='.$group_id.'&u='.$userId.'&action=set_moderator">'.
Display::return_icon('social_moderator_add.png', get_lang('AddModerator')).'</a>';
Display::return_icon('social_moderator_add.png', get_lang('Add as moderator')).'</a>';
$user['link'] .= '<a href="group_waiting_list.php?id='.$group_id.'&u='.$userId.'&action=deny">'.
Display::return_icon('user_delete.png', get_lang('DenyEntry')).'</a>';
Display::return_icon('user_delete.png', get_lang('Deny access')).'</a>';
break;
}
$new_member_list[] = $user;
@ -106,7 +106,7 @@ foreach ($users as $user) {
$social_right_content = '';
if (empty($new_member_list) > 0) {
$social_right_content = Display :: return_message(get_lang('ThereAreNotUsersInTheWaitingList'));
$social_right_content = Display :: return_message(get_lang('ThereAreNotUsersInTheWaiting list'));
}
$tpl = new Template(null);

@ -23,7 +23,7 @@ $content = null;
if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
if ($_GET['view'] === 'mygroups') {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('MyGroups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('My groups')];
} elseif ($_GET['view'] === 'newest') {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Newest')];
@ -34,7 +34,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
} else {
$interbreadcrumb[] = ['url' => 'groups.php', 'name' => get_lang('Groups')];
if (!isset($_GET['id'])) {
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('GroupList')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Groups list')];
}
}
@ -174,7 +174,7 @@ foreach ($results as $result) {
// Avoiding my groups
if (!in_array($id, $my_group_list)) {
$html .= '<a class="btn btn-primary" href="group_view.php?id='.$id.'&action=join&u='.api_get_user_id().'">'.
get_lang('JoinGroup').'</a> ';
get_lang('Join group').'</a> ';
}
$html .= '<div class="group-actions" >'.$join_url.'</div>';
@ -236,7 +236,7 @@ if (is_array($results) && count($results) > 0) {
// Avoiding my groups
if (!in_array($id, $my_group_list)) {
$html .= '<a class="btn btn-primary" href="group_view.php?id='.$id.'&action=join&u='.api_get_user_id().'">'.
get_lang('JoinGroup').'</a> ';
get_lang('Join group').'</a> ';
}
$html .= '<div class="group-actions" >'.$join_url.'</div>';
@ -269,12 +269,12 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
if (api_get_setting('allow_students_to_create_groups_in_social') == 'true') {
$create_group_item =
'<a class="btn btn-default" href="'.api_get_path(WEB_PATH).'main/social/group_add.php">'.
get_lang('CreateASocialGroup').'</a>';
get_lang('Create a social group').'</a>';
} else {
if (api_is_allowed_to_edit(null, true)) {
$create_group_item =
'<a class="btn btn-default" href="'.api_get_path(WEB_PATH).'main/social/group_add.php">'.
get_lang('CreateASocialGroup').'</a>';
get_lang('Create a social group').'</a>';
}
}
break;
@ -318,17 +318,17 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
[true, true, true, false]
);
} else {
$my_group_content = '<span class="muted">'.get_lang('GroupNone').'</span>';
$my_group_content = '<span class="muted">'.get_lang('(none)').'</span>';
}
if (api_get_setting('allow_students_to_create_groups_in_social') == 'true') {
$create_group_item =
'<a class="btn btn-default" href="'.api_get_path(WEB_PATH).'main/social/group_add.php">'.
get_lang('CreateASocialGroup').'</a>';
get_lang('Create a social group').'</a>';
} else {
if (api_is_allowed_to_edit(null, true)) {
$create_group_item =
'<a class="btn btn-default" href="'.api_get_path(WEB_PATH).'main/social/group_add.php">'.
get_lang('CreateASocialGroup').'</a>';
get_lang('Create a social group').'</a>';
}
}
if (count($grid_newest_groups) > 0) {
@ -342,7 +342,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
[true, true, true, false]
);
} else {
$newest_content = '<div class="muted">'.get_lang('GroupNone').'</div>';
$newest_content = '<div class="muted">'.get_lang('(none)').'</div>';
}
if (count($grid_pop_groups) > 0) {
$popular_content = Display::return_sortable_grid(
@ -355,14 +355,14 @@ if (isset($_GET['view']) && in_array($_GET['view'], $allowed_views)) {
[true, true, true, true, true]
);
} else {
$popular_content = '<div class="muted">'.get_lang('GroupNone').'</div>';
$popular_content = '<div class="muted">'.get_lang('(none)').'</div>';
}
}
if (!empty($create_group_item)) {
$social_right_content .= Display::page_subheader($create_group_item);
}
$headers = [get_lang('Newest'), get_lang('Popular'), get_lang('MyGroups')];
$headers = [get_lang('Newest'), get_lang('Popular'), get_lang('My groups')];
$social_right_content .= Display::tabs(
$headers,
[$newest_content, $popular_content, $my_group_content],

@ -47,7 +47,7 @@ $menu = SocialManager::show_social_menu('home');
$social_search_block = Display::panel(
UserManager::get_search_form(''),
get_lang('SearchUsers')
get_lang('Search users')
);
$social_group_block = SocialManager::getGroupBlock($user_id);
@ -82,16 +82,16 @@ $formSearch->addText(
get_lang('Search'),
false,
[
'aria-label' => get_lang('SearchUsers'),
'aria-label' => get_lang('Search users'),
'custom' => true,
'placeholder' => get_lang('SearchUsersByName'),
'placeholder' => get_lang('Search usersByName'),
]
);
// Added a Jquery Function to return the Preview of OpenGraph URL Content
$htmlHeadXtra[] = SocialManager::getScriptToGetOpenGraph();
$tpl = new Template(get_lang('SocialNetwork'));
$tpl = new Template(get_lang('Social network'));
SocialManager::setSocialUserBlock($tpl, $user_id, 'home');
$tpl->assign('add_post_form', $wallSocialAddPost);
$tpl->assign('posts', $posts);

@ -17,7 +17,7 @@ if (api_get_setting('allow_social_tool') !== 'true') {
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = ['url' => 'profile.php', 'name' => get_lang('SocialNetwork')];
$interbreadcrumb[] = ['url' => 'profile.php', 'name' => get_lang('Social network')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Invitations')];
$userGroupModel = new UserGroup();
@ -38,7 +38,7 @@ if (is_array($_GET) && count($_GET) > 0) {
$userGroupModel->update_user_role(api_get_user_id(), $value, GROUP_USER_PERMISSION_READER);
Display::addFlash(
Display::return_message(get_lang('UserIsSubscribedToThisGroup'), 'success')
Display::return_message(get_lang('User is subscribed to this group'), 'success')
);
header('Location: '.api_get_path(WEB_CODE_PATH).'social/invitations.php');
@ -54,7 +54,7 @@ if (is_array($_GET) && count($_GET) > 0) {
]
)) {
Display::addFlash(
Display::return_message(get_lang('UserIsAlreadySubscribedToThisGroup'), 'warning')
Display::return_message(get_lang('User is already subscribed to this group'), 'warning')
);
header('Location: '.api_get_path(WEB_CODE_PATH).'social/invitations.php');
@ -62,7 +62,7 @@ if (is_array($_GET) && count($_GET) > 0) {
}
Display::addFlash(
Display::return_message(get_lang('UserIsNotSubscribedToThisGroup'), 'warning')
Display::return_message(get_lang('User is not subscribed to this group'), 'warning')
);
header('Location: '.api_get_path(WEB_CODE_PATH).'social/invitations.php');
@ -72,7 +72,7 @@ if (is_array($_GET) && count($_GET) > 0) {
$userGroupModel->delete_user_rel_group(api_get_user_id(), $value);
Display::addFlash(
Display::return_message(get_lang('GroupInvitationWasDeny'))
Display::return_message(get_lang('Group invitation was denied'))
);
header('Location: '.api_get_path(WEB_CODE_PATH).'social/invitations.php');
@ -103,7 +103,7 @@ if (count($_GET) <= 0) {
$socialInvitationsBlock .= '<div class="row">
<div class="col-md-12">
<a class="btn btn-success" href="search.php"><em class="fa fa-search"></em> '.
get_lang('TryAndFindSomeFriends').'
get_lang('Try and find some friends').'
</a>
</div>
</div><br />';
@ -162,7 +162,7 @@ if ($numberLoop != 0) {
$invitationHtml .= '</div>';
$invitationHtml .= '</div></div>';
}
$socialInvitationsBlock .= Display::panel($invitationHtml, get_lang('InvitationReceived'));
$socialInvitationsBlock .= Display::panel($invitationHtml, get_lang('Invitation received'));
}
if (count($list_get_invitation_sent) > 0) {
@ -188,7 +188,7 @@ if (count($list_get_invitation_sent) > 0) {
$invitationSentHtml .= '</div>';
$invitationSentHtml .= '</div></div>';
}
$socialInvitationsBlock .= Display::panel($invitationSentHtml, get_lang('InvitationSent'));
$socialInvitationsBlock .= Display::panel($invitationSentHtml, get_lang('Invitation sent'));
}
if (count($pending_invitations) > 0) {
@ -214,14 +214,14 @@ if (count($pending_invitations) > 0) {
$waitingInvitation .= '<div class="description-group">'.$invitation['description'].'</div>';
$waitingInvitation .= '<div class="btn-group" role="group">';
$waitingInvitation .= Display::toolbarButton(
get_lang('AcceptInvitation'),
get_lang('Accept invitation'),
api_get_path(WEB_CODE_PATH).'social/invitations.php?'.http_build_query(['accept' => $invitation['id']]),
'check',
'success',
['id' => 'accept-invitation-'.$invitation['id']]
);
$waitingInvitation .= Display::toolbarButton(
get_lang('DenyInvitation'),
get_lang('Deny invitation'),
api_get_path(WEB_CODE_PATH).'social/invitations.php?'.http_build_query(['deny' => $invitation['id']]),
'times',
'danger',
@ -230,7 +230,7 @@ if (count($pending_invitations) > 0) {
$waitingInvitation .= '</div>';
$waitingInvitation .= '</div></div>';
}
$socialInvitationsBlock .= Display::panel($waitingInvitation, get_lang('GroupsWaitingApproval'));
$socialInvitationsBlock .= Display::panel($waitingInvitation, get_lang('Groups waiting for approval'));
}
$tpl = new Template(null);

@ -91,10 +91,10 @@ if (api_get_setting('allow_message_tool') === 'true') {
$form->addElement(
'label',
get_lang('AttachmentFiles'),
get_lang('Attachments'),
'<div id="link-more-attach">
<a class="btn btn-default" href="javascript://" onclick="return add_image_form()">
'.get_lang('AddOneMoreFile').'
'.get_lang('Add one more file').'
</a>
</div>'
);
@ -104,11 +104,11 @@ if (api_get_setting('allow_message_tool') === 'true') {
'file',
'attach_1',
sprintf(
get_lang('MaximunFileSizeX'),
get_lang('Maximun file size: %s'),
format_file_size(api_get_setting('message_max_upload_filesize'))
)
);
$form->addButtonSend(get_lang('SendMessage'));
$form->addButtonSend(get_lang('Send message'));
$form->setDefaults(['content' => $message, 'title' => $subject]);
$tpl->assign('content', $form->returnForm());

@ -30,7 +30,7 @@ switch ($action) {
break;
case 'generate':
$certificate = Certificate::generateUserSkills(api_get_user_id());
Display::addFlash(Display::return_message(get_lang('Updated')));
Display::addFlash(Display::return_message(get_lang('Update successful')));
header('Location: '.api_get_self());
exit;
break;
@ -59,7 +59,7 @@ if ($isStudent) {
$frmStudents = new FormValidator('students', 'get');
$slcStudent = $frmStudents->addSelect(
'student',
get_lang('Student'),
get_lang('Learner'),
['0' => get_lang('Select')]
);
$frmStudents->addButtonSearch(get_lang('Search'));
@ -146,12 +146,12 @@ if ($isStudent) {
switch ($action) {
case 'filterByCourse':
$course = api_get_course_info_by_id($selectedCourse);
$reportTitle = sprintf(get_lang('AchievedSkillInCourseX'), $course['name']);
$reportTitle = sprintf(get_lang('Skills acquired in course %s'), $course['name']);
$tableRows = $objSkill->listAchievedByCourse($selectedCourse);
break;
case 'filterBySkill':
$skill = $objSkill->get($selectedSkill);
$reportTitle = sprintf(get_lang('StudentsWhoAchievedTheSkillX'), $skill['name']);
$reportTitle = sprintf(get_lang('LearnersWhoAchievedTheSkillX'), $skill['name']);
$students = UserManager::getUsersFollowedByUser(
$userId,
STUDENT,
@ -214,7 +214,7 @@ if ($isStudent) {
}
if (empty($tableRows)) {
Display::addFlash(Display::return_message(get_lang('NoResults')));
Display::addFlash(Display::return_message(get_lang('No results found')));
}
$tpl->assign('rows', $tableRows);
$templateName = $tpl->get_template($tplPath);

@ -42,7 +42,7 @@ function denied_friend (element_input) {
}
function register_friend(element_input) {
if(confirm("'.get_lang('AddToFriends').'")) {
if(confirm("'.get_lang('Are you sure you want to add this contact to your friends ?').'")) {
name_button=$(element_input).attr("id");
name_div_id="id_"+name_button.substring(13);
user_id=name_div_id.split("_");
@ -81,7 +81,7 @@ $actions = null;
if (isset($_GET['cidReq'])) {
$actions = Display::url(
Display::return_icon('back.png', get_lang('BackTo').' '.get_lang('Documents').' ('.get_lang('Course').')'),
Display::return_icon('back.png', get_lang('Back to').' '.get_lang('Documents').' ('.get_lang('Course').')'),
api_get_self().'?'.api_get_cidreq().'&id='.$_GET['parent_id']
);
}
@ -90,17 +90,17 @@ if (api_get_setting('allow_social_tool') == 'true') {
Session::write('this_section', SECTION_SOCIAL);
$interbreadcrumb[] = [
'url' => 'profile.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
} else {
Session::write('this_section', SECTION_COURSES);
$interbreadcrumb[] = [
'url' => api_get_path(WEB_PATH).'user_portal.php',
'name' => get_lang('MyCourses'),
'name' => get_lang('My courses'),
];
}
$tpl = new Template(get_lang('MyFiles'));
$tpl = new Template(get_lang('My files'));
SocialManager::setSocialUserBlock($tpl, api_get_user_id(), 'myfiles');
$editor = \Chamilo\CoreBundle\Framework\Container::getHtmlEditor();
$template = $tpl->get_template($editor->getEditorStandAloneTemplate());
@ -114,7 +114,7 @@ if (api_get_setting('allow_social_tool') == 'true') {
$social_layout = $tpl->get_template('social/myfiles.tpl');
$tpl->display($social_layout);
} else {
$controller = new IndexManager(get_lang('MyCourses'));
$controller = new IndexManager(get_lang('My courses'));
$tpl->assign(
'actions',
Display::toolbarAction('toolbar', [$actions])

@ -34,7 +34,7 @@ function add_image_form() {
filepaths.appendChild(elem1);
id_elem1 = "filepath_"+counter_image;
id_elem1 = "\'"+id_elem1+"\'";
document.getElementById("filepath_"+counter_image).innerHTML = "<div class=\"form-group\" ><label class=\"col-sm-4\">'.get_lang('FilesAttachment').'</label><input class=\"col-sm-8\" type=\"file\" name=\"attach_"+counter_image+"\" /></div><div class=\"form-group\" ><label class=\"col-sm-4\">'.get_lang('Description').'</label><div class=\"col-sm-8\"><input style=\"width:100%\" type=\"text\" name=\"legend[]\" /></div></div>";
document.getElementById("filepath_"+counter_image).innerHTML = "<div class=\"form-group\" ><label class=\"col-sm-4\">'.get_lang('Files attachments').'</label><input class=\"col-sm-8\" type=\"file\" name=\"attach_"+counter_image+"\" /></div><div class=\"form-group\" ><label class=\"col-sm-4\">'.get_lang('Description').'</label><div class=\"col-sm-8\"><input style=\"width:100%\" type=\"text\" name=\"legend[]\" /></div></div>";
if (filepaths.childNodes.length == 6) {
var link_attach = document.getElementById("link-more-attach");
if (link_attach) {
@ -43,8 +43,8 @@ function add_image_form() {
}
}
</script>';
$nameTools = get_lang('ComposeMessage');
$tpl = new Template(get_lang('ComposeMessage'));
$nameTools = get_lang('Compose message');
$tpl = new Template(get_lang('Compose message'));
/**
* Shows the compose area + a list of users to select from.
@ -70,7 +70,7 @@ function show_compose_reply_to_message($message_id, $receiver_id, $tpl)
$row = Database::fetch_array($result, 'ASSOC');
$userInfo = api_get_user_info($row['user_sender_id']);
if (empty($row['user_sender_id']) || empty($userInfo)) {
$html = get_lang('InvalidMessageId');
$html = get_lang('The id of the message to reply to is not valid.');
return $html;
}
@ -85,7 +85,7 @@ function show_compose_to_user($receiver_id, $tpl)
{
$userInfo = api_get_user_info($receiver_id);
$html = get_lang('To').':&nbsp;<strong>'.$userInfo['complete_name'].'</strong>';
$default['title'] = api_xml_http_response_encode(get_lang('EnterTitle'));
$default['title'] = api_xml_http_response_encode(get_lang('Please enter a title'));
$default['users'] = [$receiver_id];
$html .= manageForm($default, null, '', $tpl);
@ -124,7 +124,7 @@ function manageForm($default, $select_from_user_list = null, $sent_to = '', $tpl
'<div id="file_uploads"><div id="filepath_1">
<div id="filepaths" class="form-horizontal">
<div id="paths-file" class="form-group">
<label class="col-sm-4">'.get_lang('FilesAttachment').'</label>
<label class="col-sm-4">'.get_lang('Files attachments').'</label>
<input class="col-sm-8" type="file" name="attach_1"/>
</div>
</div>
@ -141,15 +141,15 @@ function manageForm($default, $select_from_user_list = null, $sent_to = '', $tpl
$form->addLabel(
'',
'<span id="link-more-attach"><a class="btn btn-default" href="javascript://" onclick="return add_image_form()">'.
get_lang('AddOneMoreFile').'</a></span>&nbsp;('.
get_lang('Add one more file').'</a></span>&nbsp;('.
sprintf(
get_lang('MaximunFileSizeX'),
get_lang('Maximun file size: %s'),
format_file_size(api_get_setting('message_max_upload_filesize'))
).')'
);
$form->addButtonSend(get_lang('SendMessage'), 'compose');
$form->setRequiredNote('<span class="form_required">*</span> <small>'.get_lang('ThisFieldIsRequired').'</small>');
$form->addButtonSend(get_lang('Send message'), 'compose');
$form->setRequiredNote('<span class="form_required">*</span> <small>'.get_lang('Required field').'</small>');
$form->setDefaults($default);
$html = '';
@ -181,7 +181,7 @@ function manageForm($default, $select_from_user_list = null, $sent_to = '', $tpl
if ($res) {
Display::addFlash(Display::return_message(
get_lang('MessageSent'),
get_lang('Message Sent'),
'confirmation',
false
));
@ -205,7 +205,7 @@ function manageForm($default, $select_from_user_list = null, $sent_to = '', $tpl
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = [
'url' => api_get_path(WEB_PATH).'main/social/home.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
$interbreadcrumb[] = [

@ -26,9 +26,9 @@ if (empty($userInfo)) {
}
$substitutionTerms = [
'password' => get_lang('EncryptedData'),
'salt' => get_lang('RandomData'),
'empty' => get_lang('NoData'),
'password' => get_lang('Encrypted data'),
'salt' => get_lang('Random data'),
'empty' => get_lang('No data available'),
];
$action = isset($_REQUEST['action']) ? $_REQUEST['action'] : '';
@ -36,21 +36,21 @@ $formToString = '';
if (api_get_setting('allow_terms_conditions') === 'true') {
$form = new FormValidator('delete_term', 'post', api_get_self().'?action=delete_legal&user_id='.$userId);
$form->addHtml(Display::return_message(get_lang('WhyYouWantToDeleteYourLegalAgreement'), 'normal', false));
$form->addTextarea('explanation', [get_lang('DeleteLegal'), get_lang('ExplanationDeleteLegal')], [], true);
$form->addHtml(Display::return_message(get_lang('You can ask below for your legal agreement to be deleted or your account to be deleted.</br>In the case of the legal agreement, once deleted you will have to accept it again on your next login to be able to access the platform and recover your access, because we cannot reasonably at the same time give you a personal environment and not treat your personal data.</br>In the case of an account deletion, your account will be deleted along with all of your course subscriptions and all the information related to your account. Please select the corresponding option with care. In both cases, one of our administrators will review your request before it is effective, to avoid any misunderstanding and definitive loss of your data.'), 'normal', false));
$form->addTextarea('explanation', [get_lang('Delete legal agreement'), get_lang('ExplanationDelete legal agreement')], [], true);
$form->addHidden('action', 'delete_legal');
$form->addButtonSave(get_lang('DeleteLegal'));
$form->addButtonSave(get_lang('Delete legal agreement'));
$formToString = $form->returnForm();
$formDelete = new FormValidator('delete_account', 'post', api_get_self().'?action=delete_account&user_id='.$userId);
$formDelete->addTextarea(
'explanation',
[get_lang('DeleteAccount'), get_lang('ExplanationDeleteAccount')],
[get_lang('Delete account'), get_lang('ExplanationDelete account')],
[],
true
);
$formDelete->addHidden('action', 'delete_account');
$formDelete->addButtonDelete(get_lang('DeleteAccount'));
$formDelete->addButtonDelete(get_lang('Delete account'));
$formToString .= $formDelete->returnForm();
}
switch ($action) {
@ -85,11 +85,11 @@ switch ($action) {
$currentUserInfo = api_get_user_info($userId);
foreach ($bossList as $bossId) {
$subjectEmail = sprintf(
get_lang('UserXSignedTheAgreement'),
get_lang('User %s signed the agreement.'),
$currentUserInfo['complete_name']
);
$contentEmail = sprintf(
get_lang('UserXSignedTheAgreementTheDateY'),
get_lang('User %s signed the agreement.TheDateY'),
$currentUserInfo['complete_name'],
api_get_local_time($time)
);
@ -102,7 +102,7 @@ switch ($action) {
);
}
}
Display::addFlash(Display::return_message(get_lang('Saved')));
Display::addFlash(Display::return_message(get_lang('Saved..')));
header('Location: '.api_get_self());
exit;
break;
@ -122,7 +122,7 @@ switch ($action) {
$explanation
);
Display::addFlash(Display::return_message(get_lang('Saved')));
Display::addFlash(Display::return_message(get_lang('Saved..')));
Event::addEvent(
LOG_USER_DELETE_ACCOUNT_REQUEST,
LOG_USER_OBJECT,
@ -131,9 +131,9 @@ switch ($action) {
$url = api_get_path(WEB_CODE_PATH).'admin/user_list_consent.php';
$link = Display::url($url, $url);
$subject = get_lang('RequestForAccountDeletion');
$subject = get_lang('Request for account removal');
$content = sprintf(
get_lang('TheUserXAskedForAccountDeletionWithJustificationXGoHereX'),
get_lang('User %s asked for the deletion of his/her account, explaining that "%s". You can process the request here: %s'),
$userInfo['complete_name'],
$explanation,
$link
@ -177,9 +177,9 @@ switch ($action) {
$url = api_get_path(WEB_CODE_PATH).'admin/user_list_consent.php';
$link = Display::url($url, $url);
$subject = get_lang('RequestForLegalConsentWithdrawal');
$subject = get_lang('Request for consent withdrawal on legal terms');
$content = sprintf(
get_lang('TheUserXAskedLegalConsentWithdrawalWithJustificationXGoHereX'),
get_lang('User %s asked for the removal of his/her consent to our legal terms, explaining that "%s". You can process the request here: %s'),
$userInfo['complete_name'],
$explanation,
$link
@ -211,14 +211,14 @@ if (!empty($_GET['export'])) {
$allowSocial = api_get_setting('allow_social_tool') === 'true';
$nameTools = get_lang('PersonalDataReport');
$nameTools = get_lang('Personal data');
$show_message = null;
if ($allowSocial) {
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = [
'url' => api_get_path(WEB_PATH).'main/social/home.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
} else {
$this_section = SECTION_MYPROFILE;
@ -228,7 +228,7 @@ if ($allowSocial) {
];
}
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('PersonalDataReport')];
$interbreadcrumb[] = ['url' => '#', 'name' => get_lang('Personal data')];
// LEFT CONTENT
$socialMenuBlock = '';
@ -255,7 +255,7 @@ foreach ($properties as $key => $value) {
$personalDataContent .= '<u>'.$categoryName.'</u> &gt;</li>';
$personalDataContent .= '<ul id="personal-data-list-'.$category.'_options" style="display:none;">';
if (empty($subValue)) {
$personalDataContent .= '<li>'.get_lang('NoData').'</li>';
$personalDataContent .= '<li>'.get_lang('No data available').'</li>';
} else {
foreach ($subValue as $subSubValue) {
$personalDataContent .= '<li>'.Security::remove_XSS($subSubValue).'</li>';
@ -267,7 +267,7 @@ foreach ($properties as $key => $value) {
case 'extraFields':
$personalDataContent .= '<li>'.$key.': </li><ul>';
if (empty($value)) {
$personalDataContent .= '<li>'.get_lang('NoData').'</li>';
$personalDataContent .= '<li>'.get_lang('No data available').'</li>';
} else {
foreach ($value as $subValue) {
if (is_array($subValue->value)) {
@ -287,7 +287,7 @@ foreach ($properties as $key => $value) {
$personalDataContent .= '<u>'.get_lang($category).'</u> &gt;</li>';
$personalDataContent .= '<ul id="personal-data-list-'.$category.'_options" style="display:none;">';
if (empty($subValue)) {
$personalDataContent .= '<li>'.get_lang('NoData').'</li>';
$personalDataContent .= '<li>'.get_lang('No data available').'</li>';
} else {
if (count($subValue) === 1000) {
$showWarningMessage = true;
@ -317,7 +317,7 @@ foreach ($properties as $key => $value) {
case 'groups':
$personalDataContent .= '<li>'.$key.': </li><ul>';
if (empty($subValue)) {
$personalDataContent .= '<li>'.get_lang('NoData').'</li>';
$personalDataContent .= '<li>'.get_lang('No data available').'</li>';
} else {
foreach ($value as $subValue) {
$personalDataContent .= '<li>'.Security::remove_XSS($subValue).'</li>';
@ -330,7 +330,7 @@ foreach ($properties as $key => $value) {
foreach ($value as $session => $courseList) {
$personalDataContent .= '<li>'.$session.'<ul>';
if (empty($courseList)) {
$personalDataContent .= '<li>'.get_lang('NoData').'</li>';
$personalDataContent .= '<li>'.get_lang('No data available').'</li>';
} else {
foreach ($courseList as $course) {
$personalDataContent .= '<li>'.$course.'</li>';
@ -355,7 +355,7 @@ foreach ($properties as $key => $value) {
/*sif (!empty($value['date'])) {
$personalDataContent .= '<li>'.$key.': '.$value['date'].'</li>';
} else {
$personalDataContent .= '<li>'.$key.': '.get_lang('ComplexDataNotShown').'</li>';
$personalDataContent .= '<li>'.$key.': '.get_lang('Complex data (not shown)').'</li>';
}*/
} else {
$personalDataContent .= '<li>'.$key.': '.Security::remove_XSS($value).'</li>';
@ -371,30 +371,30 @@ if (api_get_setting('allow_terms_conditions') === 'true') {
$userId,
'legal_accept'
);
$permissionBlock .= Display::return_icon('accept_na.png', get_lang('NotAccepted'));
$permissionBlock .= Display::return_icon('accept_na.png', get_lang('Rejected'));
if (isset($value['value']) && !empty($value['value'])) {
list($legalId, $legalLanguageId, $legalTime) = explode(':', $value['value']);
$permissionBlock = '<h4>'.get_lang('CurrentStatus').'</h4>'.
get_lang('LegalAgreementAccepted').' '.Display::return_icon('accept.png', get_lang('LegalAgreementAccepted'), [], ICON_SIZE_TINY).
$permissionBlock = '<h4>'.get_lang('Current status').'</h4>'.
get_lang('Legal agreement accepted').' '.Display::return_icon('accept.png', get_lang('Legal agreement accepted'), [], ICON_SIZE_TINY).
'<br />';
$permissionBlock .= get_lang('Date').': '.api_get_local_time($legalTime).'<br /><br />';
$permissionBlock .= $formToString;
/*$permissionBlock .= Display::url(
get_lang('DeleteLegal'),
get_lang('Delete legal agreement'),
api_get_self().'?action=delete_legal&user_id='.$userId,
['class' => 'btn btn-danger btn-xs']
);*/
} else {
// @TODO add action handling for button
$permissionBlock .= Display::url(
get_lang('SendLegal'),
get_lang('Send legal agreement'),
api_get_self().'?action=send_legal&user_id='.$userId,
['class' => 'btn btn-primary btn-xs']
);
}
} else {
$permissionBlock .= get_lang('NoTermsAndConditionsAvailable');
$permissionBlock .= get_lang('No terms and conditions available');
}
//Build the final array to pass to template
@ -439,11 +439,11 @@ $tpl->assign('actions', Display::toolbarAction('toolbar', [$actions]));
$termLink = '';
if (api_get_setting('allow_terms_conditions') === 'true') {
$url = api_get_path(WEB_CODE_PATH).'social/terms.php';
$termLink = Display::url(get_lang('ReadTermsAndConditions'), $url);
$termLink = Display::url(get_lang('Read the Terms and Conditions'), $url);
}
if ($showWarningMessage) {
Display::addFlash(Display::return_message(get_lang('MoreDataAvailableInTheDatabaseButTrunkedForEfficiencyReasons')));
Display::addFlash(Display::return_message(get_lang('More data available in the database but trunked for efficiency reasons.')));
}
// Block Social Avatar

@ -92,7 +92,7 @@ if (isset($_GET['shared'])) {
}
$interbreadcrumb[] = [
'url' => 'home.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
if (isset($_GET['u']) && is_numeric($_GET['u']) && $_GET['u'] != api_get_user_id()) {
@ -175,7 +175,7 @@ if ($show_full_profile) {
$user_feeds = SocialManager::getUserRssFeed($user_id);
if (!empty($user_feeds)) {
$social_rss_block = Display::panel($user_feeds, get_lang('RSSFeeds'));
$social_rss_block = Display::panel($user_feeds, get_lang('RSS feed'));
}
// Productions
@ -220,7 +220,7 @@ if ($show_full_profile) {
$invitations .= '<div class="pull-right">';
$invitations .= Display::toolbarButton(
get_lang('SocialAddToFriends'),
get_lang('Add to my contacts'),
api_get_path(WEB_AJAX_PATH).'social.ajax.php?'.http_build_query([
'a' => 'add_friend',
'friend_id' => $user_invitation_id,
@ -237,7 +237,7 @@ if ($show_full_profile) {
}
$invitations .= '</ul>';
$listInvitations = Display::panelCollapse(
get_lang('PendingInvitations'),
get_lang('Pending invitations'),
$invitations,
'invitations',
null,
@ -251,7 +251,7 @@ if ($show_full_profile) {
$production_list = UserManager::build_production_list($user_id);
$product_content = '';
if (!empty($production_list)) {
$product_content .= '<div><h3>'.get_lang('MyProductions').'</h3></div>';
$product_content .= '<div><h3>'.get_lang('My productions').'</h3></div>';
$product_content .= $production_list;
$socialRightInformation .= SocialManager::social_wrapper_div($product_content, 4);
}
@ -259,7 +259,7 @@ if ($show_full_profile) {
$images_uploaded = null;
// Images uploaded by course
/*if (!empty($file_list)) {
$images_uploaded .= '<div><h3>'.get_lang('ImagesUploaded').'</h3></div>';
$images_uploaded .= '<div><h3>'.get_lang('Uploaded images').'</h3></div>';
$images_uploaded .= '<div class="social-content-information">';
$images_uploaded .= $file_list;
$images_uploaded .= '</div>';
@ -269,25 +269,25 @@ if ($show_full_profile) {
if (!empty($user_info['competences']) || !empty($user_info['diplomas'])
|| !empty($user_info['openarea']) || !empty($user_info['teach'])) {
$more_info .= '<div><h3>'.get_lang('MoreInformation').'</h3></div>';
$more_info .= '<div><h3>'.get_lang('More information').'</h3></div>';
if (!empty($user_info['competences'])) {
$more_info .= '<br />';
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('MyCompetences').'</strong></div>';
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('My competences').'</strong></div>';
$more_info .= '<div class="social-profile-extended">'.$user_info['competences'].'</div>';
$more_info .= '<br />';
}
if (!empty($user_info['diplomas'])) {
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('MyDiplomas').'</strong></div>';
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('My diplomas').'</strong></div>';
$more_info .= '<div class="social-profile-extended">'.$user_info['diplomas'].'</div>';
$more_info .= '<br />';
}
if (!empty($user_info['openarea'])) {
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('MyPersonalOpenArea').'</strong></div>';
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('My personal open area').'</strong></div>';
$more_info .= '<div class="social-profile-extended">'.$user_info['openarea'].'</div>';
$more_info .= '<br />';
}
if (!empty($user_info['teach'])) {
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('MyTeach').'</strong></div>';
$more_info .= '<div class="social-actions-message"><strong>'.get_lang('What I am able to teach').'</strong></div>';
$more_info .= '<div class="social-profile-extended">'.$user_info['teach'].'</div>';
$more_info .= '<br />';
}

@ -32,7 +32,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $views)) {
);
$number_friends = count($friends);
$friend_html = '';
$friend_html .= '<div><h3>'.get_lang('SocialFriend').'</h3></div>';
$friend_html .= '<div><h3>'.get_lang('My friends').'</h3></div>';
$friend_html .= '<div id="friend-container" class="social-friend-container">';
$friend_html .= '<div id="friend-header" >';
@ -115,7 +115,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $views)) {
$item_actions = '';
if (api_get_user_id() == $user_id) {
$item_actions = '<div class="box_shared_profile_group_actions"><a href="group_view.php?id='.$id.'">'.
get_lang('SeeMore').$url_close.'</div>';
get_lang('See more').$url_close.'</div>';
}
$grid_my_groups[] = [
$item_name,
@ -128,7 +128,7 @@ if (isset($_GET['view']) && in_array($_GET['view'], $views)) {
if (count($grid_my_groups) > 0) {
echo '<div style="margin-top:20px">';
echo '<div><h3>'.get_lang('MyGroups').'</h3></div>';
echo '<div><h3>'.get_lang('My groups').'</h3></div>';
$count_groups = 0;
if (count($results) == 1) {
$count_groups = count($results).' '.get_lang('Group');

@ -20,7 +20,7 @@ Event::registerLog($logInfo);
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = [
'url' => api_get_path(WEB_CODE_PATH).'social/home.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
$interbreadcrumb[] = [
@ -34,7 +34,7 @@ $menu = SocialManager::show_social_menu('messages');
$social_right_content = '';
$keyword = '';
$actionsLeft = '<a href="'.api_get_path(WEB_CODE_PATH).'social/new_promoted_message.php">'.
Display::return_icon('new-message.png', get_lang('ComposeMessage'), [], 32).'</a>';
Display::return_icon('new-message.png', get_lang('Compose message'), [], 32).'</a>';
$form = MessageManager::getSearchForm(api_get_self());
if ($form->validate()) {

@ -41,17 +41,17 @@ foreach ($usersRequested as $userRequested) {
}
$form = new FormValidator('require_user_linking');
$form->addUserAvatar('hrm', get_lang('DRH'), 'medium');
$form->addUserAvatar('hrm', get_lang('Human Resources Manager'), 'medium');
$form->addSelectAjax(
'users',
[get_lang('LinkMeToStudent'), get_lang('LinkMeToStudentComment')],
[get_lang('Link me to student'), get_lang('Link me to studentComment')],
$requestOptions,
[
'multiple' => 'multiple',
'url' => api_get_path(WEB_AJAX_PATH).'user_manager.ajax.php?a=get_user_like',
]
);
$form->addButtonSave(get_lang('RequestLinkToStudent'));
$form->addButtonSave(get_lang('Request linking with student'));
$form->setDefaults([
'hrm' => $hrm,
'users' => array_keys($requestOptions),
@ -68,7 +68,7 @@ if ($form->validate()) {
UserManager::requestUsersToHRManager($hrm->getId(), $usersId, false);
Display::addFlash(
Display::return_message(get_lang('LinkingRequestsAdded'), 'success')
Display::return_message(get_lang('Linking request added'), 'success')
);
header('Location: '.api_get_self());
@ -79,7 +79,7 @@ $usersAssigned = UserManager::get_users_followed_by_drh($hrm->getId());
$content = $form->returnForm();
$content .= Display::page_subheader(get_lang('AssignedUsersListToHumanResourcesManager'));
$content .= Display::page_subheader(get_lang('List of users assigned to Human Resources manager'));
$content .= '<div class="row">';
foreach ($usersAssigned as $userAssigned) {
@ -108,7 +108,7 @@ foreach ($usersAssigned as $userAssigned) {
$content .= '</div>';
$toolName = get_lang('RequestLinkingToUser');
$toolName = get_lang('Request linking to student');
$view = new Template($toolName);
$view->assign('header', $toolName);

@ -20,7 +20,7 @@ $this_section = SECTION_SOCIAL;
$tool_name = get_lang('Search');
$interbreadcrumb[] = [
'url' => api_get_path(WEB_CODE_PATH).'social/profile.php',
'name' => get_lang('SocialNetwork'),
'name' => get_lang('Social network'),
];
$query = isset($_GET['q']) ? Security::remove_XSS($_GET['q']) : null;
@ -78,7 +78,7 @@ if ($query != '' || ($query_vars['search_type'] == '1' && count($query_vars) > 2
}
if (empty($users) && empty($groups)) {
Display::addFlash(Display::return_message(get_lang('SorryNoResults')));
Display::addFlash(Display::return_message(get_lang('Sorry no results')));
}
$results = '<div id="whoisonline">';
@ -88,14 +88,14 @@ if ($query != '' || ($query_vars['search_type'] == '1' && count($query_vars) > 2
foreach ($users as $user) {
$user_info = api_get_user_info($user['id'], true);
$sendInvitation = '<button class="'.$buttonClass.' disabled ">
<em class="fa fa-user"></em> '.get_lang('SendInvitation').'</button>';
<em class="fa fa-user"></em> '.get_lang('Send invitation').'</button>';
$relation_type = SocialManager::get_relation_between_contacts(api_get_user_id(), $user_info['user_id']);
$url = api_get_path(WEB_PATH).'main/social/profile.php?u='.$user_info['user_id'];
// Show send invitation icon if they are not friends yet
if ($relation_type != 3 && $relation_type != 4 && $user_info['user_id'] != api_get_user_id()) {
$sendInvitation = '<a href="#" class="'.$buttonClass.' btn-to-send-invitation" data-send-to="'.$user_info['user_id'].'">
<em class="fa fa-user"></em> '.get_lang('SendInvitation').'</a>';
<em class="fa fa-user"></em> '.get_lang('Send invitation').'</a>';
}
$sendMessageUrl = api_get_path(WEB_AJAX_PATH).'user_manager.ajax.php?'.http_build_query([
@ -104,26 +104,26 @@ if ($query != '' || ($query_vars['search_type'] == '1' && count($query_vars) > 2
]);
$sendMessage = Display::toolbarButton(
get_lang('SendMessage'),
get_lang('Send message'),
$sendMessageUrl,
'envelope',
'default',
[
'class' => 'ajax btn-sm',
'data-title' => get_lang('SendMessage'),
'data-title' => get_lang('Send message'),
]
);
if (!empty($user_info['user_is_online'])) {
$status_icon = Display::return_icon('online.png', get_lang('OnLine'), null, ICON_SIZE_TINY);
$status_icon = Display::return_icon('online.png', get_lang('Online'), null, ICON_SIZE_TINY);
} else {
$status_icon = Display::return_icon('offline.png', get_lang('Disconnected'), null, ICON_SIZE_TINY);
}
if ($user_info['status'] == 5) {
$user_icon = Display::return_icon('user.png', get_lang('Student'), null, ICON_SIZE_TINY);
$user_icon = Display::return_icon('user.png', get_lang('Learner'), null, ICON_SIZE_TINY);
} else {
$user_icon = Display::return_icon('teacher.png', get_lang('Teacher'), null, ICON_SIZE_TINY);
$user_icon = Display::return_icon('teacher.png', get_lang('Trainer'), null, ICON_SIZE_TINY);
}
$user_info['complete_name'] = Display::url($user_info['complete_name'], $url);
@ -204,7 +204,7 @@ if ($query != '' || ($query_vars['search_type'] == '1' && count($query_vars) > 2
<p>'.$members.'</p>
<p>'.$group['description'].'</p>
<p>'.$tags.'</p>
<p>'.$url_open.get_lang('SeeMore').$url_close.'</p>
<p>'.$url_open.get_lang('See more').$url_close.'</p>
</div>
</div>
</div>';

@ -23,10 +23,10 @@ $url = api_get_path(WEB_AJAX_PATH).'model.ajax.php?a=get_user_skill_ranking';
//The order is important you need to check the the $column variable in the model.ajax.php file
$columns = [
get_lang('Photo'),
get_lang('FirstName'),
get_lang('LastName'),
get_lang('SkillsAcquired'),
get_lang('CurrentlyLearning'),
get_lang('First name'),
get_lang('Last name'),
get_lang('Skills acquired'),
get_lang('Currently learning'),
get_lang('Rank'),
];

@ -35,7 +35,7 @@ $dialogForm->addLabel(
Display::tag('p', null, ['id' => 'name', 'class' => 'form-control-static'])
);
$dialogForm->addLabel(
get_lang('ShortCode'),
get_lang('Short code'),
Display::tag('p', null, ['id' => 'short_code', 'class' => 'form-control-static'])
);
$dialogForm->addLabel(
@ -44,8 +44,8 @@ $dialogForm->addLabel(
);
$dialogForm->addLabel(
[
get_lang('Gradebook'),
get_lang('WithCertificate'),
get_lang('Assessments'),
get_lang('With Certificate'),
],
Display::tag(
'ul',

@ -30,7 +30,7 @@ foreach ($values as $value) {
}
}
$term['date_text'] = get_lang('PublicationDate').': '.
$term['date_text'] = get_lang('Publication date').': '.
api_get_local_time(
$term['date'],
null,

@ -10,7 +10,7 @@ if (api_get_setting('allow_social_tool') != 'true') {
}
$this_section = SECTION_SOCIAL;
$interbreadcrumb[] = ['url' => api_get_path(WEB_PATH).'main/social/home.php', 'name' => get_lang('SocialNetwork')];
$interbreadcrumb[] = ['url' => api_get_path(WEB_PATH).'main/social/home.php', 'name' => get_lang('Social network')];
$interbreadcrumb[] = ['url' => 'promoted_messages.php', 'name' => get_lang('PromotedMessages')];
$social_right_content = '';

Loading…
Cancel
Save