Bravo List

Bravo List (http://www.bvlist.com/index.php)
-   Yuna Scatari Edition (YSE) (http://www.bvlist.com/forumdisplay.php?f=22)
-   -   Fatal Error (http://www.bvlist.com/showthread.php?t=3258)

Geko 22nd August 2009 18:01

Fatal Error
 
I got problem like this.

In browse when I got full torrent list (15) then I put another one torrent then shows the second page. But when I click to open second page I got this error:

Code:

Fatal error:  Call to undefined function  convert_text() in /home2/geko/public_html/takepage.php on line 15
I am sorry for my bad language :( But please help

kp380lv 22nd August 2009 18:14

Screen in studio please!

Geko 22nd August 2009 18:26

http://img199.imageshack.us/img199/929/31263578.jpghttp://img269.imageshack.us/img269/4886/19812402.jpg


and script in takepage.php
PHP Code:


<?

require_once("include/bittorrent.php");
dbconn(false);
header ("Content-Type: text/html; charset=" $tracker_lang['language_charset']);

$page = (int) $_GET["page"];

if (!isset(
$page)) {
    
stdmsg($tracker_lang["error"], "Не пытайся меня взломать!");
}

$count = (int) $_GET["count"];
$torrentsperpage = (int) $_GET["torrentsperpage"];
$where convert_text(urldecode(decode_unicode_url($_GET["where"])));
$orderby "ORDER BY torrents.sticky ASC, torrents.id DESC";

list(
$pagertop$pagerbottom$limit) = browsepager($torrentsperpage$count"browse.php?" $addparam);
$query "SELECT torrents.id, torrents.moderated, torrents.moderatedby, torrents.category, torrents.leechers, torrents.seeders, torrents.free, torrents.name, torrents.times_completed, torrents.size, torrents.added, torrents.comments, torrents.numfiles, torrents.filename, torrents.sticky, torrents.owner," .
"IF(torrents.numratings < $minvotes, NULL, ROUND(torrents.ratingsum / torrents.numratings, 1)) AS rating, categories.name AS cat_name, categories.image AS cat_pic, users.username, users.class".($CURUSER ", EXISTS(SELECT * FROM readtorrents WHERE readtorrents.userid = ".sqlesc($CURUSER["id"])." AND readtorrents.torrentid = torrents.id) AS readtorrent" ", 1 AS readtorrent")." FROM torrents LEFT JOIN categories ON category = categories.id LEFT JOIN users ON torrents.owner = users.id $where $orderby $limit";
$res mysql_query($query) or die(mysql_error());

print(
"<table id=\"pager\" class=\"embedded\" cellspacing=\"0\" cellpadding=\"5\" width=\"100%\"><tr><td class=\"index\" colspan=\"12\">");
print(
$pagertop);
print(
"</td></tr>");

torrenttable($res"index");

print(
"<tr><td class=\"index\" colspan=\"12\">");
print(
$pagerbottom);
print(
"</td></tr></table>");

?>


kp380lv 22nd August 2009 18:31

Seems you miss function convert_text.....

Which source code you use?

Geko 22nd August 2009 18:32

;( I don't even know what is this :( can you please help.

I am using Yuna scatari pre6

Bump: I don't know how to fix it.
When i am at torrent list or in another words in browser I have http://filebits.woano.lv/browse.php

when I click second page on torrent list shows - http://filebits.woano.lv/browse.php#

but needs to be-
http://filebits.woano.lv/browse.php?page=1

How I can fix it?

kp380lv 24th August 2009 08:31

Damn why you use that AJAX browse mod!? It's not good.

BoLaMN 25th August 2009 14:24

well kp380lv your reply was a great success, u Geko u will need to place this function:

PHP Code:

 
function convert_text($s)
{
$out "";
 
for (
$i=0$i<strlen($s); $i++)
{
$c1 substr ($s$i1);
$byte1 ord ($c1);
if (
$byte1>>== 6// 110x xxxx, 110 prefix for 2 bytes unicode
{
$i++;
$c2 substr ($s$i1);
$byte2 ord ($c2);
$byte1 &= 31// remove the 3 bit two bytes prefix
$byte2 &= 63// remove the 2 bit trailing byte prefix
$byte2 |= (($byte1 3) << 6); // last 2 bits of c1 become first 2 of c2
$byte1 >>= 2// c1 shifts 2 to the right
 
$word = ($byte1<<8) + $byte2;
if (
$word==1025$out .= chr(168); // ?
elseif ($word==1105$out .= chr(184); // ?
elseif ($word>=0x0410 && $word<=0x044F$out .= chr($word-848); // ?-? ?-?
else
{
$a dechex($byte1);
$a str_pad($a2"0"STR_PAD_LEFT);
$b dechex($byte2);
$b str_pad($b2"0"STR_PAD_LEFT);
$out .= "&#x".$a.$b.";";
}
}
else
{
$out .= $c1;
}
}
 
return 
$out;


into your takepage.php or globals.php to make this function to work

Cheers BoLaMN

kp380lv 25th August 2009 17:52

Well BoLamn i post better mod for browse which is more effective than this lol


All times are GMT +2. The time now is 18:41.

Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.