forked from hetao29/slightphp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSSphinx.php
More file actions
33 lines (30 loc) · 1.33 KB
/
SSphinx.php
File metadata and controls
33 lines (30 loc) · 1.33 KB
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
<?php
/*{{{LICENSE
+-----------------------------------------------------------------------+
| SlightPHP Framework |
+-----------------------------------------------------------------------+
| This program is free software; you can redistribute it and/or modify |
| it under the terms of the GNU General Public License as published by |
| the Free Software Foundation. You should have received a copy of the |
| GNU General Public License along with this program. If not, see |
| http://www.gnu.org/licenses/. |
| Copyright (C) 2008-2009. All Rights Reserved. |
+-----------------------------------------------------------------------+
| Supports: http://www.slightphp.com |
+-----------------------------------------------------------------------+
}}}*/
require_once(dirname(__FILE__).DIRECTORY_SEPARATOR."sphinx/sphinxapi.php");
/**
* @package SlightPHP
*/
class SSphinx extends SlightPHP\SphinxClient{
private $_page=1;
function setPage($page){
$this->_page = $page;
$this->SetLimits (($this->_page-1)*$this->_limit,$this->_limit);
}
function setLimit($limit){
$this->_limit = $limit;
$this->SetLimits (($this->_page-1)*$this->_limit,$this->_limit);
}
}