|
|
Latest News |
Latest Threads |
|
 |
55.766 Posts & 4.945 Themen in 78 Foren |
|
|
|
 |
Forensuche |
|
Suchbegriff |
Benutzerauswahl |
Ergebnisse anzeigen |
 |
 |
Frage zur Statusbox 48 Beiträge in diesem Thema |
|
|
 |
|
 |
02.08.2012 - 19:46 Uhr |
|
|
|
Leider das selbe ...
Wenn ich den Code rauslasse ist es weg ... nehm ich ihn wieder rein ist die Meldung wieder da. 
|
|
|
|
|
|
|
 |
|
 |
02.08.2012 - 19:56 Uhr |
|
|
|
Nur mal Problehalber:
Öffne die pkinc/main.php und suche das:
| PHP-Quelltext # load extend user-function
if (is_file(pkDIRROOT.'pkinc/userObject.php'))
{
require_once (pkDIRROOT.'pkinc/userObject.php');
}
# load extend user-function | |  |
Und ersetze es mit dem:
Hier klicken zum aufklappen 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 | | PHP-Quelltext # load extend user-function
function userLeagueImage($userID='')
{
# Bilder-PFad
$uLI__imageFolder ='images/Wappen/';
# Bilder-Größe + GrößenPrüfung
$uLI__imageDim
=
array(
'sizeX' =>'22',
'sizeY' =>'22',
'sizeControl' =>TRUE,
);
# erlaubte Bilder-Typen
$uLI__imageAllow
=
array(
'.png',
'.gif',
'.jpg',
'.jpeg',
);
if (!isset($uLI__imageFolder) || !is_string($uLI__imageFolder) || trim($uLI__imageFolder)=='' || !is_dir($uLI__imageFolder))
{
return;
}
if (!isset($uLI__imageAllow) || !is_array($uLI__imageAllow) || count($uLI__imageAllow)===0)
{
return;
}
global
$SQL
;
$uLI__userID
=
isset ($userID)
&& is_numeric($userID)
&& trim ($userID)!=''
? intval ($userID)
: pkGetUservalue('id')
;
$uLI__user =$SQL->fetch_assoc($SQL->query("SELECT spezial_field FROM ".pkSQLTAB_USER." WHERE user_id='".$uLI__userID."' AND user_activate LIMIT 1"));
if (!isset($uLI__user) || !is_array($uLI__user) || count($uLI__user)===0)
{
return;
}
$uLI__user =trim($uLI__user['spezial_field']);
$uLI__image =$uLI__imageFolder.$uLI__user;
$iA__file =
$iA__name =
$uLI__sizeX =
$uLI__sizeY =NULL;
foreach ($uLI__imageAllow as $iA__file)
{
if (!is_file($uLI__image.$iA__file))
{
continue;
}
$iA__name =$uLI__image.$iA__file;
}
if (
isset ($uLI__imageDim)
&& is_array($uLI__imageDim)
&& count ($uLI__imageDim)!==0
&& isset ($uLI__imageDim['sizeControl'])
&& $uLI__imageDim['sizeControl']===TRUE
)
{
$uLI__sizeImage =userImageResize($iA__name, intval($uLI__imageDim['sizeX']), intval($uLI__imageDim['sizeY']));
$uLI__sizeX =$uLI__sizeImage['0'];
$uLI__sizeY =$uLI__sizeImage['1'];
}
return '<img border="0" width="'.$uLI__sizeX.'" height="'.$uLI__sizeY.'" src="'.$iA__name.'" />';
}
function userImageResize($imageFile='', $maxX='', $maxY='')
{
if (!isset($imageFile) || !is_string($imageFile) || trim($imageFile)=='' || !is_file($imageFile))
{
return;
}
$maxX
=
isset ($maxX)
&& is_numeric($maxX)
&& trim ($maxX)!=''
? intval ($maxX)
: '50'
;
$maxY
=
isset ($maxY)
&& is_numeric($maxY)
&& trim ($maxY)!=''
? intval ($maxY)
: '50'
;
$imageArray =getimagesize($imageFile);
$imageX =intval($imageArray['0']);
$imageY =intval($imageArray['1']);
$percentX =$maxX * 100 / $imageX;
$percentY =$maxY * 100 / $imageY;
$percent
=
$percentX <= $percentY
? $percentX
: $percentY
;
$percent =$percent / 100;
$imageX =number_format($imageX * $percent, '0', ',', '.');
$imageY =number_format($imageY * $percent, '0', ',', '.');
return array($imageX, $imageY);
}
# load extend user-function | |  |
Ist halt der Inhalt der userObject.php ohne dem <?php am Anfang und ?> am Ende.
---
Sollte das funktionieren, könnte es sein, das die Datei selbst irgendwas intern drin hat (nicht erkennbar).
Da wäre die Frage dann:
Hast du die Datei selbst erstellt und den Code eingefügt oder über den Anhang hochgeladen?
Wenn ersteres, war es eine .txt-Datei oder eine .rtf-Datei?
|
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von k!r!ka - 05.09.2012 - 19:46 Uhr |
|
|
|
|
|
|
|
 |
|
 |
02.08.2012 - 20:05 Uhr |
|
|
|
So geht es
Die Datei hab ich aus dem Anhang genommen ...
Muss ich das jetzt noch ändern?
|
|
|
|
|
|
|
 |
|
 |
02.08.2012 - 20:10 Uhr |
|
|
|
Nein, wenn es geht, ist es gut. Ich hab es lediglich so gemacht, damit Fremdscripte zumindest ein bisschen isoliert / getrennt vom System sind.
Naja, lassen wir das erstmal so. Wenn dir langweilig ist, oder du halt oben genanntes durchziehen möchtest, dann könntest du ja mal spaßighalber eine vorhandene .php-Datei vom phpKit kopieren und den Inhalt löschen und durch den Inhalt der userObject.php tauschen. Aber wie gesagt, nur wenn dir langweilig ist Und dann natürlich wieder diesen Part mit den Einbinden.
|
|
|
|
|
|
|
 |
|
 |
02.08.2012 - 20:18 Uhr |
|
|
|
Joa wenn mir mal langweilig ist dann versuch ich mal mein Glück.
Vielen Dank für die Hilfe und Arbeit nochmal 
Hätte das nie geschafft.
Großen Dank! 
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 12:00 Uhr |
|
|
|
Bitte unterlasse deine Doppelpostings. Sollte ein neues Problem auftauchen, so bitte auch ein neuen Thread anfangen. Das hilf anderen Usern, ggf. nach einem Problem zu suchen.
MfG
Jardin
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 15:14 Uhr |
|
|
|
Okay entschuldige ... bisher hab ich das ja auch gemacht.
Nur im Prinzip knöpft es ja auch an dieser Funktion an, da ich sie dafür auch benutzt hab.
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 16:13 Uhr |
|
|
|
Also wenn ich das so einfüge, ist in der Community Box kein Bild ... :/
|
Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von Obumba - 05.09.2012 - 16:25 Uhr |
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 16:31 Uhr |
|
|
|
Inwiefern existiert kein Bild? Geht es jetzt um die Änderung mit den Default-Bild oder das einfach kein Bild angezeigt wird? 
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 16:37 Uhr |
|
|
|
Ich meine, mit dem was ich vorher da stehen hatte habe ich ein Bild gesehen ...
Jetzt ist gar keins mehr da.
Sondern nur noch die Links mit den Icons ...
Das mit dem Default hab ich schon eingefügt, kann es aber noch net überprüfen ....
|
|
|
|
|
|
|
 |
|
 |
05.09.2012 - 17:20 Uhr |
|
|
|
Naja die Seite ist vor dem laden kurz weiß mit dem Inhalt:
test-Echo: UserID via pkGetUservalue() ist --> 1
test-Echo: UserID via SESSION ist --> 1
test-Echo: UserID via pkGetUservalue() ist --> 1
test-Echo: UserID via SESSION ist --> 1
Ansonsten hier mal der Code der Navbox ....
Hier klicken zum aufklappen
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 | | PHP-Quelltext
<?php
if(!defined('pkFRONTEND') || pkFRONTEND!='public')
die('Direct access to this location is not permitted.');
$boxlinks=array();
#login
if(!pkGetUservalue('id'))
{
if($config['nb_community_box']!=2)
$boxlinks[0]=pkHtmlLink(pkLink('login'),pkGetLang('login'),'','pknidcommunity0','pkcontent_a_'.$navalign);
else
{
$form_action=pkLink('','','login=1');
$login_remove_path=pkEntities($ENV->getvar('QUERY_STRING'));
$lang_username=pkGetLang('username');
$lang_password=pkGetLang('password');
$lang_bl_login=pkGetLang('bl_login');
eval("\$boxlinks[0]=\"".pkTpl("navigation/community_loginform")."\";");
$boxlinks[1]=pkHtmlLink(pkLink('login','lostpassword'),pkGetLang('password_lost?'),'','','pkcontent_a_'.$navalign);
}
}
echo 'test-Echo: UserID via pkGetUservalue() ist --> '.pkGetUservalue('id').'<br>';
echo 'test-Echo: UserID via SESSION ist --> '.$_SESSION['USER']['id'].'<br>';
# userWappen
$userWappen
=
function_exists('userLeagueImage')
? userLeagueImage(pkGetUservalue('id'))
: NULL
;
# userWappen
#logout
if(pkGetUservalue('id'))
$boxlinks[0]='<a onmouseout="logout.src=\'images/style/ezero-urbanred/deko/login/logout_small.gif\'" onmouseover="logout.src=\'images/style/ezero-urbanred/deko/login/logout_small_b.gif\';" href="?logout=1"><img width="36" height="40" border="0" title="Koffer packen und ausloggen" alt="Koffer packen und ausloggen" name="logout" src="images/style/ezero-urbanred/deko/login/logout_small.gif" /></a> '.pkHtmlLink(pkLink('','','logout=1'),'','','pkcontent_a_'.$navalign);
#memberlist
if(getrights(pkGetConfig('member_infoshow')))
$boxlinks[2]='<a onmouseout="member.src=\'images/style/ezero-urbanred/deko/login/user_small.gif\'" onmouseover="member.src=\'images/style/ezero-urbanred/deko/login/user_small_b.gif\';" href="?path=userslist"><img width="23" height="40" border="0" title="Benutzer suchen oder Profile ansehen" alt="Benutzer suchen oder Profile ansehen" name="member" src="images/style/ezero-urbanred/deko/login/user_small.gif" /></a> '.pkHtmlLink(pkLink('userslist'),'','','pkcontent_a_'.$navalign);
#register & users >> profile
if(intval(pkGetUservalue('id'))>0)
{
##### Popup Awaykalender by burnerfm.de || lcl-online.de #####
include_once(pkDIRCLASS.'away'.pkEXT);
if (!empty($userinfo['user_away_reason']) && $userinfo['user_away_starting'] < pkTIME && $path == 'start')
{
$startdate = date('d.m.Y',$userinfo['user_away_starting']);
$enddate = date('d.m.Y',$userinfo['user_away_ending']);
$grund = $awaykalender->away_show($awayreturn,pkEntities($userinfo['user_away_reason']),'span');
eval("\$site_body.=\"".pkTpl("awaykalender/popup_away")."\";");
}
##### Popup Awaykalender by burnerfm.de || lcl-online.de ####
if(pkGetUservalue('imoption'))
{
if(pkGetUserMessageCount())
{
$boxlinks[4]='<a href="?path=privatemessages&imid=new"><img src="images/style/ezero-urbanred/deko/login/profile_small_ima.gif" border="0" title="Sie haben neue Nachrichten erhalten" alt="Sie haben neue Nachrichten erhalten" /></a> '.pkHtmlLink(pkLink('privatemessages','','imid=new'),pkGetSpecialLang('private_message'),'','','pkcontent_a_'.$navalign,pkGetSpecialLang('private_message'));
}
else {
$boxlinks[4]='<a onmouseout="profil.src=\'images/style/ezero-urbanred/deko/login/profile_small.gif\'" onmouseover="profil.src=\'images/style/ezero-urbanred/deko/login/profile_small_b.gif\';" href="?path=userprofile"><img width="29" height="40" border="0" title="Ihr Profil berabeiten" alt="Ihr Profil berabeiten" name="profil" src="images/style/ezero-urbanred/deko/login/profile_small.gif" /></a> '.pkHtmlLink(pkLink('privatemessages'),'','','pkcontent_a_'.$navalign,pkGetLang('write_private_message'));
}
}else{
$boxlinks[4]='<a onmouseout="profil.src=\'images/style/ezero-urbanred/deko/login/profile_small.gif\'" onmouseover="profil.src=\'images/style/ezero-urbanred/deko/login/profile_small_b.gif\';" href="?path=userprofile"><img width="29" height="40" border="0" title="Ihr Profil berabeiten" alt="Ihr Profil berabeiten" name="profil" src="images/style/ezero-urbanred/deko/login/profile_small.gif" /></a>';
}
#admin link
if(adminaccess('adminarea')){
$boxlinks[5]='<a onmouseout="admin.src=\'images/style/ezero-urbanred/deko/login/admin_small.gif\'" onmouseover="admin.src=\'images/style/ezero-urbanred/deko/login/admin_small_b.gif\';" href="'.pkDIRWWWADMIN.'"><img width="29" height="40" border="0" title="Adminbereich" alt="Adminbereich" name="admin" src="images/style/ezero-urbanred/deko/login/admin_small.gif" /></a>';
}
else{
$boxlinks[3]='<a onmouseout="pn.src=\'images/style/ezero-urbanred/deko/login/alternate_admin_small.gif\'" onmouseover="pn.src=\'images/style/ezero-urbanred/deko/login/alternate_admin_small_b.gif\';" href="?path=privatemessages"><img width="29" height="40" border="0" title="PN - Center" alt="PN - Center" name="pn" src="images/style/ezero-urbanred/deko/login/alternate_admin_small.gif" /></a>';
}
}
return $boxlinks;
?>
| |  |
|
Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von Obumba - 05.09.2012 - 17:21 Uhr |
|
|
|
|
|
|
|
 |
|
 |
Ähnliche Themen |
|
|
|
|
|
|
|
|