Uutiset:

Wondering if this will always be free?  See why free is better.

Main Menu
Advertisement:

¿Click'n'Load 2 para smf? ¿como adaptarlo?

Aloittaja bacanzito, elokuu 20, 2013, 02:29:12 AP

« edellinen - seuraava »

bacanzito

¿Click'n'Load 2  para smf? ¿como adaptarlo?     :D

http://jdownloader.org/knowledge/wiki/glossary/cnl2

Qué es Click 'N' Load 2?



Es una función creada por jDownloader, que también sirve para otros softwares de gestores de descargas, el cual permite que al hacer click en un botón o enlace, los links de descargas se copien automáticamente en el/los softwares de gestores de descargas que estén abierto. Por lo tanto, para ser breves, le brinda comodidad al usuario de no andar copiando los links 1×1 y con un click, mandar los enlaces al programa.

¿Cómo funciona?

Creas en el editor de texto el siguiente bbcode:

[CNL2][/CNL2]

Agregas en entre los BBCodes el link o los links(separados por ","):

[CNL2]link1,link2,link3[/CNL2]

jdownloader.php

<?php
function base16Encode($arg){
$ret="";
for($i=0;$i<strlen($arg);$i++){
$tmp=ord(substr($arg,$i,1));
$ret.=dechex($tmp);
}
return $ret;
}

$key="1234567890987654";
$transmitKey=base16Encode($key);
$link="http://www.mediafire.com/?xxxx1/jDownloader.dmgrnhttp://www.mediafire.com/?xxxx2/jDownloader2.dmg";
$cp mcrypt_module_open(MCRYPT_RIJNDAEL_128'''cbc''');
@
mcrypt_generic_init($cp$key,$key);
$enc mcrypt_generic($cp$link);   
mcrypt_generic_deinit($cp);
mcrypt_module_close($cp);
$crypted=base64_encode($enc);

?>


<FORM ACTION="http://127.0.0.1:9666/flash/addcrypted2" target="hidden" METHOD="POST">
   <INPUT TYPE="hidden" NAME="passwords" VALUE="myPassword">
   <INPUT TYPE="hidden" NAME="source" VALUE="http://jdownloader.org/spielwiese"> 
   <INPUT TYPE="hidden" NAME="jk" VALUE="function f(){ return '31323334353637383930393837363534';}">
   <INPUT TYPE="hidden" NAME="crypted" VALUE="<?php echo $crypted?>">
   <INPUT TYPE="SUBMIT" NAME="submit" VALUE="Add Link to JDownloader">
</FORM>


hay un plugin en  wordpress  que lo hizo un amigo lopezito ejemplo:

cnl2.php

<?php 
/*
Plugin Name: Click'n'Load 2   
Description: Agrega el script Click'n'Load 2 http://jdownloader.org/knowledge/wiki/glossary/cnl2
Version: 1.0
Author: Lopezito 
*/

function CNL2script($attr$content null) {
$linkimg get_option('link_img');
extractshortcode_atts( array('btn' => 'Agregar links a JDownloader''pass' => null), $attr ) );

if(
$pass != NULL || $pass != ''){$passinput '<input type="hidden" name="passwords" value="'.esc_attr($pass).'"/> '; } else {$passinput '';}
if(
$linkimg != NULL || $linkimg != ''){$inputsubmit '<input type="image" name="submit" src="'.$linkimg.'" />';}else{$inputsubmit '<input type="submit" name="submit" value="'.$btn.'"/>';}
if(
$content){
$paso1 explode(','$content);
$listlinks '';
$linkscount 1;
foreach(
$paso1 as $paso2){
$listlinks .= '<a href="'.$paso2.'">Descargar link #'.$linkscount.'</a><br/>';
$linkscount++;
}
$inputlinks str_replace(',','\r\n',$content);
}

return 
$listlinks.'<br/><form action="http://127.0.0.1:9666/flash/add" target="hidden" method="POST">
   '
.$passinput.'
   <input type="hidden" name="source" value="http://jdownloader.org/spielwiese"/>     
   <input type="hidden" name="urls" value="'
.$inputlinks.'"/>
   '
.$inputsubmit.'
</form>'
;

}
add_shortcode('CNL2''CNL2script');


// Panel
function panel_admin_cnl2() {
include('panel.php');
}

function 
panel_admin_menu_cnl2() {
add_options_page'Click \'n\' Load 2''Click \'n\' Load 2''administrator''cnl2_wp''panel_admin_cnl2' );
}

add_action('admin_menu''panel_admin_menu_cnl2');

?>


panel.php

<?php
if($_POST['y'] == 'Y') {
$link $_POST['link_img'];
update_option('link_img'$link);
?>

<div class="updated"><p><strong><?php _e('Datos guardados.' ); ?></strong></p></div>
<?php
} else {
$link get_option('link_img');
}
?>

<style type="text/css">
#wpwrap {
background: rgb(51, 51, 51)!important;
}
#wpfooter {
color: rgb(255, 255, 255)!important;
}
h2.titlewrap {
background: rgb(38, 137, 243);
padding: 5px;
width: 300px;
color: white;
text-shadow: 1px 1px rgba(34, 34, 34, 0.26);
border-left: 5px solid #222;
border-right: 1px solid rgba(34, 34, 34, 0.2);
margin-left: -10px;
}
.wrap {
background: rgb(255, 255, 255) url(http://lopezito.com/imagenes/logo.png) no-repeat top right;
padding: 5px;
border-radius: 5px;
width: 70%;
border: 2px solid rgba(34, 34, 34, 0.32);
}
.updated {
border-radius: 0px!important;
background: rgba(241, 199, 29, 0.57)!important;
border: 1px solid rgb(221, 191, 36)!important;
width:297px;
margin:0px 0px 0px -7px!important;
color: rgb(71, 71, 71)!important;
text-shadow: 1px 1px rgba(255, 255, 255, 0.41)!important;
}
.guardar {
width: 100%;
background: rgb(159, 236, 75);
border: none;
border-right: 1px solid rgba(34, 34, 34, 0.23);
color: rgb(255, 255, 255);
text-shadow: 1px 1px rgba(34, 34, 34, 0.14);
font-size: 20px;
padding: 15px 0px;
cursor: pointer;
border-left: 5px solid #222;
margin-left: -10px;
}
.guardar:hover {
background: rgb(131, 228, 25);
}
textarea {
max-width: 100%;
min-width: 100%;
min-height: 100px;
}
</style>
<div class="wrap">
<?php
echo "<h2 class='titlewrap'>" __'CNL2 - WP''oscimp_trdom' ) . "</h2>";
?>

<?php 
$link 
get_option('link_img');
?>

<form name="oscimp_form" method="post" action="<?php echo str_replace'%7E''~'$_SERVER['REQUEST_URI']); ?>">
<input type="hidden" name="y" value="Y">

<p><?php _e("Link de la imagen*: " ); ?><br/><input name="link_img" value="<?php echo $link?>"></p></p>
* Si no introduce una la url, se mostrar&aacute; un bot&oacute;n com&uacute;n.

<input type="submit" class="guardar" name="Submit" value="<?php _e('Guardar datos''oscimp_trdom' ?>" />
</form>
</div>


fuente: http://lopezito.com/blog/cnl2/








Advertisement: