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
Auto-Resize Images & More Tags
Controls ·  Search New posts · Mark unread

You are in: Forum / Forum / v2.08 / v2.08 Mods Completed

Unknown User
2012-04-28 17:52:48
 Images that are too large will be automaticaly resized to 640px and you will get more new tags:

- Small images (240px).

- YouTube and Google videos (and small videos).

- Align all to left, center, right or justify.

In each theme that you have, in header.php before </head> copy this code:


<script type="text/javascript" src="js/ncode_imageresizer.js"></script>
<script type="text/javascript">
<!--
NcodeImageResizer.MODE = 'newwindow';
NcodeImageResizer.MAXWIDTH = 640;
NcodeImageResizer.MAXHEIGHT = 0;
NcodeImageResizer.Msg1 = 'Click this bar to view the full image.';
NcodeImageResizer.Msg2 = 'This image has been resized. Click this bar to view the full image.';
NcodeImageResizer.Msg3 = 'This image has been resized. Click this bar to view the full image.';
NcodeImageResizer.Msg4 = 'Click this bar to view the small image.';
//-->
</script>



theme.css copy this code:

In each theme that you have, in bottom of


/* === Start Resize images === */

table.ncode_imageresizer_warning {
background: #000000;
color: #FF8000;
border:  1px solid #000000;
cursor: pointer;
}

table.ncode_imageresizer_warning td {
font-size: 12px;
color: #FF2000;
vertical-align: middle;
text-decoration: bold;
}

table.ncode_imageresizer_warning td.td1 {
padding: 5px;
}

table.ncode_imageresizer_warning td.td1 {
padding: 2px;
}

/* ==== End Resize images ==== */




In backend/functions.php find and replace this code:


// [img=http://www/image.gif]
$s = preg_replace("/\[img\]((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\[\/img\]/i", "<img border='0' src=\"\\1\" alt='' />", $s);


// [img=http://www/image.gif]
$s = preg_replace("/\[img=((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\]/i", "<img border='0' src=\"\\1\" alt='' />", $s);


with this code:



         // [img=http://www/image.gif]
   $s = preg_replace("/\[img\]((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\[\/img\]/i", "<img border=\"0\" src=\"\\1\" alt=\"\" onload=\"NcodeImageResizer.createOn(this);\">", $s);


// [img=http://www/image.gif]
   $s = preg_replace("/\[img=((http|https):\/\/[^\s'\"<>]+(\.gif|\.jpg|\.png|\.bmp|\.jpeg))\]/i", "<img border=\"0\" src=\"\\1\" alt=\"\" onload=\"NcodeImageResizer.createOn(this);\">", $s);




// [imgw][url="http://www/image.gif%5B/imgw%5D"]http://www/image.gif[/imgw][/url]
 $s = preg_replace("/[imgw](http://[^s'"<>]+(.(jpg|gif|png)))[/imgw]/i","<a class="light" target="_blank" href="1 "><img width="240" src="1" alt="" / border="0"></a><br /><font size="1" color="#FF2000" style="margin-left:5px">Click on image to see it in full size!</font>", $s);

 // [imgw=[url="http://www/image.gif%5D"]http://www/image.gif][/url]
 $s = preg_replace("/[imgw=(http://[^s'"<>]+(.(jpg|gif|png)))]/i","<a class="light" target="_blank" href="1 "><img width="240" src="1" alt="" / border="0"></a><br /><font size="1" color="#FF2000" style="margin-left:5px">Click on image to see it in full size!</font>", $s);

 // YouTube Vids
 $s = preg_replace("/*youtube.com.*v=([^s'"<>]+)]/ims", "<object width="640" height="480"><param name="movie" value="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"></param><param[/url] name="allowscriptaccess" value="never"></param><param name="allowFullScreen" value="true"></param><param name="allowNetworking" value="internal"></param><embed src="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"[/url] type="application/x-shockwave-flash" allowscriptaccess="never" allowfullscreen="true" allowNetworking="internal" width="640" height="480"></embed></object>", $s);

 // YouTube small Vids [videow=URL]
 $s = preg_replace("/[videow=[^s'"<>]*youtube.com.*v=([^s'"<>]+)]/ims", "<object width="320" height="240"><param name="movie" value="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"></param><param[/url] name="allowscriptaccess" value="never"></param><param name="allowFullScreen" value="true"></param><param name="allowNetworking" value="internal"></param><embed src="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"[/url] type="application/x-shockwave-flash" allowscriptaccess="never" allowfullscreen="true" allowNetworking="internal" width="320" height="240"></embed></object>", $s);

 // Google Vids
 $s = preg_replace("/*video.google.com.*docid=(-?[0-9]+).*]/ims", "<embed style="width:640px; height:480px;" id="VideoPlayback" align="middle" type="application/x-shockwave-flash" src="[url="http://video.google.com/googleplayer.swf?docId=1%22"]http://video.google.com/googleplayer.swf?docId=1"[/url] allowScriptAccess="sameDomain" quality="best" bgcolor="#ffffff" scale="noScale" wmode="window" salign="TL"  FlashVars="playerMode=embedded"> </embed>", $s);

 // Google small Vids [videow=URL]
 $s = preg_replace("/[videow=[^s'"<>]*video.google.com.*docid=(-?[0-9]+).*]/ims", "<embed style="width:320px; height:240px;" id="VideoPlayback" align="middle" type="application/x-shockwave-flash" src="[url="http://video.google.com/googleplayer.swf?docId=1%22"]http://video.google.com/googleplayer.swf?docId=1"[/url] allowScriptAccess="sameDomain" quality="best" bgcolor="#ffffff" scale="noScale" wmode="window" salign="TL"  FlashVars="playerMode=embedded"> </embed>", $s);
 //
Text


 $s = preg_replace("/((s|.)+?)/", "<center>1</center>", $s);

 //[align=(left, center, right, justify)]Text[/align]
 


//[align=(center|left|right|justify)]text[/align]
    $s = preg_replace("/\[align=([a-zA-Z]+)\]((\s|.)+?)\[\/align\]/i","<div style=\"text-align:\\1\">\\2</div>", $s);

Extract the attached archive and upload all files into your root.

 [ATTACH]2444._xfImport[/ATTACH]
imageresizer.rar
Download
Unknown User
2012-04-28 22:58:58
very old mod too
Unknown User
2012-04-29 00:31:59
Matchbox please show some respect it's the thought that counts...
Unknown User
2012-04-29 06:05:00
Allow full screen and YouTube website blocking

// YouTube Vids

$s = preg_replace("/[video=[^s'"<>]*youtube.com.*v=([^s'"<>]+)]/ims", "<object width="400" height="325"><param name="movie" value="[url="http://www.youtube.com/watch?v=1%22></param><param"]http://www.youtube.com/watch?v=1"></param><param[/url] name="allowscriptaccess" value="never"></param><param name="allowFullScreen" value="true"></param><param name="allowNetworking" value="internal"></param><embed src="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"[/url] type="application/x-shockwave-flash" allowscriptaccess="never" allowfullscreen="true" allowNetworking="internal" width="400" height="325"></embed></object>", $s);

// YouTube small Vids [videow=URL]

$s = preg_replace("/[videow=[^s'"<>]*youtube.com.*v=([^s'"<>]+)]/ims", "<object width="320" height="240"><param name="movie" value="[url="http://www.youtube.com/watch?v=1%22></param><param"]http://www.youtube.com/watch?v=1"></param><param[/url] name="allowscriptaccess" value="never"></param><param name="allowFullScreen" value="true"></param><param name="allowNetworking" value="internal"></param><embed src="[url="http://www.youtube.com/watch?v=1%22"]http://www.youtube.com/watch?v=1"[/url] type="application/x-shockwave-flash" allowscriptaccess="never" allowfullscreen="true" allowNetworking="internal" width="320" height="240"></embed></object>", $s);

Unknown User
2012-04-29 07:01:28
thanks works nice.
Unknown User
2012-04-29 09:56:40
i do have better for it lol ill post it
Unknown User
2012-07-02 17:12:48
matchbox, I am still waiting... Or is it just an unfounded praise?

I want to invite all those who say that do not work these codes, on my tracker: [url="http://www.flux-gamer.net"]http://www.flux-gamer.net[/url] where work properly for a year  :P

They can have fun with the page 'More Tags' and send their own messages until they are enlightened  :D

I use TT v2.08 and php v5.2.17
Unknown User
2012-07-02 17:14:32
He's banned lol so you may be waiting until the next life pmsl
2012-07-02 17:37:23
Works with V2.08?
Unknown User
2012-07-02 19:07:21
Quote:
Mods Complete

TT v2.08 only - Completed Modifications for v2.08
2012-07-02 21:26:58
"AzuriS, post: 83905":

ok! here its not working ca 2.8
Unknown User
2012-07-31 19:49:50
thx :D
Unknown User
2012-08-11 14:38:18

// Start Resize images

<script type="text/javascript" src="js/ncode_imageresizer.js"></script>
<script type="text/javascript">

<!--
NcodeImageResizer.MODE = 'newwindow';
NcodeImageResizer.MAXWIDTH = 640;
NcodeImageResizer.MAXHEIGHT = 0;
NcodeImageResizer.Msg1 = 'Click this bar to view the full image.';
NcodeImageResizer.Msg2 = 'This image has been resized. Click this bar to view the full image.';
NcodeImageResizer.Msg3 = 'This image has been resized. Click this bar to view the full image.';
NcodeImageResizer.Msg4 = 'Click this bar to view the small image.';
//-->
</script>

// End Resize Images


this not working in the NB-Black-v2.08
Unknown User
2012-10-25 16:10:03
Not working me  :(  use tt2-svn. What is wrong? Where can I find a mistake?
Unknown User
2012-10-25 18:14:35
sometimes changing

<script type="text/javascript" src="scripts/ncode_imageresizer.js"></script>
to


<script type="text/javascript" src="js/ncode_imageresizer.js"></script>


and then copying ncode_imageresizer.js into js

works for people, seems some servers protection blocks the scripts dir

On my site I cant run anything from scripts dir.
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: 3
  • Members: 0
  • Guests online: 3
  • Comments: 3
  • Messages: 1,728