Hoşgeldin Misafir

[MOD] Welcome on Index / Ana Sayfada Hoşgeldin Karşılaması

MiRaT

13 Kas 2017
2,077 Mesaj

Aktiflik

Seviye

Deneyim

TIM / GÖREV:
Kod:
############################################################## 
## MOD İSMİ: Welcome on Index
## MOD YAZARI: Cherokee Red < [email protected] > (Kenny Cameron) 
http://mrikasu.com/cherokeered
## MOD AÇIKLAMASI: Shows a welcome message on the index page. If the member is registered/logged in, it will show the username - which will also be a link to the users profile. If the user is not logged in/registered, then the username will display as guest and will be a link to the register 
page :) 
## MOD VERSİYONU: 1.0.0
## 
## KURULUM SEVİYESİ : BASİT
## KURULUM SÜRESİ : YAKLAŞIK 3 DK
## EDİTLENECEK DOSYALAR: templates/subSilver/index_body_body.tpl
##         index.php
##         language/lang_english/lang_main.php
## Included Files: n/a 
############################################################## 
## Author Notes:
## 
## I originally thought this this MOD up myself withought knowing that a similar MOD existed - 
http://www.phpbbhacks.com/download/2316 - by hafiz mohd. But I had already started writing my 
version when I found this. I have used some parts of hm's code, but I removed quite a bit. I 
would like to thank hafiz though, as his MOD helped me to perfect mine.
## 
############################################################## 
## MOD History: 
## 
##   2004-10-03 - Version 1.0.0 
##      - mod created
##
############################################################## 
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD 
############################################################## 
#
#-----[ AÇ ]------------------------------------------ 
#
index.php
# 
#-----[ BUL ]------------------------------------------ 
# 
      'body' => 'index_body.tpl')
   );
# 
#-----[ ARDINA EKLE ]------------------------------------------ 
# 
if ($userdata['user_id'] != '-1')
{
    $welcome_name = '<a href="' . append_sid("profile.$phpEx?mode=editprofile&" . $userdata['user_id']) . '">' . $userdata['username'] . '</a>';
}
else
{
    $welcome_name = '<a href="' . append_sid("profile.$phpEx?mode=register&") . '">' . $lang['Guest'] . '</a>';
}
# 
#-----[ BUL ]------------------------------------------ 
# 
      'FORUM_LOCKED_IMG' => $images['forum_locked'],
# 
#-----[ ARDINA EKLE ]------------------------------------------ 
# 

      'L_NAME_WELCOME' => $lang['Welcome'],
      'U_WELCOME_NAME' => $welcome_name,
#
#-----[ AÇ ]------------------------------------------ 
#
templates/subSilver/index_body.tpl
#
#-----[ BUL ]------------------------------------------ 
#
<table width="100%" cellspacing="0" cellpadding="2" border="0" align="center">
#
#-----[ ARDINA EKLE ]------------------------------------------ 
#
<tr>
   <td><span class="gen">
   {L_NAME_WELCOME} {U_WELCOME_NAME}<br />
   </td>
</tr>
#
#-----[ AÇ ]------------------------------------------ 
#
language/lang_english/lang_main.php
# 
#-----[ BUL ]------------------------------------------ 
# 
$lang['Forums_marked_read'] = 'All forums have been marked read';
# 
#-----[ ARDINA EKLE ]------------------------------------------ 
# 

$lang['Welcome'] = "<b>Welcome back</b>";
#-----[ TÜM DEĞŞİKLİKLERİ KAYDET VE DOSYALARI KAPAT ]------------------------------------------ 
# 
# EoM