Форум TBDev  



КОММЕРЧЕСКАЯ ПОДДЕРЖКА: ICQ 159186
НЕ МОЖЕШЬ САМ ПОСТАВИТЬ ТРЕКЕР? УСТАНОВИМ ПЛАТНО
УВАЖАЙТЕ МОЕ И ВАШЕ ВРЕМЯ, НЕ ЗАДАЛБЫВАЙТЕ ГЛУПЫМИ ВОПРОСАМИ!
НЕ ХОТИТЕ ПОПАСТЬ В БАН? ЧИТАЙТЕ ПРАВИЛА
МИНИ-ЧАВО: CHMOD || ОБНОВЛЕНИЕ БЕЗОПАСНОСТИ || ОТКРЫЛСЯ SVN
РЕШЕНИЕ ПРОБЛЕМ: НЕ КАЧАЮТСЯ ФАЙЛЫ || КАК КАЧАТЬ ИЗ SVN || ТОРМОЗИТ ТРЕКЕР?
ОПТИМИЗИРОВАННАЯ ВЕРСИЯ || ТЕСТОВАЯ ВЕРСИЯ (устарело) || GIT ВЕРСИЯ

ОТКРЫЛСЯ РЕПОЗИТОРИЙ НА --> GitHub <--

МУЛЬТИТРЕКЕР С ПОДДЕРЖКОЙ UDP

Вернуться   Форум TBDev > For english speaking users > Hacks'n'mods > Mods requests

Ответ
Опции темы Поиск в этой теме
Непрочитано 19.08.2007, 22:25   #1
Новичок
 
Регистрация: Aug 2007
Возраст: 31
Провел на форуме:
22 ч 39 мин 33 сек.
Сообщения: 26
Поблагодарил: 5
Поблагодарили 5 раз(а) в 4 сообщениях
Файловый архив: 7
Закачек: 0
Вопрос Show announce_url=passhash - how ? And latest posts from IPB forum ?

Hello

In upload.php file how to add line with passhash and then when I open page: http://localhost/upload.php to be something like this:

Announce URL: http://localhost/announce.php?passkey=ffsdfsd6464523fdafapfsdsdfsdjfsdfj ?

To show the passkey.

I've found this line:

Код:
tr($tracker_lang['announce_url'], $announce_urls[0], 1);

But how to modify then ? Something with $CURUSER[passkey] maybe.

-----------

And the second question is - how to build in block-forum.php integration for latest from from IPB forum ? From invisionize site I've downloaded some mod for latest posts, the source of it is:

Код:
<? // **************************************** // // Original mod submitted by Miles Johnson. // // Completely rewritten by Anthony Petito.. // // V2.6: 15 January 2007.................. // // V2.51: 13 June 2006..................... // // V2.5: 03 June 2006..................... // // V2.1: 10 April 2005.................... // // V2.0: 04 April 2005.................... // // **************************************** // // This mod will pull the latest X posts from your forum and display them on your website. // This new version will also handle forums that you do not wish to show (excluded forums) // Put this file where your FORUMS are located (e.g, http://domain.tld/forum). // This should be in the same path as your conf_global.php file // I've commented most of the code so that it's fairly understandable, however, // if you're unsure of what's going on here, stick to the comments on where to edit this file for your site. // For this to work properly, copy the following code into your website. Change it to match the link to THIS filename and path. /* <?php include("http://domain.tld/forum/latest_posts.php");?> */ ///////////////////////////// // User Editable variables // ///////////////////////////// // Change this to the number of posts you would like to show. $posts = 10; // If you would like this mod to cut topics after a certain character length, leave this at 1. Otherwise, change it to 0. $showtopiclength = 1; // Length of title to display before cutting off. If topic title length exceeds this value, it is followed by ellipses (...) // Only useful if the above varaible is set to 1. $topiclength = 40; // Add forumid's to exclude from. For example, you might want to exclude your private forums so that posts from it // do not show up. Seperate each forumid by a comma and ensure there's no spaces in between. $forumexclude = "38,37,71,73,69,44,75,108,74"; /* TIME INTERVAL DISPLAY 0 = only days 1 = only hours 2 = only minutes 3 = only seconds *** NOT WORKING *** 4 = hours and minutes 5 = hours and seconds 6 = minutes and seconds 7 = hours, minutes, seconds Please select which interval to use (besides option 3, which is not working correctly): */ $interval = 6; /* This will display the time interval between posts Example: posted 3 minutes ago Example: posted 2 hours and 3 minutes ago Example: 1 day, 5 hours ago */ //OR display date only // The following 2 lines can be changed to however you want the date and time to be displayed. // Default date: dd month year // Default time: hh:mm ampm TIMEZONE (12 hour time) // For more information on how the next 2 lines can be changed, please reference the README file. // If you elect to show the date and time it was posted instead of the way shown above ONLY, change the $showtime variable to 1. $showtime = 1; $datedisplay = 'j.m.Yг. в H:iч.'; $timedisplay = 'j.m.Yг. в H:iч.'; ////////////// // Required // ////////////// // require "C:\xampp\htdocs\forum\conf_global.php"; ////////////// // Database // ////////////// // hostname or ip of server $servername='localhost'; // username and password to log onto db server $dbusername='*******'; $dbpassword='*******'; // name of database $dbname='*******'; ////////////// Do not edit below///////// connecttodb($servername,$dbname,$dbusername,$dbpassword); function connecttodb($servername,$dbname,$dbuser,$dbpassword) { global $link; $link=mysql_connect ("$servername","$dbuser","$dbpassword"); if(!$link){die("Could not connect to MySQL");} mysql_select_db("$dbname",$link) or die ("could not open db".mysql_error()); } // Query the DB with the supplied user inputted variables. if ($forumexclude <> "") { $getposts = mysql_query("SELECT posts, last_poster_name, last_poster_id, title, tid, forum_id, last_post FROM ibf_topics WHERE (forum_id NOT IN ($forumexclude)) ORDER BY last_post DESC LIMIT $posts") OR DIE (mysql_error()); } else { $getposts = mysql_query("SELECT posts, last_poster_name, last_poster_id, title, tid, forum_id, last_post FROM ibf_topics ORDER BY last_post DESC LIMIT $posts") OR DIE (mysql_error()); } // Format and display the results. while ( $post = mysql_fetch_array($getposts)) { $post[full_title] = $post[title]; if ($showtopiclength == 1 AND strlen($post[full_title]) > $topiclength) { $post[short_title] = substr($post[full_title],0,$topiclength); $post[short_title] = $post[short_title]."..."; } else { $post[short_title] = $post[full_title]; } $posted_on = date($datedisplay, $post[last_post]); // Need to change mySQL timestamp to something more human readable. $today_date = date($datedisplay, time()); // Grab today's date so we can compare it against the posted date if ($showtime == 0) { $showtimediff = timediff($interval,time(),$post[last_post]); $datefield = $showtimediff; } else { // If it was posted today, we want to display "Today, hh:mm AMPM" If ($posted_on == $today_date) { $datefield = "Днес"; $datefield = $datefield . ", " . date($timedisplay, $post[last_post]); } // If it was posted yesterday, we want to display "Yesterday, hh:mm AMPM" elseif (date('d F Y',strtotime("-1 day")) == $posted_on) { $datefield = "Вчера"; $datefield = $datefield . ", " . date($timedisplay, $post[last_post]); } else { $datefield = $posted_on; } } echo ///////////////// // Post Format // ///////////////// // Between the EOD markers you can put whatever you want in HTML format. Just ensure that the link stays somewhat the same. <<<EOD <table width=100% id=torrenttable border=1 cellspacing=0 cellpadding=4> <tr> <td width=25%><center><a href="$INFO[board_url]/ipb/index.php?showtopic=$post[tid]&view=getnewpost">$post[short_title]</a></center></td> <td width=25%><center>$post[posts]</center></td> <td width=25%><center>от <a href="$INFO[board_url]/ipb/index.php?showuser=$post[last_poster_id]"><b>$post[last_poster_name]</b></a></center></td> <td width=25%><center>$datefield</center></td> </tr></table> EOD; } function timediff($interval, $starttime, $endtime) { $timediff = $starttime - $endtime; $days=intval($timediff/86400); $remain=$timediff%86400; $hours=intval($remain/3600); $remain=$remain%3600; $mins=intval($remain/60); $secs=$remain%60; $pluraldays = ($days < 2) ? " day " : " days "; $pluralhours = ($hours < 2) ? " hour " : " hours "; $pluralmins = ($mins < 2) ? " minute " : " minutes "; $pluralsecs = ($secs < 2) ? " second " : " seconds "; $hourcount = ($hours == 0) ? 1 : 0; $minscount = ($mins == 0) ? 1 : 0; $secscount = ($secs == 0) ? 1 : 0; if ($days > 1) { // If a post is older than Yesterday we want to display the the date and time it was created rather than how long ago. // This makes it easier to display rather than having it say 3 days, 5 hours ago, for example. $timediff = $posted_on; } elseif ($days == 1) { // The post is within 1 day old. In this case, I've decided it may be best to show only 1 day, 5 hours ago, for example. $timediff = "posted ".$days." day and ".$hours.$pluralhours." ago"; } else { // Less than 1 day has passed and here we use the interval that was set above. if ($interval == 0) { $timediff = "posted ".$days.$pluraldays." ago";} // show only days elseif ($interval == 1) { $timediff = "posted ".$hours.$pluralhours." ago";} // show only hours elseif ($interval == 2) { $timediff = "posted ".$mins.$pluralmins." ago";} // show only minutes elseif ($interval == 3) { $timediff = "posted ".$secs.$pluralsecs." ago";} // show only seconds elseif ($interval == 4) { // show hours and minutes if ($hourcount) { $timediff = "posted ".$mins." ".$pluralmins." ago"; } else if ($minscount) { $timediff = "posted ".$hours." ".$pluralhours." ago"; } else { $timediff = "posted ".$hours.$pluralhours." and ".$mins." ".$pluralmins." ago"; } } elseif ($interval == 5) { // show hours and seconds if ($hourscount) { $timediff = "posted ".$secs." ".$pluralsecs." ago"; } else if ($secscount) { $timediff = "posted ".$hours." ".$pluralhours." ago"; } else { $timediff = "posted ".$hours.$pluralhours." and ".$sec." ".$pluralsecs." ago"; } } elseif ($interval == 6) { // show minutes and seconds if ($minscount == 1) { $timediff = "posted ".$secs." ".$pluralsecs." ago"; } else if ($secscount == 1 ) { $timediff = "posted ".$mins." ".$pluralmins." ago"; } else { $timediff = "posted ".$mins.$pluralmins." and ".$secs." ".$pluralsecs." ago"; } } else { // show hours, minutes and seconds $timediff = "posted ".$hours.$pluralhours.", ".$mins." ".$pluralmins." and".$secs." ".$pluralsecs." ago"; } } return $timediff; } ?>

I've translated in Bulgarian ( some functions ), but how to to build in block-forum.php ? I've added there ( in file block-forum.php ) line:

Код:
include("http://domain/blocks/latest_posts.php");

But in the index page are errors:

Цитата:
Warning: include() [function.include]: URL file-access is disabled in the server configuration in C:\xampp\htdocs\st\blocks\block-forum.php on line 7

Warning: include(http://domain/blocks/latest_posts.php) [function.include]: failed to open stream: no suitable wrapper could be found in C:\xampp\htdocs\st\blocks\block-forum.php on line 7

Warning: include() [function.include]: Failed opening 'http://domaint/blocks/latest_posts.php' for inclusion (include_path='.;C:\xampp\php\pear\') in C:\xampp\htdocs\st\blocks\block-forum.php on line 7

What do I have to do to work this integration in index.php of latest IPB posts ?

--------------

Also 3rd questions - in my torrent site, based on yours source of TBDev - I've created first SysOp Account. Then second account from the staff panel - just for testing. Then from my SysOp ( a.k.a. Director ) account created torrent ( then delete from my BitTorrent client and download it from the page, because Private Tracker Patch rLz... ), then exit and logged in from the 2nd test account to download the torrent - but it doesn't download it. From the SysOp account - ya, it seeding it ( BitComet 0.70 ). But nothing upload. From the test account - ya, it's leeching it, but nothing downloading. 0% - 0%. What do I have to do ? Or this thing do not working from 1 PC ( 1 IP ) from 2 accounts ? And how to remove ( disable ) this Private Tracker Patch ?

Последний раз редактировалось GEVREKA, 19.08.2007 в 22:31.
GEVREKA вне форума   Ответить с цитированием
Непрочитано 19.08.2007, 23:36   #2
Девелопер
 
Аватар для Yuna
 
Регистрация: Sep 2006
Адрес: Украина, Киев
Возраст: 29
Провел на форуме:
3 мес 1 нед 4 д
Сообщения: 8,844
Поблагодарил: 32
Поблагодарили 3,823 раз(а) в 1,492 сообщениях
Файловый архив: 125
Закачек: 14
Отправить сообщение для  Yuna с помощью ICQ
Цитата:
Сообщение от GEVREKA
And how to remove ( disable ) this Private Tracker Patch ?
takeupload.php

Цитата:
Сообщение от GEVREKA
Also 3rd questions - in my torrent site, based on yours source of TBDev - I've created first SysOp Account. Then second account from the staff panel - just for testing. Then from my SysOp ( a.k.a. Director ) account created torrent ( then delete from my BitTorrent client and download it from the page, because Private Tracker Patch rLz... ), then exit and logged in from the 2nd test account to download the torrent - but it doesn't download it. From the SysOp account - ya, it seeding it ( BitComet 0.70 ). But nothing upload. From the test account - ya, it's leeching it, but nothing downloading. 0% - 0%. What do I have to do ? Or this thing do not working from 1 PC ( 1 IP ) from 2 accounts ?
Probably you are behing nat or anything like that...

Цитата:
Сообщение от GEVREKA
What do I have to do to work this integration in index.php of latest IPB posts ?
You shouldn't write URL, you must write file path not URI...
__________________
Бесплатных консультаций не даю, шаманом и телепатом не работаю.

На вопросы "тут?", "здесь?" и прочие - НЕ ОТВЕЧАЮ.
Сразу пишите что хотели.

Мои TOP-моды:
Yuna вне форума   Ответить с цитированием
Непрочитано 22.08.2007, 06:26   #3
Новичок
 
Регистрация: Aug 2007
Возраст: 31
Провел на форуме:
22 ч 39 мин 33 сек.
Сообщения: 26
Поблагодарил: 5
Поблагодарили 5 раз(а) в 4 сообщениях
Файловый архив: 7
Закачек: 0
1. But exact where in takeupload.php ? What lines to remove/add ?

2. Ya, may be. I've tested with one friend - it works. But I'm downloading from him with big speed, but he from me - very slow speed.

3. It didn't works again . May be you shoud test it, it will be good idea for people ( like me ) using IPB forum.

And I've added to block-stats.php function for $donors, but in block-online.php - how to add it ? Also for warned users. When some donor/warned user is browsing the tracker - to show next to his username star.gif/warned.gif. Something like this:



Also the class-groups ( with their colors ) under online users and from blocks-stats -> Totaal verkeer ( all traffic of the tracker means may be ).

Also searching for these 2 blocks ( specially for your source ):



Thanks .

Последний раз редактировалось GEVREKA, 22.08.2007 в 06:38.
GEVREKA вне форума   Ответить с цитированием
Непрочитано 22.08.2007, 10:17   #4
Девелопер
 
Аватар для Yuna
 
Регистрация: Sep 2006
Адрес: Украина, Киев
Возраст: 29
Провел на форуме:
3 мес 1 нед 4 д
Сообщения: 8,844
Поблагодарил: 32
Поблагодарили 3,823 раз(а) в 1,492 сообщениях
Файловый архив: 125
Закачек: 14
Отправить сообщение для  Yuna с помощью ICQ
Learn PHP
__________________
Бесплатных консультаций не даю, шаманом и телепатом не работаю.

На вопросы "тут?", "здесь?" и прочие - НЕ ОТВЕЧАЮ.
Сразу пишите что хотели.

Мои TOP-моды:
Yuna вне форума   Ответить с цитированием
Непрочитано 12.01.2008, 22:36   #5
Заблокирован
 
Аватар для computerkidt
 
Регистрация: Dec 2007
Адрес: www.armyoffate.net
Возраст: 31
Провел на форуме:
2 д 15 ч 46 мин
Сообщения: 89
Поблагодарил: 6
Поблагодарили 2 раз(а) в 2 сообщениях
Файловый архив: 4
Закачек: 0
Цитата:
Сообщение от Yuna
Learn PHP

LMAO or you can contact me thru IM
computerkidt вне форума   Ответить с цитированием
Ответ


Здесь присутствуют: 1 (пользователей - 0 , гостей - 1)
 
Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск

Ваши права в разделе
Вы не можете создавать темы
Вы не можете отвечать на сообщения
Вы не можете прикреплять файлы
Вы не можете редактировать сообщения

BB-коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход


Часовой пояс GMT +3, время: 18:24.

Помощь проекту: Z383911536440 R302660491620 E291451202567



Анализ сайта Розміщено в Україні

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Valid XHTML 1.0 Transitional Valid CSS!