Boas-vindas ao Power Pixel

Junte-se a comunidade! Crie o seu próprio conteúdo, e faça amizades.EntrarCriar uma conta

Perfil IPB

3 participantes

S4BR1N4 S4BR1N4  • Dom 4 maio 2014 - 23:53

Perfil IPB  Empty Perfil IPB Dom 4 maio 2014 - 23:53

Minha questão:
Olá, eu estou querendo uma ajudinha...

Eu segui o tutorial do [Dark]Doki- a respeito do perfil IPB que por sinal ficou ótimo.

[Tens de ter uma conta e sessão iniciada para poderes visualizar este link]

aparentemente ele ficou muito bom porém tem umas partes que não funcionam não sei se porque já estava assim ou se é meu forum por exemplo:

[Tens de ter uma conta e sessão iniciada para poderes visualizar esta imagem]

Ali na parte da reputação ela nunca muda só fica neutro os numeros mudam normal mas não muda o neutro.

e ali nos amigos não aparecem os amigos gostaria de saber se é algum problema no codigo que está junto com o perfil que está logo a baixo, poderia verificar? Desde já eu agradeço muito.

Código:
//<![CDATA[
/* Plugin to Add Hover Class! */
(function($){
$.fn.hoverClass = function(c) {
return this.hover(
function() { $(this).toggleClass(c); }
);
};
}(jQuery));
/*$('[id^=field_id]').hoverClass('hover');*/
function editableField(){
$('#user_status_cell #uneditable').hide();
$('#user_status_cell #editable').show();
};
/* ---- Variables definitions 1---- */
/*find username and state*/
var UserName = $('#profile_content').find('span.fn.nickname').text();
<!-- BEGIN switch_show_status -->
var UserStats = $.trim('{USER_ONLINE}');
<!-- END switch_show_status -->
var pUserName = encodeURI(UserName); /*encodeURI('{PUSERNAME}');*/ /*to avoid espace in url names!*/
var sStarIMG = 'http://i69.servimg.com/u/f69/18/17/62/92/star10.png';
var UserNum = {CUR_USER_ID}; /*location.href.split('/u')[1];*/ /*ID number of user*/
var Logged_As = $('#pun-visit strong').text();
/*related to reputations - Place the numbers and labels reputation of your forum*/
var iReputation_1 = 0;
var iReputation_2 = 10;
var iReputation_3 = 20;
var iReputation_4 = 100;
var iReputation_5 = 200;
var lReputation_1 = 'Neutro';
var lReputation_2 = 'Regular';
var lReputation_3 = 'Bom';
var lReputation_4 = 'Ótimo';
var lReputation_5 = 'Excelente';
/*related to tabs*/
var tabTopicsLoaded = 0;
var tabPostsLoaded = 0;
var tabShoutsLoaded = 0;
var activeTab = '';
/*----------------------------------*/
/*sets default user image*/
var $Sel = $('#profile_tabs').find('p.short.photo_holder');
if($.trim($Sel.find('img').attr('src')) =='') {
$Sel.append('<img alt="- foto" src="http://2img.net/i/fa/invision/pp-blank-thumb.png" id="profile_photo" class="ipsUserPhoto">');
$('#photo_popup_inner #ips_currentPhoto').append('<img alt="- foto" src="http://2img.net/i/fa/invision/pp-blank-thumb.png" id="profile_photo" class="ipsUserPhoto">');
} else {
$Sel.find('img').attr('id','profile_photo').addClass('ipsUserPhoto');
}
/*sets joined in*/
$('#user_info_cell').find('span.joined_in').html($('#field_id-4').find('div.field_uneditable').text()); /*id-4 => "Data de inscrição"*/
/*sets state*/
if(UserStats == 'conectado') {
$('#user_info_cell #user_connected').html('online').addClass('ipsBadge_green').removeClass('ipsBadge_lightgrey');
} else {
$('#user_info_cell #user_connected').html('offline').addClass('ipsBadge_lightgrey').removeClass('ipsBadge_green');
};
/*sets profile fields*/
$('.ipsList_data [id^=field_id]:contains("_Log")').hide();   
$('#field_id-6').hide();
$('#field_id-14').hide();
$('#field_id-4').hide();
/* sets posts */
var posts = $('#field_id-6').find('div.field_uneditable').text();
$('#amount_posts').text(posts);
/* field_id1 (Título) = First field added to the perfil! */
var $Len = $('#field_id1');
if($Len.length) {
var $Sel = $Len.find('div.field_uneditable');
if($.trim($Sel.text()) == '-') {
$Sel.addClass('desc lighter').text('Sem informações');
}
}   
/*sets gender*/
var $Len = $('#field_id-7');
if($Len.length) {
$Len.find('span.row_title').html('<span style="color:##66666;">Gênero:</span>');
var $Sel = $Len.find('div.field_uneditable');
if($.trim($Sel.text()) == '-') {
$Sel.html('<img alt="Não informado" src="http://i69.servimg.com/u/f69/18/17/62/92/myster10.png"> Não informado');
} else {
var UserGender = $Sel.find('img').attr('src').split('_')[2];
switch (UserGender)
{
case 'male.gif':
$Sel.html('<img alt="Masculino" src="http://i69.servimg.com/u/f69/18/17/62/92/male10.png"> Masculino');
break;
case 'female.gif':
$Sel.html('<img alt="Feminino" src="http://i69.servimg.com/u/f69/18/17/62/92/female10.png"> Feminino');
break;
default:
$Sel.html('<img alt="Não informado" src="http://i69.servimg.com/u/f69/18/17/62/92/myster10.png"> Não informado');
}
}
}
/*sets Job/hobbies*/
var $Len = $('#field_id-9');
if($Len.length) {
var $Sel = $Len.find('div.field_uneditable');
if($.trim($Sel.text()) == '-') {
$Sel.addClass('desc lighter').text('Sem informações');
}
}
/*sets localization*/
var $Len = $('#field_id-11');
if($Len.length) {
var $Sel = $Len.find('div.field_uneditable');
if($.trim($Sel.text()) == '-') {
$Sel.addClass('desc lighter').text('Sem informações');
}
}
/*sets born*/
var $Len = $('#field_id-12');
if($Len.length) {
$Len.find('span.row_title').find('span').text('Nascimento');
var $Sel = $Len.find('div.field_uneditable');
if($.trim($Sel.text()) == '-') {
$Sel.addClass('desc lighter').text('Sem informações');
}
}
/*sets user comments*/
var $Len = $('#field_id-20');
if($Len.length) {
$Len.hide();
var $Sel = $Len.find('div.field_uneditable');  /*id-20 => "Comentários"*/
if($.trim($Sel.text()) != '-') {
$('#user_status_cell .user_comments').html($Sel);
$('#user_status_cell').css('display', '');
}
}
/*sets [Quem sou eu] field*/
var $Len = $('#field_id-8');
if($Len.length) {
$Len.hide();
var $Sel = $Len.find('div.field_uneditable'); /*id-8 => "Humor"*/
if($.trim($Sel.text()) != '-') {
$('#user_humor_id').find('.user_humor').html($Sel);
$('#user_humor_id').css('display', '');
}
}
/*sets reputation fields*/   
var Reputation = $('#field_id-14').find('div.field_uneditable').text();
var $Sel = $('#reputation_panel').find('span.title');
$Sel.text(lReputation_1);
$('#reputation_panel').find('span.number').text(Reputation);
$('#reputation_panel').removeClass('zero').addClass('positive');
switch (Reputation)
{
case (Reputation = iReputation_1):
$('#reputation_panel').removeClass('positive').addClass('zero');
break;
case (Reputation > iReputation_1 && Reputation < iReputation_2):
$('#user_rate_1').find('img').attr('src', sStarIMG);
break;
case (Reputation >= iReputation_2 && Reputation < iReputation_3):
$Sel.text(lReputation_2);
$('#user_rate_2').find('img').attr('src', sStarIMG);
break;
case (Reputation >= iReputation_3 && Reputation < iReputation_4):
$Sel.text(lReputation_3);
$('#user_rate_3').find('img').attr('src', sStarIMG);
break;
case (Reputation >= iReputation_4 && Reputation < iReputation_5):
$Sel.text(lReputation_4);
$('#user_rate_4').find('img').attr('src', sStarIMG);
break;
case (Reputation >= iReputation_5):
$Sel.text(lReputation_5);
$('#user_rate_5').find('img').attr('src', sStarIMG);
break;
}
/*sets friends information*/
/*                                      This load and read all friends fields ¯| */
/*$('#friends_foes').load(location.href + ' #profile-advanced-right .module.main:last .main-content.clearfix', function() {
});*/
<!-- BEGIN switch_user_logged_in -->
/* Atualizações Recentes de Status */
/*                                              This load and read all form fields ¯| */
$('.tab_link_pane #pane_members_status .status_update').load('/privmsg?mode=post_profile&u=' + UserNum + ' .main .frm-form', function() {
$('.status_update .frm-form .main-head.clearfix').remove();
$('.status_update .frm-form .main').hide();
$('.status_update .frm-form .main-content.frm').css('padding', '0px');
$('.status_update .frm-form .main-content.frm .frm-set')
.css({ 'border-bottom' : '0', 'background' : 'none repeat scroll 0 0 #71A5C9', 'height' : '0px', 'margin' : '0px', 'padding' : '0px' });
$('.status_update .frm-form .frm-set.multi #text_editor_select_controls').hide();
$('.status_update .frm-form .frm-set.multi #text_editor_controls').hide();
$('.status_update .frm-form .main-content.frm .frm-set > dl').hide();
$('.status_update .frm-form .frm-set.multi .left').remove();
$('.status_update .frm-form .frm-set.multi textarea_content').css('width', '100%');
$('.status_update .frm-form .frm-set.multi #textarea_content dt').remove(); /*.posting-block*/
$('.status_update .frm-form .frm-set.multi #smiley-box').hide(); /*or remove()*/
$('.status_update .frm-form .frm-set').css('padding', '0');
/*.posting-block*/
$('.status_update .frm-form .frm-set.multi #textarea_content .frm-textarea')
.css({ 'padding' : '0', 'border-top-width' : '0', 'float' : 'left', 'width' : '100%', 'height' : '31px', 'margin-left' : '5px', 'margin-top' : '0' })
.append('<input type="submit" accesskey="s" tabindex="6" value="Comentar" name="post" class="ipsButton" style="float:right; position:relative; top: -30px; right: -43px;">')
.append('<input type="checkbox" name="attach_sig" style="display:none;">'); /*Do not add signature*/
$('.status_update .frm-textarea #text_editor_textarea').css({ 'width' : '675px', 'height' : '16px', 'padding' : '6px 4px' }).attr('placeholder', 'Deixar uma mensagem...');
$('.status_update .frm-form .frm-set .frm-buttons input[name=preview]').remove();
$('.status_update .frm-form .frm-set .frm-buttons input[name=post]').remove();
$('.status_update .frm-form .frm-set .frm-buttons input[name=username]').val(Logged_As); /*sets user name to send message!*/
$('.status_update .frm-form .frm-set.multi input[name=subject]').val('Mensagem'); /*sets title to send message!*/
$('.status_update .frm-form .frm-set .frm-buttons').removeClass('frm-buttons').addClass('post_comment');
$('.status_update .frm-form .frm-set .post_comment').css('height', '0px');
$('.status_update .frm-form').attr('target','iPerfmsg');
$('.status_update .frm-form').submit(function(){var time=setTimeout("fperfMsgSent()",1000);});
if(UserName == Logged_As) {
$('.status_update .frm-form .frm-set.multi input[name=subject]').val('O que há em minha mente:'); /*sets title to send message!*/
$('.status_update .frm-form .frm-set.multi #textarea_content .frm-textarea input[name=post]').val('Atualizar');
$('.status_update .frm-textarea #text_editor_textarea').attr('placeholder', 'O que há em sua mente?');
}
readPerfilMessages();
});
function fperfMsgSent(){
if(UserName !== Logged_As) {
alert('A sua mensagem foi enviada!');
}
$('.status_update .frm-textarea #text_editor_textarea').val('');
readPerfilMessages();
}
/*                                      This load and read all messages fields ¯| */
function readPerfilMessages() {
$('.tab_link_pane .ipsBox.clearfix #status_wrapper').load(location.href + 'wall #profile-advanced-details', function() {
$('#status_wrapper .main-head').remove();
$('#status_wrapper .main-content.clearfix .pagination.top:first').remove();
$('#status_wrapper .new-message.bottom').remove();
});
}
<!-- END switch_user_logged_in -->
<!-- BEGIN switch_user_logged_in -->
/* ---- Variables definitions 2---- */
var UserFriends = $('#friends_foes > a:first').text();
var UserFoes = $('#friends_foes > a:last').text();
/*----------------------------------*/
/*sets user utility [Buttons] and [Links]*/
if(UserName == Logged_As) {
$('.topic_buttons li.editPerfil').css('display', '');
$('#change_photo').css('display', '');
} else {
var $Sel = $('#admin_user');
if($Sel.length) {
$('.topic_buttons li.editMember').css('display', '');
$('.topic_buttons li.editMember').find('a').attr('href', $Sel.find('a').attr('href'));
}
var $Sel = $('#ban_user');
if($Sel.length) {
var $href = $Sel.find('a');
if($href.length) {
$('.topic_buttons li.FlagSpam').css('display', '');
/*$('.topic_buttons li.FlagSpam').find('a').attr('href', $href.attr('href'));*/
} else {
var Texto = $Sel.text();
/*alert(Texto);*/
}     
}
if(UserFriends !=='') {
$('#add_friend').css('display', '');
} else {
$('#remove_friend').css('display', '');
}
$('#pm_button').css('display', '').find('a').attr('href', '/privmsg?mode=post&u=' + UserNum);
}
<!-- END switch_user_logged_in -->
$('#ban_member_popup #confirm_ban').submit(function(){
var time=setTimeout("winReload('O membro '+UserName+' foi alertado com sucesso!')",1000);
});
function winReload(msg){
if(msg.length){
alert(msg);
}
window.location.reload()
}
function Question() {
if (confirm("Tem certeza que deseja continuar?")==true) {
x="You pressed OK!";
} else {
x="You pressed Cancel!";
}
document.getElementById("demo").innerHTML=x;
}
/*
function show_popup(id) {
var $oObj = $('#'+id);
if ($oObj.css('display') == 'none') {
$oObj.add('#document_modal').fadeIn('slow');
$("input:text:eq(0):visible").focus();
} else {
$oObj.add('#document_modal').fadeOut('slow');
}     
}
*/
function show_popup( element, focus ) {
if ( element == '' ) {return false;}
var $oObj = $('#' + element);
var oldIndex = 0;
/* Add an "document_modal" to the code...*/
$oObj.before('<div id="popup_modal" class="modal" style="display:none; width: 100%; height: 100%; position: fixed; top: 0px; left: 0px; z-index: 10000; opacity: 0.4; background-color: #3E3E3E;"></div>');
/* Save original z-index order and sets new...*/
oldIndex = $oObj.css('z-index');
$oObj.css('z-index', '10001');
if ($oObj.css('display') == 'none') {
$oObj.add('#popup_modal').fadeIn('slow');
if ( focus != '' ) {$(focus).focus();}
} else {
$oObj.add('#popup_modal').fadeOut('slow');
/* restore original z-index */
$oObj.css('z-index', oldIndex);
/* Remove "document_modal"! */
$oObj.parent().remove('#popup_modal');
}     
}
$(document).ready(function(){
$('#iframe_photo_popup').load(function(){
var iframe = $('#iframe_photo_popup').contents().find('div .main-content.frm');
if(iframe.length > 0) {
var PhotoPopup = iframe.html();
$('#photo_popup_inner').find('div.iframe_photo_popup').html(PhotoPopup);
$('.frm-info').css('display', 'none');
$('.frm-set').css('margin', '0');
$('.frm-set dt').css({ 'font-weight' : '400', 'float' : 'left', 'text-align' : 'left', 'width' : 'auto' });
$('.frm-set dd').css({ 'margin-left' : '5px', 'float' : 'left' });
$('.frm-set > dl:last-child').css('display', 'none');
$('.inputbox').css('width', '80% !important');
$('.frm-buttons').css({ 'display' : '', 'margin-bottom' : '0px' });
$('.button2').removeClass('button2').addClass('ipsButton ips_photoSubmi');
$('.ipsButton.ips_photoSubmi').css('margin-right', '5px');
$('.frm-buttons > dd').css('padding-left', '200px');
}
});
});
$(document).ready(function(){
$(".tab_toggle:first").addClass("active").show();
$(".tab_toggle").click(function(){
$(".tab_toggle").removeClass("active");
$(this).addClass("active");
activeTab = $(this).find("a").attr("href");
/*var activeTab = '#' + $(this).find("a").attr("onclick");*/
switch (activeTab)
{
case '#pane_forums_topics':
if (tabTopicsLoaded == 0) {$('#ajax_loading').show();tabTopicsLoaded = 1;}
$('#pane_forums_topics').find('div.main.paged').load("/sta/"+pUserName+" div .main.paged", function() {
TabLoaded();
var $Sel = $('#pane_forums_topics').find('div.main.paged');
if($Sel.length > 1) {
$('#pane_forums_topics .frm-form .page-title').text('Tópicos que criei');
$('.posting').css('display', 'none');
$('.main-foot').css('display', 'none');
} else {
$Sel.html('<div class="no_messages" style="margin-top: 15px;">Não há tópicos para exibir</div>');
}
});
break;
case '#pane_forums_posts':
if (tabPostsLoaded == 0) {$('#ajax_loading').show();tabPostsLoaded = 1;}
$('#pane_forums_posts').find('div.main.paged').load("/spa/"+pUserName+" div .main.paged", function() {
TabLoaded();
var $Sel = $('#pane_forums_posts').find('div.main.paged');
if($Sel.length > 1) {
$('#pane_forums_posts .page-title').text('Posts que fiz');
$('.user.online').css('display', 'none');
$('.post .postmain').css('margin-left', '0');
$('.post .postmain .posthead').css('margin-left', '0');
$('.post .postmain .postfoot').css('margin-left', '0');
$('.posting').css('display', 'none');
$('.main-foot').css('display', 'none');
} else {
$Sel.html('<div class="no_messages" style="margin-top: 15px;">Não há posts para exibir</div>');
}
});
break;
case '#pane_forums_shouts':
if (tabShoutsLoaded == 0) {$('#ajax_loading').show();tabShoutsLoaded = 1;}
$('#pane_forums_shouts').find('div.main.paged').load("/st/"+pUserName+" div .main.paged", function() {
TabLoaded();
var $Sel = $('#pane_forums_shouts').find('div.main.paged');
if($Sel.length > 1) {
$('#pane_forums_shouts .page-title').text('Todas as minhas mensagens');
$('.posting').css('display', 'none');
$('.main-foot').css('display', 'none');
} else {
$Sel.html('<div class="no_messages" style="margin-top: 15px;">Não há mensagens para exibir</div>');
}
});
break;
default:
$('.tab_link_pane').css('display', 'none');
$(activeTab).fadeIn();
}
return false;
});
});
function TabLoaded() {
$('.tab_link_pane').css('display', 'none');
if($("#ajax_loading").is(":visible")) {
$(activeTab).fadeIn();
$('#ajax_loading').fadeOut();
} else {
$(activeTab).show();
}
}
//]]>


Endereço do meu fórum:
[Tens de ter uma conta e sessão iniciada para poderes visualizar este link]

Versão:
PunBB

Josh Josh  • Seg 5 maio 2014 - 0:38

Perfil IPB  Empty Re: Perfil IPB Seg 5 maio 2014 - 0:38

Reputação da mensagem: 100% (1 votos)
Até agora nenhum dos perfils IPB funcionam totalmente.

S4BR1N4 S4BR1N4  • Seg 5 maio 2014 - 2:41

Perfil IPB  Empty Re: Perfil IPB Seg 5 maio 2014 - 2:41

ah, ok Josh obrigada por responder pensei que fosse alguma coisa no meu forum, pois poderia ser algum conflito de algum JS

Josh Josh  • Seg 5 maio 2014 - 11:24

Perfil IPB  Empty Re: Perfil IPB Seg 5 maio 2014 - 11:24

Esse perfil esta em fase de implementação, como tem lá.
Ou seja em breve vai ser atualizado, Aguarde mais respostas pode ser que já possa editar ou já tenha novidades.
Em amigos e adicionados me parece funcional, você já tetou adicionar algum membro ?
Até mais.

S4BR1N4 S4BR1N4  • Seg 5 maio 2014 - 15:04

Perfil IPB  Empty Re: Perfil IPB Seg 5 maio 2014 - 15:04

Josh escreveu:Esse perfil esta em fase de implementação, como tem lá.
Ou seja em breve vai ser atualizado, Aguarde mais respostas pode ser que já possa editar ou já tenha novidades.
Em amigos e adicionados me parece funcional, você já tetou adicionar algum membro ?
Até mais.

sim eu tenho amigos add já mas não aparece para mim nem na aba ao lado esquedo, não sei se pode ser algum conflito de js, por isso queria saber se tem algo para se fazer.

DeeW. DeeW.  • Seg 5 maio 2014 - 22:25

Perfil IPB  Empty Re: Perfil IPB Seg 5 maio 2014 - 22:25

Olá,

O Perfil foi desenvolvido por JScript, o mesmo "parece" que vai parar com suporte Forumeiros.

Até!

S4BR1N4 S4BR1N4  • Ter 6 maio 2014 - 0:45

Perfil IPB  Empty Re: Perfil IPB Ter 6 maio 2014 - 0:45

DeeW. escreveu:Olá,

O Perfil foi desenvolvido por JScript, o mesmo "parece" que vai parar com suporte Forumeiros.

Até!

ah que pena :/ queria que pelo menos os amigos funcionasse. Em todo caso obrigada pela resposta.

Conteúdo patrocinado  • 

Perfil IPB  Empty Re: Perfil IPB

Permissões neste sub-fórum
Não podes responder a tópicos