Convertisseur UTF-8 en ligne

Un outil bien utile pour débugger les problèmes d’encodage UTF-8 : http://rishida.net/tools/conversion/.

[xslt]Utiliser du code java dans une xsl

Exemple d’utilisation de code java dans une feuille de style XSLT.

example 1:

< ?xml version="1.0" encoding="US-ASCII" ?>





...

example 2:



yyyyMMdd


...

Voir aussi le site de Xalan

Apache Commons Validator

Pour mémoire, la librairie Apache Commons Validator propose une API Java pour valider email, numéro de carte bleu, etc.

De plus, on constate qu’il y a dans le package les librairies en Javascript. Pratique!

[jBoss] MySQL Database Configuration

MySQL is an open source database used by many open source projects and small organizations. To use JBoss 4.0 with MySQL, we first need to put the MySQL driver classes into the CLASSPATH. Copy the .jar file mysql-connector-java-3.0.9-stable-bin.jar to the /server/default/lib directory.

To use the MySQL data source, copy /docs/examples/jca/mysql-ds.xml to the /server/default/deploy directory. Modify the mysql-ds.xml configuration file by setting to com.mysql.jdbc.Driver and to jdbc:mysql:///, where is the MySQL host server and is the MySQL database.

Next, we need to set the and elements in the standardjaws.xml or jaws.xml file:
[xml]

java:/MySqlDS
mySQL

[/xml]

We also need to set the and elements in the standardjbosscmp-jdbc.xml or jbosscmp-jdbc.xml file:
[xml]


java:/MySqlDS
mySQL


[/xml]

Finally, we modify login-config.xml with MySQL database settings. Add the following element to login-config.xml:
[xml]


"org.jboss.resource.security.ConfiguredIdentityLoginModule"
flag = "required">
sa
sa


jboss.jca:service=LocalTxCM,name=MySqlDS




[/xml]

By modifying the mysql-ds.xml, standardjaws.xml, standardjbosscmp-jdbc.xml, and login-config.xml files, the JBoss 4.0 server is configured to be used with a MySQL database.

Source

[Java Web Start] Memos!!

Cet article regroupe les choses dont j’ai généralement besoin de retrouver pour mettre en place une application JAVA avec Java Web Start.

Example de la structure du fichier JNLP de lancement :
[xml]
< ?xml version="1.0" encoding="UTF-8"?>


Slota Benoit
Mon appli



















arg1

[/xml]

LE GUIDE : http://java.sun.com/javase/6/docs/technotes/guides/javaws/developersguide/contents.html

Liens expliquant comment mettre en place un auto-installeur de la JVM avec des scripts de détections automatiques Javascript :

http://java.sun.com/developer/technicalArticles/JavaLP/javawebstart/AutoInstall.html

Le lien chez Sun : http://java.sun.com/products/javawebstart/index.jsp