Tuesday, April 25, 2006

URL GNU/Linux

http://www.zonasiete.org/manual/
http://www.pedroreina.org/curso/
http://del.icio.us/pneff/CursoLinux

www.zonasiete.org/manual/ch14.html
http://packages.debian.org/

Administracion de Programas
http://es.tldp.org/Manuales-LuCAS/AA_Linux_colegio-1.1/AA_Linux_colegio-1.1-html/x7216.htm

Pagina de iTALC
=================
http://italc.sourceforge.net
http://www.juntadeandalucia.es/averroes/guadalinex/?q=node/49

Thunderbird en Español
===================

http://opensourcearticles.com/introduction_to_thunderbird_spanish

Guadalinex - Junta de Andalucia
===============================

http://www.guadalinex.org/

Ruby
===========================
http://es.tldp.org/Manuales-LuCAS/doc-guia-usuario-ruby/doc-guia-usuario-ruby-html/
http://rubyforge.org/frs/?group_id=167

MySQL
============================
http://dev.mysql.com/doc/refman/5.0/es/introduction.html
http://www.webtaller.com/construccion/lenguajes/mysql/lecciones/gestion_usuarios_mysql.php
http://mysql.conclase.net/curso/index.php?cap=013

Manuales en de Linux
===========================
http://www.uoc.edu/posgrado/matricula_abierta/web/materiales_libres.html
http://www.mygnet.com/

Practicas de Linux
======================
http://iescasablancas.xtec.es/cursos/linux/p1.html
http://dis.um.es/~barzana/Informatica/Ejercicios_Practicas/Indice_Practicas_Calc.html
http://www.mononeurona.org/index.php?idp=581

Bash
=======
http://moranar.com.ar/lin/lbash1.html

Guía de Aprendizaje de Python
===============================
http://es.tldp.org/Tutoriales/Python/Tutorial-Python/node6.html

Guia de Squid + Python
=========================
http://www.diariolinux.com/tiki-read_article.php?articleId=7347

http://docs.kde.org/stable/es/kdeedu/kig/index.html

Solid Converter PDF 3.0
========================

S/N: |Name: myName||E-Mail: test@test.co.org|
|Company: myCompany||Serial: MWPW|S/N: |Name: myName||E-Mail: test@test.co.org||Company: myCompany||Serial: MWPW|

Tuesday, March 14, 2006

Links SQL-Server 2005

SQL-Server

http://www.microsoft.com/spanish/msdn/Spain/eventos/encuentromicrosoft/main.asp

VB . NET

http://msdn.microsoft.com/vbasic/

http://www.elguille.info/NET/cursoVB.NET/indice.htm
http://www.elguille.info/NET/ADONET/ejemplo_adonet_bases_tipo_access.htm

Tuesday, March 07, 2006

PHP I

sistema
=====
UTF-8
UTF-16

Latin 1 2 *8 =256
iso-8859-1

Unicode ==2 *16= 65540

http://del.icio.us/pneff/lang:es+curso:php



===========
test.css
===========
ul.navegacion {
background: grey;
color:white;
}
ul.navegacion a {
color: white;
font-weight: bold;
}
.external {
background: grey;
}
===========
Index.html
=========

link rel="stylesheet" href="test.css"





Weblog de Richard


Es mi Weblog


Articulo 2


son estilos de Titulos


Articulo 3




Titulo 4


Titulo 5

Titulo 6

Hola Mundo!


Enlace


eso Tiene Un Enfasis Importante
y aqui tenemos otro Enfasis

Nueva Línea



Patrice
y eso por jemplo
Patrice





========
Bucles en PHP
==========
for($i=0; $i<=10; $i++) { echo "$i
";
}

$i = 0;
while($i <= 10) { echo "$i
";
$i++;
}



foreach($a as $elemento){
echo "$elemento
";
?>



$nombre = "Richard";
$apellido = "Evangelista Piñan";
echo "Hola " .$nombre. ", Como estas
";

$a = array('elemento 1','elemento 2','elemento 3','...');
print_r($a );
if($a[0] == 'elemento 1'){
echo "si está bien!";
}else{
echo "ALGO NO FUNCIONA!";
}


===========
Index.php
=======



Test de PHP:
meta equiv="Content-Type" content="text/html;charset=UTF-8"



Ingrese un Número de 0 - 100







";
$correcto=42;
$_SESSION['intentos']++;
echo "Intentos: $_SESSION[intentos]
";

if($numero==$correcto){
echo "Bien el Numero es: $numero";
}elseif($numero < $correcto){ echo "El Número corecto es Mayor que: $numero"; }else{ echo "El Número corecto es menor que : $numero"; } ?>



===========
Nombre.php
=========









Continuar


===========
nombre2.php
===========







Thursday, March 02, 2006

Configuracion del Repositorio

/etc/apt
=======
deb file:///cdrom/ sarge main local

# deb cdrom:[Debian GNU/Linux edu _Sarge_ - Unofficial i386 Binary-1 (20060120)]/ unstable contrib local main non-free

#deb http://security.debian.org/ stable/updates main contrib non-free
deb http://security.debian.org/ sarge/updates main contrib non-free
### Use (by uncommenting) either http or ftp, NOT both
### http based apt source: ----------------
deb http://ftp.debian.org/debian/ sarge main contrib non-free
deb http://non-us.debian.org/debian-non-US/ sarge/non-US main contrib non-free
deb http://ftp.skolelinux.no/skolelinux/ sarge local
### ftp based apt source: -----------------
# deb ftp://ftp.debian.org/debian/ sarge main contrib non-free
# deb ftp://non-us.debian.org/debian-non-US/ sarge/non-US main contrib non-free
# deb ftp://ftp.skolelinux.no/skolelinux/ sarge local
# deb http://www.backports.org/debian/ sarge-backports main

deb-src http://ftp.debian.org/debian/ sarge main contrib non-free
deb-src http://non-us.debian.org/debian-non-US/ sarge/non-US main contrib non-free
deb-src http://ftp.skolelinux.no/skolelinux/ sarge local
deb http://tjener.intern/apt/ binary/
deb-src http://tjener.intern/apt/ source/
deb http://ftp.de.debian.org/backports.org/ sarge-backports main contrib non-free
=============
grub
=======
# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
default 0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 5

# Pretty colours
color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line) and entries protected by the
# command 'lock'
# e.g. password topsecret
# password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title Windows 95/98/NT/2000
# root (hd0,0)
# makeactive
# chainloader +1
#
# title Linux
# root (hd0,1)
# kernel /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specifiv kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
# kopt=root=/dev/hda2 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd0,1)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
## alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
## lockalternative=false
# lockalternative=false

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
## altoptions=(recovery mode) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
## howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
## memtest86=false
# memtest86=true

## ## End Default Options ##

title Debian GNU/Linux, kernel 2.6.8-2-386
root (hd0,1)
kernel /boot/vmlinuz-2.6.8-2-386 root=/dev/hda2 ro
initrd /boot/initrd.img-2.6.8-2-386
savedefault
boot

title Debian GNU/Linux, kernel 2.6.8-2-386 (recovery mode)
root (hd0,1)
kernel /boot/vmlinuz-2.6.8-2-386 root=/dev/hda2 ro single
initrd /boot/initrd.img-2.6.8-2-386
savedefault
boot

### END DEBIAN AUTOMAGIC KERNELS LIST

title Debian GNU/Linux, kernel 2.6.8-2-386 (sistema testo, /dev/hda3)
root (hd0,2)
kernel /boot/vmlinuz-2.6.8-2-386 root=/dev/hda3 ro
initrd /boot/initrd.img-2.6.8-2-386
savedefault
boot

title Debian GNU/Linux, kernel 2.6.8-2-386 (sistema testo, /dev/hda3) (recovery mode)
root (hd0,2)
kernel /boot/vmlinuz-2.6.8-2-386 root=/dev/hda3 ro single
initrd /boot/initrd.img-2.6.8-2-386
savedefault
boot
=============

Tuesday, February 28, 2006

URL de Programas

apt-get install java-package

URL de Programacio de Juegos en Python
=============================
http://www.linuxjuegos.com/2005/08/25/programacion-de-juegos-en-python-tutorial-2/

Programacion Grafica en Python
=======================
http://wingware.com/doc/intro/tutorial-getting-around

Programa:
===
Python Card

Ejemplo en base a la clase Anterior
========================
# -*- coding: utf-8 -*-
"""
__version__ = "$Revision: 1.5 $"
__date__ = "$Date: 2004/04/30 16:26:12 $"
"""

from PythonCard import model
from clases import *
class MyBackground(model.Background):

def on_initialize(self, event):
self.__actual = -1
l = self.components.lstEstudiantes
l.Clear()

from pickle import load

f = open ("Salon.data", "r")
self.__salon = load(f)
f.close()


for e in self.__salon.getEstudiantes():
l.Append(e.getNombreCompleto() +" "+ e.getCiudad() + " " + e.getMail())

def on_close(self, event):
from pickle import dump
f = open ("Salon.data", "w")
dump(self.__salon, f)
f.close()
event.skip()

def on_lstEstudiantes_select(self,event):
self.__actual = event.GetSelection() #Numero de elemento Seleccionado
lista = self.__salon.getEstudiantes()
e = lista[self.__actual]
self.components.txtNombre.text= e.getNombre()
self.components.txtApellido.text= e.getApellido()
self.components.txtCiudad.text= e.getCiudad()
self.components.txtMail.text= e.getMail()

def on_btnGuardar_mouseClick(self,event):
if self.__actual >=0:
lista = self.__salon.getEstudiantes() #Ingresa a la lista
e = lista[self.__actual]
e.setNombre(self.components.txtNombre.text) #Imprime setNombre con la nueva cadena
e.setApellido(self.components.txtApellido.text)
e.setCiudad(self.components.txtCiudad.text)
e.setMail(self.components.txtMail.text)
self.components.lstEstudiantes.SetString(self.__actual, e.getNombreCompleto()+" "+ e.getCiudad() + " " + e.getMail())

def on_btnNuevo_mouseClick(self,event):
nombre = self.components.txtNombre.text
apellido = self.components.txtApellido.text
ciudad = self.components.txtCiudad.text
mail = self.components.txtMail.text
e = Estudiante(nombre, apellido, ciudad, mail)
self.__salon.anadir(e)
self.components.lstEstudiantes.Append(e.getNombreCompleto()+" "+ e.getCiudad() + " " + e.getMail())
self.__actual = len(self.__salon.getEstudiantes())-1

def on_btnBorrar_mouseClick(self,event):
if self.__actual >=0:
self.components.lstEstudiantes.delete(self.__actual)
lista = self.__salon.getEstudiantes()
del lista[self.__actual]
self.__actual = -1



if __name__ == '__main__':
app = model.Application(MyBackground)
app.MainLoop()


=====================================
Programa de NetSupport para administrar máquinas en Windows
=====================================
http://www.softbull.com/index.php

=====================================
Programa de MySQL Developer
=====================================
http://crlab.com/download.html

Instalar Pugins de Java Debian

Bajar
====
mozilla-plugin-vlc

Instalar
=====
java-package
sun-j2re1.4

Saturday, February 25, 2006



Ejemplode php Richard


buscando errot en la conexion




function conectarse()
{
if (!($link=mysql_connect("localhost","root","")))
{
echo "Error conectando a la base de datos";
exit();
}
if(!mysql_select_db("turno2d",$link))
{
echo "Error Selecionando la base de datos";
exit();
}
return $link;
}
$
$link=conectarse();
echo "conexion satisfactoria.
";
mysql_close($link);//cierra la conexion
?>

$cnt1=mysql_connect("localhost","root","");
mysql_select_db("turno2",$cnt1);
$resultado=mysql_query("select * from cliente".$cnt1);
for ($i=0;$i<5;$i++)
{
echo "Codigo de cliente:".mysql_result($resultado,$i,"id_prueba")."
";
echo "Nombre de cliente:".mysql_result($resultado,$i,"nombre")."
";
echo "Apellido de cliente:".mysql_result($resultado,$i,"apellido")."

";
}
?>
======
Error
======



Web Master Diego Thomson





Lista de Personas




Richard
// Conexion, seleccion de base de datos
$enlace = mysql_connect('localhost', 'richarde', 'password')
or die('No pudo conectarse : ' . mysql_error());
//echo 'Conexión exitosa';
mysql_select_db('richarde') or die('No pudo seleccionarse la BD.');

// Realizar una consulta SQL
$consulta = 'SELECT * FROM personas';
$resultado = mysql_query($consulta) or die('La consulta falló: ' . mysql_error());

// Impresion de resultados en HTML
echo "\n";

?>







while ($linea = mysql_fetch_array($resultado, MYSQL_ASSOC)) {
echo "\t\n";
foreach ($linea as $valor_col) {
echo "\t\t\n";
}
echo "\t\n";
}
echo "
Codigo Nombre Apellido Ciudad
" . htmlspecialchars($valor_col). "
\n";

// Liberar conjunto de resultados
mysql_free_result($resultado);

// Cerrar la conexion
mysql_close($enlace);
?>

Tuesday, February 21, 2006

Tython - Programacion Base de Objetos

Ide
===
  • Dividir un porgrama en partes independientes (clase)
  • Cada clase define un interface publico pero tambien tiene un estado interno
  • No importa al resto del sistema como la clase funciona
Ejmeplo
=====



Tarea:
====
  • Cambiar la tarea 2
  • Crear una clase con tres métodos
    • Número_Aleatorio: retorna un número 1-100
    • pregunta: Pregunta el usuario para un número
    • Jugar:juega
Solución:
======
# -*- coding: iso-8859-15 -*-
class Juego:
def numero_aleatorio(self):
from random import randint
return randint(1,100)
# Retornar número
def pregunta(self):
# Retornar número
#return = numero_aleatorio('Nuemro de 1 100')
while True:
num=raw_input("Ingrese un Nuemro 1 -100")
if num.isdigit() and int(num)<=100: return int(num) print "Ingrese un Numero Valido" def juega(self): numero = self.numero_aleatorio() intentos = 0 while True: usuario = self.pregunta() intentos = intentos + 1 if usuario == numero: print "Muy bien." print intentos, " intentos." break elif numero > usuario:
print "El número buscado es mayor"
elif numero < usuario:
print "El número buscado es menor"
j = Juego()
j.juega()
print j.pregunta()


Ejemplo de Clase:
============
# -*- coding: iso-8859-15 -*-
class Persona:
def __init__(self, nombre, apellido):
self.__nombre=nombre
self.__apelli=apellido
def getNombre(self):
return self.__nombre
def getApellido(self):
return self.__apelli
def setApellido(self,apellido):
self.__apelli=apellido
def getNombreCompleto(self):
return self.__nombre + " " + self.__apelli
def enviarCorreo(self,mensaje):
#
pass

amigos=[]
print "Por favor Ingresa los Nombres de tus Amigos"
print "Para Teminar Ingrese q!"

while True:
nombre=raw_input("Nombre: ")
if nombre=='q':
break
apellido=raw_input("Apellido: ")

pers=Persona(nombre,apellido)
amigos.append(pers)

print
print "Terminado"
for amigo in amigos:
print " - ", amigo.getNombreCompleto()

Caso Practico: Palicacion con clase
======================

Clase.py
=====
class Salon:
def __init__(self,nombre, profesor):
self.__nombre = nombre
self.__profesor = profesor
self.__estudiantes = []
def getNombre(self):
return self.__nombre
def getProfesor(self):
return self.__profesor
def anadir(self, estudiante):
self.__estudiantes.append(estudiante)
def getEstudiantes(self):
return self.__estudiantes

class Profesor:
def __init__(self,nombre):
self.__nombre = nombre
def getNombre(self):
return self.__nombre

class Estudiante:
def __init__(self,nombre):
self.__nombre = nombre
def getNombre(self):
return self.__nombre
Crear.py
=======
from clases import *

p = Profesor("Profe 1")
e1= Estudiante("Estudiante 1")
e2= Estudiante("Estudiante 2")
e3= Estudiante("Estudiante 3")

s = Salon("Salon 1", p)
s.anadir(e1)
s.anadir(e2)
s.anadir(e3)

from pickle import dump
f = open ("Salon.data", "w")
dump(s, f)
f.close()
Leer.py
======
from clases import *
from pickle import load

f = open ("Salon.data", "r")
s = load(f)
f.close()


print s.getNombre()
print 'Profe: ', s.getProfesor().getNombre()
print "Estuduiantes: "
for e in s.getEstudiantes():
print " - ",e.getNombre()
==================