Recent Posts

Pages: [1] 2 3 ... 10
1
XBTIT Support / Fix for speeding up Forum display
« Last post by quimbo on April 17, 2017, 04:55:15 pm »
We are in the process of upgrading our site from  1.38 to xbtit.  We have many forums, topics and posts and file forum_main.php was taking 26 seconds to load.  I have added a table and modified the script.  It now loads in 0.3 seconds

Create a table

Code: [Select]
CREATE TABLE `xbtit_lastpost` (
  `forumid` int(11) NOT NULL,
  `lastpost` int(11) DEFAULT NULL,
  PRIMARY KEY (`forumid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci

next, add the first 2 lines to the php file and and modify the 3rd line to this:

Code: [Select]
$truncate = do_sqlquery("Truncate table {$TABLE_PREFIX}lastpost");

$load = do_sqlquery("insert into {$TABLE_PREFIX}lastpost (forumid,lastpost) (Select forumid,MAX(lastpost) From {$TABLE_PREFIX}topics Group by forumid)");

$forums_res = do_sqlquery(" SELECT f.*, t.lastpost, t.subject, t.locked, p.userid as uid, u.username, p.added as date, p.topicid,".
                          " IF(t.lastpost<=(SELECT lastpostread FROM {$TABLE_PREFIX}readposts rp WHERE rp.userid=".((int)$CURUSER["uid"]).
                          " AND rp.topicid=t.id) OR t.lastpost IS NULL,'unlocked','unlockednew') as img FROM {$TABLE_PREFIX}forums f LEFT JOIN {$TABLE_PREFIX}topics t ON f.id=t.forumid".
                          " LEFT JOIN {$TABLE_PREFIX}posts p ON t.lastpost=p.id".
                          " LEFT JOIN {$TABLE_PREFIX}users u ON p.userid=u.id".
  " left join {$TABLE_PREFIX}lastpost lp on t.lastpost = lp.lastpost and t.forumid = lp.forumid".
  " WHERE (t.lastpost IS NULL OR t.lastpost= lp.lastpost) AND".
  " f.minclassread<=".((int)$CURUSER["id_level"]).
                          " AND f.id_parent=0 ORDER BY sort,name",true);


quimbo

2
I too am having problems with the make command for the newest xbt (from github)

My cpp, gcc, g++, and svn versions are as follows (all updated from older versions):

Code: [Select]
[[email protected] ~]$ cpp --version
cpp (GCC) 4.9.4
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[[email protected] ~]$ gcc --version
gcc (GCC) 4.9.4
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[[email protected] ~]$ g++ --version
g++ (GCC) 4.9.4
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[[email protected] ~]$ svn --version
svn, version 1.7.8 (r1419691)
   compiled Apr 15 2017, 19:22:04

Copyright (C) 2012 The Apache Software Foundation.
This software consists of contributions made by many people; see the NOTICE
file for more information.
Subversion is open source software, see http://subversion.apache.org/

The following repository access (RA) modules are available:

* ra_svn : Module for accessing a repository using the svn network protocol.
  - handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
  - handles 'file' scheme



From the research I've seen, having the above versions exceeds the minimum requirement to process the commands. I still receive errors.

The commands go as follows:

Code: [Select]
git clone https://github.com/OlafvdSpek/xbt
cd xbt/Tracker
cmake .
above processed successfully

Code: [Select]
makeproduces the following error

Code: [Select]
[  7%] Building CXX object CMakeFiles/xbt_tracker.dir/home/site/xbt/misc/bt_misc.o
cc1plus: error: unrecognized command line option "-std=c++11"
make[2]: *** [CMakeFiles/xbt_tracker.dir/home/site/xbt/misc/bt_misc.o] Error 1
make[1]: *** [CMakeFiles/xbt_tracker.dir/all] Error 2
make: *** [all] Error 2

I'm not sure what other dependencies are required to compile the tracker, as the documentation is now very limited.

Anything I might be missing?

Dedicated server details as follows:
  • CentOS 6.8, WHM, cPanel
  • XBTIT 2.5.4
  • Apache 2.4
  • PHP 5.6
  • MySQL 5.0.11
 
Willing to give revision 2389 a try, but unable to find it for download.
Thanks as always!!

[email protected]
3
This has been resolved!!

KingCobra58 (on github) has provided this fix:

Quote
Try replacing this
Code: [Select]
mysqli_query($GLOBALS['conn']to this
Code: [Select]
mysqli_real_escape_string($GLOBALS['conn']in this query
Code: [Select]
do_sqlquery("UPDATE {$TABLE_PREFIX}users SET password='".mysqli_query($GLOBALS['conn'],$multipass[$i]["rehash"])."', salt='".mysqli_query($GLOBALS['conn'],$multipass[$i]["salt"])."', pass_type='".$i."', dupe_hash='".mysqli_query($GLOBALS['conn'],$multipass[$i]["dupehash"])."' WHERE id=$id AND random=$random",true);

After this, no errors and password recovery is functional.

Thank you KingCobra58 and XBTIT dev team for the help and hard work!!
5
XBTIT Support / Re: XBTIT 2.5.0 Styles
« Last post by outtyrox on April 13, 2017, 02:55:55 am »
is there a way to clone the default theme and work on our own theme?
6
SOLVED - See posts below...

Greetings all,

I've posted this to the github bugs report, but would like to gain some more traction with this issue.

When resetting a password in XBTIT v2.5.4, it appears that the rehashed password isn't being sent to the database. The following error flashes quickly after clicking the link in the email, before redirecting you to a success message:

Warning: mysqli_query(): Empty query in /home/site/webroot/recover.php on line 148

This results in no hash in the password column for a particular user in the xbtit_users table, and the user is unable to log in.

For example:
  • Database contains a password hash in the "password" field of the sql database for a user
  • User forgets password, so clicks Recover password
  • User receives email with link to reset password
  • User clicks link, site opens to that error above, then quickly redirects to an affirmative message.
  • User receives second email with temporary, complex password
  • User cannot log in using that password
  • Database no longer contains any password hash in the "password" field for that user

The snippet of code at line 148 is the following:

Code: [Select]
do_sqlquery("UPDATE `{$TABLE_PREFIX}users` SET `password`='".mysqli_query($GLOBALS['conn'],$multipass[$i]["rehash"])."', `salt`='".mysqli_query($GLOBALS['conn'],$multipass[$i]["salt"])."', `pass_type`='".$i."', `dupe_hash`='".mysqli_query($GLOBALS['conn'],$multipass[$i]["dupehash"])."' WHERE `id`=$id AND `random`=$random",true);I've also attached the recover.php file to this post.

Install/server details are as follows:

Fully dedicated server
CentOS 6.8, WHM, cPanel
XBTIT 2.5.4 - fresh, unmodified installation
Apache 2.4
PHP 5.6
MySQL 5.0.11
'mysqli' has been enabled with EasyApache 3 custom configuraiton
Password Hashing Algorithm set to "Classic XBTIT"

This is a migrated database from BTITracker 1.3.2 - used the provided upgrade sql scripts to manually upgrade each necessary table sequentially.

If someone knows of a way to make this code work, that would be excellent. I have installed a couple fresh versions of XBTIT to be sure it wasn't something I did to my modified site code that caused the issue - same problem. Not being able to reset passwords may cause a delay in our relaunch.

Google searches mention this error may be related to mixing mysqli queries and mysql queries. I will look back at past version codes to compare the differences, and see if anything stands out.

Please PM me directly if you think you can help, and need the site URL. We are in development mode, so I don't want the URL to be public just yet.

Thanks and cheers!

[email protected]
7
XBTIT Support / Re: Tracker announce on another server?
« Last post by King Cobra on April 03, 2017, 11:21:08 am »
your a xbtitFM user you should have asked in that support forum
8
XBTIT Support / Tracker announce on another server?
« Last post by arne on April 02, 2017, 08:13:01 am »
Hello,
Is it possible to host my php announce on a seperate server beside the one where site is hosted?

For example my xbtit site in a server and i will use subdoamins for both php and xbt which will be on another server.

Thanks in advance
9
XBTIT Support / Re: xbtit 2.5.4 tracker status not working
« Last post by Mahmoud on March 06, 2017, 03:58:28 pm »
problem solved  :D
it was torrent client error :D and once fixed my torrent file started seeding immediately, it was the proxy server type i change it to "NONE".
Quote
Client:
qBittorrent 3.3.10

Regards,
10
XBTIT Support / xbtit 2.5.4 tracker status not working
« Last post by Mahmoud on March 06, 2017, 11:57:24 am »
Hello,

i just installed xbtit 2.5.4 and uploaded some files to try it but unfortunately i cant start seeding because tracker status error "NOT WORKING" attached screenshot.
i even enabled PID system with live status and NAT checking on but still the same error.
Quote
Server's OS
Linux
PHP version
5.6.21
MYSQL version
10.0.28-MariaDB

thanks,
Pages: [1] 2 3 ... 10

Powered by EzPortal