|
||
|
||
|
Want to use the NFO stripping engine from this site on your own? I have built a PHP library that can be used pretty much anywhere for any item. PHP version requires cURL library to be enabled. Download Links for each language and a code sample is below. Download PHP Version (PHP Versions 4 & 5)This is a simple PHP Library that uses cURL to strip the NFO against the engine on this site. <?php
// Include Library require 'NFOStripper.lib.php'; // Get Contents of an NFO File $data = file_get_contents('file.nfo'); // Create new NFO Object with the NFO data as the first argument $nfo = new NFOStripper($data); // Set Image Conversion // 0 = No Image Generation, 1 = Generated Image without stripping, 2 = Generated Image with stripping $nfo->ImgOpt(0); // Set Code Formatting // 0 = No Formatting, 1 = BBCode Formatting, 2 = HTML Formatting $nfo->FormatOpt(0); // Strip the NFO and get the results $result = $nfo->Strip(); // Echo Results echo $result; ?> Download Perl/CGI VersionPerl module that can be used for stripping NFO Files. Requires LWP module. #!/usr/bin/perl
# Include the NFOStripper.pm file use NFOStripper; # Get the NFO contents local $/=undef; open(NFO, 'test.nfo') || die("Could not open file!"); $filesize = -s 'test.nfo'; read(NFO, $rawdata, $filesize); close NFO; # Create the New NFOStripper Object my $nfo = eval { new NFOStripper($rawdata); } or die ($@); # Set Image Conversion # 0 = No Image Generation, 1 = Generated Image without stripping, 2 = Generated Image with stripping $nfo->ImgOpt(0); # Set Code Formatting # 0 = No Formatting, 1 = BBCode Formatting, 2 = HTML Formatting $nfo->FormatOpt(0); # Strip the NFO and get the results $result = $nfo->Strip(); # print Results print($result); |
||
|
Yes, an API!
- Added 01/26/2010 22:04:07 CST (-0600) |
||
|