JavaScript vérifie si l'objet est nul ou vide
if (typeof value !== 'undefined' && value) {
//deal with value'
};
Sonic
if (typeof value !== 'undefined' && value) {
//deal with value'
};
function isRealValue(obj)
{
return obj && obj !== 'null' && obj !== 'undefined';
}
//Use isRealValue(obj) to check further, will always return truthy object.