| | |
| Stránka: 1 z 1
| [ Príspevkov: 3 ] | |
Autor | Správa |
---|
Registrovaný: 01.05.05 Príspevky: 13348 Témy: 1496 Bydlisko: Bratislava | Napísal JanoF: 14.10.2006 15:03 | |
|
Kód: ################################################################# ## Mod Title: Last x hours registrations ## Mod Version: 1.0 ## Author: dzidzius (you can find me at forum www.ForumBest.150.pl, there send all questions) ## Description: ## This mods adds user names list that registered in last x(you can defined it) hours ## under last registered user name. ## Installation Level: easy ## Installation Time: 2 ## Files To Edit: ## ## index.php, ## templates\subSilver\index_body.tpl, ## Generator: phpBB2 phpBB MODCreator v 1.1 ################################################################# ## This MOD is released under the GPL License. ## Intellectual Property is retained by the MOD Author(s) listed above ################################################################# ## For Security Purposes, Please Check: http://www.phpbb.com/mods/downloads/ for the ## latest version of this MOD. Downloading this MOD from other sites could cause malicious code ## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered ## in our MOD-Database, located at: http://www.phpbb.com/mods/downloads/ ################################################################# ## ## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD ################################################################# # #-----[ OPEN ]------------------------------------------ # # index.php # #-----[ FIND ]------------------------------------------ # # // # // Start output of page # // # #-----[ REPLACE WITH ]------------------------------------------ # // // Begin Last x hours registrations MOD // $new_user_list = ''; $number_of_hours = 48;
$sql = "SELECT user_id, username, user_regdate FROM " . USERS_TABLE . " ORDER BY user_regdate DESC";
if( !($result = $db->sql_query($sql)) ) { message_die(GENERAL_ERROR, 'Could not query users', '', __LINE__, __FILE__, $sql); }
while( $row = $db->sql_fetchrow($result) ) { if ( $row['user_regdate'] >= ( time() - $number_of_hours*3600 ) ) $new_user_list .= ($new_user_list !='') ? ', <a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=" . $row['user_id']) . '"' . $style_color .'><b>' . $row['username'] . '</b></a>' : '<a href="' . append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=" . $row['user_id']) . '"' . $style_color .'><b>' . $row['username'] . '</b></a>'; else break; }
$new_user_list = ($new_user_list != '') ? 'In last ' . $number_of_hours . ' hours registered: ' . $new_user_list : 'There are no new users in last ' . $number_of_hours . ' hours'; $db->sql_freeresult($result); // // End Last x hours registrations MOD // # #-----[ FIND ]------------------------------------------ # # 'FORUM_IMG' => $images['forum'], # #-----[ BEFORE, ADD ]------------------------------------------ # # 'NEW_USERS_LAST_DAYS' => $new_user_list, # #-----[ OPEN ]------------------------------------------ # # templates\subSilver\index_body.tpl # #-----[ FIND ]------------------------------------------ # # <td class="row1" align="left" width="100%"><span class="gensmall">{TOTAL_POSTS}<br />{TOTAL_USERS}<br />{NEWEST_USER}</span> # #-----[ REPLACE WITH ]------------------------------------------ # # <td class="row1" align="left" width="100%"><span class="gensmall">{TOTAL_POSTS}<br />{TOTAL_USERS}<br />{NEWEST_USER}<br />{NEW_USERS_LAST_DAYS}</span> # #-----[ SAVE/CLOSE ALL FILES ]------------------------------------------ # # EoM
_________________ Streacom DA2 | SilverStone Titanium SX800-LTI 800W | ASRock X299E-ITX/ac | Intel Core i9-9980XE & be quiet! Dark Rock TF | Kingston HyperX Impact 64 GB DDR4 2666 MHz | NVIDIA Titan RTX 24 GB | Intel SSD Optane 905P 480 GB NVMe U.2 & Intel SSD 750 1,2 TB NVMe U.2 & Intel SSD 660p 2 TB NVMe M.2 & Seagate BackUp Plus Portable 56 TB USB | 55" 4K OLED Dell Alienware AW5520QF & 24" LCD EIZO FlexScan EV2451 | Ergotron LX Wall Mount Keyboard Arm | Logitech Craft | Logitech G603 | Logitech F710 | Harman Kardon Sabre SB 35 & Sennheiser RS 175 | Microsoft Windows 7 Ultimate | APC Back-UPS ES 700 | Lenovo ThinkPad X250 | iPhone X 256 GB & Pitaka Aramid | SilverStone ML05B Milo | Corsair SF600 SFX 600W | ASRock X99E-ITX/ac | Intel Xeon E5-2683 v4 & NOCTUA NH-L12S | Kingston HyperX Savage 32 GB DDR4 2400 MHz | NVIDIA GeForce GT 710 1 GB | Intel SSD Optane Memory 32 GB NVMe M.2 & Intel SSD 730 240 GB SATA | Ubuntu Server |
|
Registrovaný: 31.08.06 Príspevky: 99 Témy: 8 Bydlisko: Wien |
$new_user_list = ($new_user_list != '') ? 'In last ' . $number_of_hours . ' hours registered: ' . $new_user_list : 'There are no new users in last ' . $number_of_hours . ' hours';
$db->sql_freeresult($result);
Takze ak spravne predpokladam tak to co je cervenou tak sa da prelozit aby to bolo napriklad v slovencine. Ak sa spravne domnievam tak sa pri zmene jazyka nezmeni to co je tam napisane. Mam pravdu?
|
|
Registrovaný: 01.05.05 Príspevky: 13348 Témy: 1496 Bydlisko: Bratislava | Napísal autor témy JanoF: 23.10.2006 22:40 | |
|
KillerSVK píše: $new_user_list = ($new_user_list != '') ? 'In last ' . $number_of_hours . ' hours registered: ' . $new_user_list : 'There are no new users in last ' . $number_of_hours . ' hours'; $db->sql_freeresult($result);
Takze ak spravne predpokladam tak to co je cervenou tak sa da prelozit aby to bolo napriklad v slovencine. Ak sa spravne domnievam tak sa pri zmene jazyka nezmeni to co je tam napisane. Mam pravdu? jj, ale mozes si to samozrejme upravit tak aby ti to tahalo preklad z jazyka a tym padom ak mas trebars slovencinu a cestinu tak aj pri zmene jazyka sa zmeni tato informacia
_________________ Streacom DA2 | SilverStone Titanium SX800-LTI 800W | ASRock X299E-ITX/ac | Intel Core i9-9980XE & be quiet! Dark Rock TF | Kingston HyperX Impact 64 GB DDR4 2666 MHz | NVIDIA Titan RTX 24 GB | Intel SSD Optane 905P 480 GB NVMe U.2 & Intel SSD 750 1,2 TB NVMe U.2 & Intel SSD 660p 2 TB NVMe M.2 & Seagate BackUp Plus Portable 56 TB USB | 55" 4K OLED Dell Alienware AW5520QF & 24" LCD EIZO FlexScan EV2451 | Ergotron LX Wall Mount Keyboard Arm | Logitech Craft | Logitech G603 | Logitech F710 | Harman Kardon Sabre SB 35 & Sennheiser RS 175 | Microsoft Windows 7 Ultimate | APC Back-UPS ES 700 | Lenovo ThinkPad X250 | iPhone X 256 GB & Pitaka Aramid | SilverStone ML05B Milo | Corsair SF600 SFX 600W | ASRock X99E-ITX/ac | Intel Xeon E5-2683 v4 & NOCTUA NH-L12S | Kingston HyperX Savage 32 GB DDR4 2400 MHz | NVIDIA GeForce GT 710 1 GB | Intel SSD Optane Memory 32 GB NVMe M.2 & Intel SSD 730 240 GB SATA | Ubuntu Server |
|
| Stránka: 1 z 1
| [ Príspevkov: 3 ] | |
| Nemôžete zakladať nové témy v tomto fóre Nemôžete odpovedať na témy v tomto fóre Nemôžete upravovať svoje príspevky v tomto fóre Nemôžete mazať svoje príspevky v tomto fóre
|
|