Enlace insertado

"; } else { echo "

Se produjo un error intentando insertar el enlace

"; } } if ( $user_auth && $user_level <= -1 && $showLinks ) { if ( isset( $mod ) ) $linea = $mod; if ( isset( $del ) ) $linea = $del; if ( isset( $linea ) ) { $llink = file( $flinks.".txt" ); $nlink = count($llink); if ( ($fp = fopen( $flinks.".txt", "w" )) ) { for ($i=0;$i<$nlink;$i++) { if ( $i == $linea ) { if ( isset( $mod ) ) { fputs( $fp, $db_descr ."|" ); fputs( $fp, $db_url ."|"); fputs( $fp, urlencode($db_comment)."\n"); } } else fputs( $fp, $llink[$i] ); } fclose( $fp ); } } // include( "inicio.htm" ); // Muestra los enlaces actuales del fichero if ( ( $fp = fopen( $flinks.".txt", "r" ) ) ) { echo "

Listado de enlaces

Fichero: $flinks.txt

"; echo "


"; echo ""; $id = 0; while( $linfo=fscanf($fp, "%[a-zA-Z0-9@&;:,. /!?-]|%[a-zA-Z0-9@&;:,. /!?-]|%[a-zA-Z0-9@&;:,. %/!?+-]\n" ) ) { list( $descLink, $urlLink, $comment ) = $linfo; if ( isset( $smod ) && $smod == $id ) { echo "
IDLink[X]
"; displayFORM( $myName."mod=$id", $descLink, $urlLink, urldecode($comment) ); echo ""; } else { echo ""; echo ""; echo ""; echo ""; } $id++; } echo "
IDLink[X]
$id$descLinkBorrar
"; fclose( $fp ); } else echo "

No he podido abrir el fichero $flinks.txt

"; echo "



"; echo "

Insertar nuevo enlace"; echo "


"; } //include("fin.htm"); function displayFORM( $dest, $db_descr, $db_url, $db_comment ) { echo "
"; echo ''; echo '
Enlace: Información del enlace

Indica un nombre para el enlace, la dirección de este y opcionalmente el comentario que debemos mostrar para el mismo.

El enlace se verá reflejado, en cuanto sea aprovado por alguno de nuestros administradores";

url:
Comentario:

'; echo ''; }