The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

When considering the user profile to display the information as the picture.

View previous topic View next topic Go down

Solved When considering the user profile to display the information as the picture.

Post by smurfavr on October 10th 2014, 4:18 pm

Now is


When considering the user profile to display the information as the picture.

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on October 10th 2014, 5:08 pm

Hell smurfavr,

You can change the profile type here :
Administration Panel > Users and groups > Profiles > General options

Tick 'no' for 'Activate advanced profile' and save.

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on October 10th 2014, 8:03 pm

Thank you Ange Tuteur.

How can I change these inscriptions profile my language?

Last visit: Today at
Private messages
Gender:
Male
Birthday Day , Month , Year
Join date
Rank:
Status
Contact user
Administrate user

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on October 10th 2014, 10:30 pm

Most of those fields should be editable here :
Administration Panel > Users and groups > Profiles > Edit

Change the texts to what you want and save :

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on October 14th 2014, 5:17 pm

These others how to change them.

Last visit: Today at
Private messages
Gender
Male, Female
Birthday Day , Month , Year
Join date
Rank:
Status
Contact user
Administrate user

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on October 30th 2014, 6:36 pm

Up

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on October 31st 2014, 9:08 pm

Hell smurfavr,

Go to administration panel > Display > Template > Profile > profile_view_body Edit

Find :
Code:
<table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>

Replace by :
Code:
<table id="profile-simple" class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>
<script type="text/javascript">_replaceReady = true;</script>

Save and publish. Add


Then go to Administration Panel > Modules > JavaScript codes management > create a new script

Title : Your choice
Placement : In all the pages
Paste the code below and submit :
Code:
_replaceReady = false, _replaceTimeout = 0, _replaceChecker = window.setInterval(function() { if (_replaceReady === true) { replaceText(); return window.clearInterval(_replaceChecker); } else if (_replaceTimeout === 1000) return window.clearInterval(_replaceChecker); _replaceTimeout += 1 },1);
function replaceText() {
 var lastvisit = 'Last visit:',
  todayat = 'Today at $1 ',
  mp = 'Private messages:',
  male = 'Male',
  female = 'Female',
  day = 'Day',
  month = 'Month',
  year = 'Year',
  rank = 'Rank:',
  status = 'Status:',
  admin = 'Administrate user:',
  contact = 'Contact1 user $1';
 $('#profile-simple').html( $('#profile-simple').html().replace(/Last visit:/,lastvisit).replace(/Today at (\d+:\d+)/,todayat).replace(/Private messages:/,mp).replace(/Male/g,male).replace(/Female/g,female).replace(/Day/,day).replace(/Month/,month).replace(/Year/,year).replace(/Rank:/,rank).replace(/Status:/,status).replace(/Administrate user:/,admin).replace(/Contact user (.*?)/,contact) );
};

There are variables with text that you can modify at the top.

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on November 2nd 2014, 7:58 am

Does not work.

profile_view_body
Code:
<table id="profile-simple" class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>
<script type="text/javascript">_replaceReady = true;</script>
<br />
<script src="{JS_DIR}jquery/json/jquery.json-1.3.min.js" type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
   $(document).ready(function(){
      $('[id^=field_id]').each(function(){
         if ( $(this).find('.field_editable').is('span, div') )
         {
            $(this).hover(function()
            {
               if( $(this).find('.field_editable.invisible').is('span, div') )
               {
                  $(this).find('.field_editable').prev().addClass('ajax-profil_hover').parent().addClass('ajax-profil_parent').append('<div class="ajax-profil_edit"><img src="{AJAX_EDIT_IMG}" /></div>');
                  $(this).find('.ajax-profil_edit').attr({
                        alt: "{L_FIELD_EDIT_VALUE}",
                        title: "{L_FIELD_EDIT_VALUE}"
                     }).click(function(){
                     $(this).prev().prev().removeClass('ajax-profil_hover').addClass('invisible').next().removeClass('invisible').append('<img src="{AJAX_VALID_IMG}" class="ajax-profil_valid" />').find('input,select');
                     $(this).prev().find('.ajax-profil_valid').attr({
                        alt: "{L_VALIDATE}",
                        title: "{L_VALIDATE}"
                     }).click(function(){
                        var content = new Array();
                        $(this).parent().find('[name]').each(function(){
                           var type_special = $(this).is('input[type=radio],input[type=checkbox]');
                           if ( (type_special && $(this).is(':checked')) || !type_special )
                           {
                              content.push(new Array($(this).attr('name'), $(this).attr('value')));
                           }
                        });
                        var id_name = $(this).parents('[id^=field_id]').attr('id');
                        var id = id_name.substring(8, id_name.length);
                        $.post(
                           "{U_AJAX_PROFILE}",
                           {id:id,user:"{CUR_USER_ID}",active:"{CUR_USER_ACTIVE}",content:$.toJSON(content),tid:"{TID}"},
                           function(data){
                              $.each(data, function(i, item){
                                 $('[id=field_id' + i + ']').find('.field_uneditable').html(item).end().find('.ajax-profil_valid').remove().end().find('.field_editable').addClass('invisible').end().find('.field_uneditable').removeClass('invisible');
                              });
                           },
                           "json"
                        );
                     });
                     $(this).remove();
                  });
               }
            },function()
            {
               if( $(this).find('.field_editable.invisible').is('span, div') )
               {
                  $(this).find('.field_editable').prev().removeClass('ajax-profil_hover');
                  $(this).find('.ajax-profil_edit').remove();
               }
            });
         }
      });
   });
//]]>
</script>



JavaScript
Code:
_replaceReady = false, _replaceTimeout = 0, _replaceChecker = window.setInterval(function() { if (_replaceReady === true) { replaceText(); return window.clearInterval(_replaceChecker); } else if (_replaceTimeout === 1000) return window.clearInterval(_replaceChecker); _replaceTimeout += 1 },1);
function replaceText() {
  var lastvisit = 'Last visit:',
      todayat = 'днес at $1 ',
      mp = 'Лични съобщения.:',
      Мъж = 'Male',
      Жена = 'Female',
      Ден = 'Day',
      Месец = 'Month',
      Година = 'Year',
      Ранг = 'Rank:',
      Статус = 'Status:',
      admin = 'Administrate user:',
      Контакт = 'Contact1 user $1';
  $('#profile-simple').html( $('#profile-simple').html().replace(/Last visit:/,lastvisit).replace(/Today at (\d+:\d+)/,todayat).replace(/Private messages:/,mp).replace(/Male/g,male).replace(/Female/g,female).replace(/Day/,day).replace(/Month/,month).replace(/Year/,year).replace(/Rank:/,rank).replace(/Status:/,status).replace(/Administrate user:/,admin).replace(/Contact user (.*?)/,contact) );
};

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on November 3rd 2014, 8:26 am

Are you using the simple profil ?

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on November 3rd 2014, 11:03 am

It is.

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on November 4th 2014, 9:41 pm

Okay try replacing the script by :
Code:
function profileText() {
 var lastvisit = 'Last visit:',
  todayat = 'днес at $1 ',
  mp = 'Лични съобщения.:',
  male = 'Мъж',
  female = 'Жена',
  day = 'Ден',
  month = 'Месец',
  year = 'Година',
  rank = 'Ранг:',
  status = 'Статус:',
  admin = 'Administrate user:',
  contact = 'Контакт user $1';
 $('#profile-simple').html( $('#profile-simple').html().replace(/Last visit:/,lastvisit).replace(/Today at (\d+:\d+)/,todayat).replace(/Private messages:/,mp).replace(/Male/g,male).replace(/Female/g,female).replace(/Day/,day).replace(/Month/,month).replace(/Year/,year).replace(/Rank:/,rank).replace(/Status:/,status).replace(/Administrate user:/,admin).replace(/Contact user (.*?)/,contact) );
};

then replace your profile_view_body template by :
Code:
<table id="profile-simple" class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>
<script type="text/javascript">_replaceReady = true;</script>
<br />
<script src="{JS_DIR}jquery/json/jquery.json-1.3.min.js" type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
  $(document).ready(function(){
  $('[id^=field_id]').each(function(){
  if ( $(this).find('.field_editable').is('span, div') )
  {
  $(this).hover(function()
  {
  if( $(this).find('.field_editable.invisible').is('span, div') )
  {
  $(this).find('.field_editable').prev().addClass('ajax-profil_hover').parent().addClass('ajax-profil_parent').append('<div class="ajax-profil_edit"><img src="{AJAX_EDIT_IMG}" /></div>');
  $(this).find('.ajax-profil_edit').attr({
  alt: "{L_FIELD_EDIT_VALUE}",
  title: "{L_FIELD_EDIT_VALUE}"
  }).click(function(){
  $(this).prev().prev().removeClass('ajax-profil_hover').addClass('invisible').next().removeClass('invisible').append('<img src="{AJAX_VALID_IMG}" class="ajax-profil_valid" />').find('input,select');
  $(this).prev().find('.ajax-profil_valid').attr({
  alt: "{L_VALIDATE}",
  title: "{L_VALIDATE}"
  }).click(function(){
  var content = new Array();
  $(this).parent().find('[name]').each(function(){
  var type_special = $(this).is('input[type=radio],input[type=checkbox]');
  if ( (type_special && $(this).is(':checked')) || !type_special )
  {
  content.push(new Array($(this).attr('name'), $(this).attr('value')));
  }
  });
  var id_name = $(this).parents('[id^=field_id]').attr('id');
  var id = id_name.substring(8, id_name.length);
  $.post(
  "{U_AJAX_PROFILE}",
  {id:id,user:"{CUR_USER_ID}",active:"{CUR_USER_ACTIVE}",content:$.toJSON(content),tid:"{TID}"},
  function(data){
  $.each(data, function(i, item){
  $('[id=field_id' + i + ']').find('.field_uneditable').html(item).end().find('.ajax-profil_valid').remove().end().find('.field_editable').addClass('invisible').end().find('.field_uneditable').removeClass('invisible');
  });
  },
  "json"
  );
  });
  $(this).remove();
  });
  }
  },function()
  {
  if( $(this).find('.field_editable.invisible').is('span, div') )
  {
  $(this).find('.field_editable').prev().removeClass('ajax-profil_hover');
  $(this).find('.ajax-profil_edit').remove();
  }
  });
  }
  });
  });
//]]>
</script>

You accidentally replaced the variable names with your translation. The texts between the 'quotes' are the replacement texts :
Code:
lastvisit = 'translation:'

I made you replace the template, because I made a small change to how the script is executed. Wink

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on November 5th 2014, 9:02 am

Does not work.

profile_view_body
Code:
<table id="profile-simple" class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>
<script type="text/javascript">_replaceReady = true;</script>
<br />
<script src="{JS_DIR}jquery/json/jquery.json-1.3.min.js" type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
  $(document).ready(function(){
      $('[id^=field_id]').each(function(){
        if ( $(this).find('.field_editable').is('span, div') )
        {
            $(this).hover(function()
            {
              if( $(this).find('.field_editable.invisible').is('span, div') )
              {
                  $(this).find('.field_editable').prev().addClass('ajax-profil_hover').parent().addClass('ajax-profil_parent').append('<div class="ajax-profil_edit"><img src="{AJAX_EDIT_IMG}" /></div>');
                  $(this).find('.ajax-profil_edit').attr({
                        alt: "{L_FIELD_EDIT_VALUE}",
                        title: "{L_FIELD_EDIT_VALUE}"
                    }).click(function(){
                    $(this).prev().prev().removeClass('ajax-profil_hover').addClass('invisible').next().removeClass('invisible').append('<img src="{AJAX_VALID_IMG}" class="ajax-profil_valid" />').find('input,select');
                    $(this).prev().find('.ajax-profil_valid').attr({
                        alt: "{L_VALIDATE}",
                        title: "{L_VALIDATE}"
                    }).click(function(){
                        var content = new Array();
                        $(this).parent().find('[name]').each(function(){
                          var type_special = $(this).is('input[type=radio],input[type=checkbox]');
                          if ( (type_special && $(this).is(':checked')) || !type_special )
                          {
                              content.push(new Array($(this).attr('name'), $(this).attr('value')));
                          }
                        });
                        var id_name = $(this).parents('[id^=field_id]').attr('id');
                        var id = id_name.substring(8, id_name.length);
                        $.post(
                          "{U_AJAX_PROFILE}",
                          {id:id,user:"{CUR_USER_ID}",active:"{CUR_USER_ACTIVE}",content:$.toJSON(content),tid:"{TID}"},
                          function(data){
                              $.each(data, function(i, item){
                                $('[id=field_id' + i + ']').find('.field_uneditable').html(item).end().find('.ajax-profil_valid').remove().end().find('.field_editable').addClass('invisible').end().find('.field_uneditable').removeClass('invisible');
                              });
                          },
                          "json"
                        );
                    });
                    $(this).remove();
                  });
              }
            },function()
            {
              if( $(this).find('.field_editable.invisible').is('span, div') )
              {
                  $(this).find('.field_editable').prev().removeClass('ajax-profil_hover');
                  $(this).find('.ajax-profil_edit').remove();
              }
            });
        }
      });
  });
//]]>
</script>

Javascript Code
Code:
function profileText() {
  var lastvisit = 'Last visit:',
      todayat = 'днес at $1 ',
      mp = 'Лични съобщения.:',
      male = 'Мъж',
      female = 'Жена',
      day = 'Ден',
      month = 'Месец',
      year = 'Година',
      rank = 'Ранг:',
      status = 'Статус:',
      admin = 'Administrate user:',
      contact = 'Контакт user $1';
  $('#profile-simple').html( $('#profile-simple').html().replace(/Last visit:/,lastvisit).replace(/Today at (\d+:\d+)/,todayat).replace(/Private messages:/,mp).replace(/Male/g,male).replace(/Female/g,female).replace(/Day/,day).replace(/Month/,month).replace(/Year/,year).replace(/Rank:/,rank).replace(/Status:/,status).replace(/Administrate user:/,admin).replace(/Contact user (.*?)/,contact) );
};

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on November 5th 2014, 9:21 pm

Ooops I'm sorry, I made a mistake in the template. Replace your view_profile_body with this :
Code:
<table id="profile-simple" class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0" align="center">
 <tr>
 <th class="thHead" colspan="2" nowrap="nowrap" height="25">{L_VIEWING_PROFILE}</th>
 </tr>
 <tr>
 <td class="catLeft" align="center" width="40%" height="28"><b><span class="gen">{L_USER_PRESENCE}</span></b></td>
 <td class="catRight" width="60%" align="center"><b><span class="gen">{L_ABOUT_USER}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="120">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td valign="middle" nowrap="nowrap" align="right" width="20%"><span class="gen">{L_AVATAR_IMG}&nbsp;</span></td>
 <td width="80%"><b><span class="gen">{AVATAR_IMG}</span></b></td>
 </tr>
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_RANK}:&nbsp;</span></td>
 <td><b><span class="gen">{POSTER_RANK}</span></b></td>
 </tr>
 <!-- BEGIN switch_show_status -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_STATUT}:&nbsp;</span></td>
 <td><b><span class="gen">{USER_ONLINE}</span></b></td>
 </tr>
 <!-- END switch_show_status -->
 <!-- BEGIN switch_allow_friendsfoes -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><span class="gen">{L_FRIENDS_AND_FOES}:&nbsp;</span></td>
 <td><span class="gen"><strong>{FRIENDSFOES}</strong></span></td>
 </tr>
 <!-- END switch_allow_friendsfoes -->
 <!-- BEGIN switch_auth_user -->
 <tr>
 <td valign="middle" nowrap="nowrap" align="right"><br /><span class="gen">{L_ADMINISTRATE_USER}:&nbsp;</span></td>
 <td><br /><strong><span class="gen">{ADMINISTRATE_USER}{BAN_USER}</span></strong></td>
 </tr>
 <!-- END switch_auth_user -->
 </table>
 </td>
 <td class="row1" rowspan="3" valign="top">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <tr>
 <td align="right" valign="top" nowrap="nowrap"><span class="gen">{L_LAST_VISITED}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{LAST_VISIT_TIME}</span></b></td>
 </tr>
 <!-- BEGIN switch_dhow_mp -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap"><span class="gen">{L_PRIVATE_MSG}:&nbsp;&nbsp;</span></td>
 <td><b><span class="gen">{PRIVATE_MSG}</span></b></td>
 </tr>
 <!-- END switch_dhow_mp -->
 <!-- BEGIN profile_field -->
 <tr id="field_id{profile_field.ID}">
 <td width="40%" align="right" valign="top" nowrap="nowrap"><span class="gen">{profile_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%"><div class="gen" style="font-weight:bold;">{profile_field.CONTENT}</div><br /><!-- BEGIN profil_type_user_posts --><span class="genmed">[{POST_PERCENT_STATS} / {POST_DAY_STATS}]</span> <br />
 <span class="genmed"><a rel="nofollow" class="genmed" href="/st/{PUSERNAME}">{L_SEARCH_USER_POSTS} :</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/sta/{PUSERNAME}">{L_TOPICS}</a><br />
 &nbsp;&nbsp;- <a rel="nofollow" class="genmed" href="/spa/{PUSERNAME}">{L_POSTS}</a></span><!-- END profil_type_user_posts --></td>
 </tr>
 <!-- END profile_field -->
 </table>
 </td>
 </tr>
 <tr>
 <td class="catLeft" align="center" height="28"><b><span class="gen">{L_CONTACT} {USERNAME}</span></b></td>
 </tr>
 <tr>
 <td class="row1" valign="top" height="{S_CONTACT_HEIGHT}">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN contact_field -->
 <tr id="field_id{contact_field.ID}">
 <td width="40%" align="right" valign="middle" nowrap="nowrap"><span class="gen">{contact_field.LABEL}&nbsp;&nbsp;</span></td>
 <td width="60%" valign="middle"><div class="gen" style="font-weight:bold;">{contact_field.CONTENT}</div></td>
 </tr>
 <!-- END contact_field -->
 <!-- BEGIN switch_admin_user_comment_active -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap" width="50%">
 <span class="gen">{L_COMMENTS} :</span><br /><span class="gensmall">{L_MODS_AND_ADMINS}</span>
 </td>
 <td class="row1" valign="middle">
 <table align="center">
 <tr>
 <td>
 {ADMIN_USER_COMMENT}
 </td>
 </tr>
 </table>
 </td>
 </tr>
 <!-- END switch_admin_user_comment_active -->
 </table>
 </td>
 </tr>
 <!-- BEGIN switch_rpg -->
 <tr>
 <td colspan="2" class="catLeft" align="center"><b><span class="gen">{L_VIEWING_RPG}</span></b></td>
 </tr>
 <tr>
 <td class="row1" align="center" valign="top" height="6">
 {RPG_IMAGE}<br /><br />
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields_left -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields_left.F_NAME} : </span>
 </td>
 <td width="100%" valign="middle" nowrap="nowrap">
 <b><span class="gen">{switch_rpg.rpg_fields_left.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields_left -->
 </table>
 </td>
 <td class="row1" align="center" valign="top" height="6">
 <table width="100%" border="0" cellspacing="1" cellpadding="0">
 <!-- BEGIN rpg_fields -->
 <tr>
 <td align="right" valign="middle" nowrap="nowrap">
 <span class="gen">{switch_rpg.rpg_fields.F_NAME} : </span>
 </td>
 <td width="100%" valign="baseline">
 <b><span class="gen">{switch_rpg.rpg_fields.F_VALUE_NEW}</span></b>
 </td>
 </tr>
 <!-- END rpg_fields -->
 </table>
 </td>
 </tr>
 <tr>
 <td colspan="2" align="center" class="row1">
 {U_ADMIN_RPG}
 </td>
 </tr>
 <!-- END switch_rpg -->
</table>
<script type="text/javascript">profileText()</script>
<br />
<script src="{JS_DIR}jquery/json/jquery.json-1.3.min.js" type="text/javascript"></script>
<script type="text/javascript">
//<![CDATA[
  $(document).ready(function(){
      $('[id^=field_id]').each(function(){
        if ( $(this).find('.field_editable').is('span, div') )
        {
            $(this).hover(function()
            {
              if( $(this).find('.field_editable.invisible').is('span, div') )
              {
                  $(this).find('.field_editable').prev().addClass('ajax-profil_hover').parent().addClass('ajax-profil_parent').append('<div class="ajax-profil_edit"><img src="{AJAX_EDIT_IMG}" /></div>');
                  $(this).find('.ajax-profil_edit').attr({
                        alt: "{L_FIELD_EDIT_VALUE}",
                        title: "{L_FIELD_EDIT_VALUE}"
                    }).click(function(){
                    $(this).prev().prev().removeClass('ajax-profil_hover').addClass('invisible').next().removeClass('invisible').append('<img src="{AJAX_VALID_IMG}" class="ajax-profil_valid" />').find('input,select');
                    $(this).prev().find('.ajax-profil_valid').attr({
                        alt: "{L_VALIDATE}",
                        title: "{L_VALIDATE}"
                    }).click(function(){
                        var content = new Array();
                        $(this).parent().find('[name]').each(function(){
                          var type_special = $(this).is('input[type=radio],input[type=checkbox]');
                          if ( (type_special && $(this).is(':checked')) || !type_special )
                          {
                              content.push(new Array($(this).attr('name'), $(this).attr('value')));
                          }
                        });
                        var id_name = $(this).parents('[id^=field_id]').attr('id');
                        var id = id_name.substring(8, id_name.length);
                        $.post(
                          "{U_AJAX_PROFILE}",
                          {id:id,user:"{CUR_USER_ID}",active:"{CUR_USER_ACTIVE}",content:$.toJSON(content),tid:"{TID}"},
                          function(data){
                              $.each(data, function(i, item){
                                $('[id=field_id' + i + ']').find('.field_uneditable').html(item).end().find('.ajax-profil_valid').remove().end().find('.field_editable').addClass('invisible').end().find('.field_uneditable').removeClass('invisible');
                              });
                          },
                          "json"
                        );
                    });
                    $(this).remove();
                  });
              }
            },function()
            {
              if( $(this).find('.field_editable.invisible').is('span, div') )
              {
                  $(this).find('.field_editable').prev().removeClass('ajax-profil_hover');
                  $(this).find('.ajax-profil_edit').remove();
              }
            });
        }
      });
  });
//]]>
</script>

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on November 5th 2014, 9:29 pm

Now only works inscription Last visit did not change.

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on November 5th 2014, 9:36 pm

Did you change the text between the quotes in this variable ?
Code:
lastvisit = 'Last visit texts:'

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by smurfavr on November 5th 2014, 11:13 pm

I've understood you, sorry. Now everything works. thank you Ange Tuteur

smurfavr
Active Poster

Male Posts : 1413
Reputation : 10
Language : Bulgarian

http://smurfa.bulgarianforum.net/

Back to top Go down

Solved Re: When considering the user profile to display the information as the picture.

Post by Ange Tuteur on November 6th 2014, 4:15 am

That's great, you're welcome. Very Happy

Topic archived

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum