Login
Username: Password:
Remember me

[Sign Up] / [Recover Password]

Theme / Language

Popular
New Torrents
new name
Size: 18.40 MB
Most active
new name
S: 74 L: 3
New Posters
[HACK] New Torrent in Shoutbox
Controls ·  Search New posts · Mark unread

You are in: Forum / Forum / v2.08 / v2 Only Mods Complete

Unknown User
2007-10-23 04:02:37
This hack is entirely based in the v Torrential Storm 1.x hack, with the correct changes.

In torrents-upload.php find:

write_log("Torrent $id ($torrent) was uploaded by " . $CURUSER["username"]);
Insert after:


mysql_query("INSERT INTO shoutbox VALUES('', 'System', 'New Torrent: ".$torrent." has been uploaded by [url=http://".$SITEURL."/account-details.php?id=".$CURUSER['id']."]" .$CURUSER['username']. "[/url]', now(), '0')") or sqlerr(__FILE__,__LINE__);







and in shoutbox.php find:



$THEME = $ss_a["uri"];

$lng_a = mysql_fetch_array(mysql_query("select uri from languages where id='" . $site_config['default_language'] . "'")) or die(mysql_error());

if ($lng_a)

$LANGUAGE = $lng_a["uri"];

}





add after:



//replace [url] tags with a proper link

$msg = preg_replace("/\[url\]([^[]+)\[\/url\]/i","<a href=\"\\1\" target=\"_blank\">\\1</a>",$msg);







Have fun!

iMagin3

shoutbox.jpg
shoutbox.jpg
Unknown User
2007-10-23 07:25:06
THX

Very good. I say thank you for it, works
Unknown User
2007-10-23 11:14:38
good working very fine

but do you know if it s possible to change the color of this announcement in the shout box

same thing for the new user annouce in the shout box thanks

gia
Unknown User
2007-10-24 11:38:29
"giajane, post: 34429":
good working very fine
but do you know if it s possible to change the color of this announcement in the shout box

same thing for the new user annouce in the shout box thanks

gia


the announce work very fine in the shout but the link for the upload dont work ????
Unknown User
2007-10-24 11:39:16
"iMagin3 SweeTDeviL, post: 34417":
This hack is entirely based in the v Torrential Storm 1.x hack, with the correct changes.In torrents-upload.php find:

write_log("Torrent $id ($torrent) was uploaded by " . $CURUSER["username"]);
Insert after:


mysql_query("INSERT INTO shoutbox VALUES('', 'System', 'New Torrent: ".$torrent." has been uploaded by [url=http://".$SITEURL."/account-details.php?id=".$CURUSER['id']."]" .$CURUSER['username']. "[/url]', now(), '0')") or sqlerr(__FILE__,__LINE__);



and in shoutbox.php find:



$THEME = $ss_a["uri"];

$lng_a = mysql_fetch_array(mysql_query("select uri from languages where id='" . $site_config['default_language'] . "'")) or die(mysql_error());

if ($lng_a)

$LANGUAGE = $lng_a["uri"];

}





add after:



//replace [url] tags with a proper link

$msg = preg_replace("/\[url\]([^[]+)\[\/url\]/i","<a href=\"\\1\" target=\"_blank\">\\1</a>",$msg);


Have fun!

iMagin3




the announce work very fine in the shout but the link for the upload dont work ????
Unknown User
2007-10-24 13:09:46
The uploaded torrent link doesn
Unknown User
2007-11-14 20:59:22
to make the link work replace $SITEURL by $site_config['SITEURL']

so the final code is :

in torrent-details.php find:

write_log("Torrent $id ($torrent) was uploaded by " . $CURUSER["username"]);
after, add :


mysql_query("INSERT INTO shoutbox VALUES('', 'System', 'New Torrent: [url=".$site_config['SITEURL']."/torrents-details.php?id=".$id."]".$torrent."[/url] has been uploaded by [url=".$site_config['SITEURL']."/account-details.php?id=".$CURUSER['id']."]" .$CURUSER['username']. "[/url]', now(), '0')") or sqlerr(__FILE__,__LINE__);







and in shoutbox.php find:



$THEME = $ss_a["uri"];

$lng_a = mysql_fetch_array(mysql_query("select uri from languages where id='" . $site_config['default_language'] . "'")) or die(mysql_error());

if ($lng_a)

$LANGUAGE = $lng_a["uri"];

}







after, Add :



//replace [url] tags with a proper link

$msg = preg_replace("/\[url\]([^[]+)\[\/url\]/i","<a href=\"\\1\" target=\"_blank\">\\1</a>",$msg);



have fun
Unknown User
2007-11-16 01:33:41
works fine .. but how do i keep from openeing in a new window and how to stop the url in the shoutbox from putting [url="http://anonym.to/"]http://anonym.to/[/url]? in the link
Unknown User
2007-11-16 07:12:39
Anonym.to is in functions.php.. use the search function, we talked quite a lot about it in the 'technical support' section a little while back. To remove the new window, remove target=_new or target=_blank (not sure which one it is...) but be aware that doing so will remove *all* anonym.to redirects on your site.
Unknown User
2007-11-18 14:33:12
"Ezerbeth, post: 35230":
Anonym.to is in functions.php.. use the search function, we talked quite a lot about it in the 'technical support' section a little while back. To remove the new window, remove target=_new or target=_blank (not sure which one it is...) but be aware that doing so will remove *all* anonym.to redirects on your site.


K i removed the anonym.to/? and i changed the _blank to _parent that way it will load in the same window instead of loading in the shoutbox window
Unknown User
2008-01-14 09:44:08
i dont have this in v2.2 and v2.3   :)

In torrents-upload.php find:

CODE

write_log("Torrent $id ($torrent) was uploaded by " . $CURUSER["username"]);
Unknown User
2008-01-14 23:41:28
Sorry for your code but don't work for me

use this , if it's the same for you

In torrents-upload.php find:

write_log("Torrent $id ($name) was Uploaded by $CURUSER[username]");





Add after





$query = "INSERT INTO shoutbox (msgid, user, message, date, userid) VALUES (NULL, 'System', 'New Torrent: [url=".$site_config['SITEURL']."/torrents-details.php?id=".$id."]".$torrent."[/url] has been uploaded by [url=".$site_config['SITEURL']."/account-details.php?id=".$CURUSER['id']."]" .$CURUSER['username']. "[/url]', now(), '0')";

mysql_query($query);
Unknown User
2008-01-15 01:29:53
thanks  :)  i try it now !
Unknown User
2008-01-15 01:54:34
"teamfsx, post: 37503":
Sorry for your code but don't work for me
use this , if it's the same for you

In torrents-upload.php find:

write_log("Torrent $id ($name) was Uploaded by $CURUSER[username]");
Add after




$query = "INSERT INTO shoutbox (msgid, user, message, date, userid) VALUES (NULL, 'System', 'New Torrent: [url=".$site_config['SITEURL']."/torrents-details.php?id=".$id."]".$torrent."[/url] has been uploaded by [url=".$site_config['SITEURL']."/account-details.php?id=".$CURUSER['id']."]" .$CURUSER['username']. "[/url]', now(), '0')";

mysql_query($query);





verry thanks you mista work number one  :)   awsome !
Unknown User
2008-03-05 22:44:21
sorry but when I upload in  Anonymous in the shout I've not anonym??? and my nick name appear!
Users online

No users online

Search



Statistics

    Torrents

  • Tracking: 3
  • Todays torrents: 0
  • Seeders: 0
  • Leechers: 0
  • Peers: 0
  • Downloaded: 89.96 GB
  • Uploaded: 9.86 GB

  • Members

  • We have: 838
  • New today: 0
  • Guest today: 9

  • Online

  • Total online: 2
  • Members: 0
  • Guests online: 2
  • Comments: 3
  • Messages: 1,728