You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2009-01-28 15:35:49

glpi_user
Member
Registered: 2008-10-28
Posts: 9

Small Question - Field does not change

Hello,

small question:

If i have in the field "Inventory number" the worth "00123" an i change it to "000123" (one 0 more) and press "update" the site reloads but the field is not updated? Why?

Greetz

Offline

#2 2009-01-28 15:41:21

MoYo
GLPI - Lead
From: Poitiers
Registered: 2004-09-13
Posts: 14,513
Website

Re: Small Question - Field does not change

Because GLPI compare the datas and PHp say that 00123 is equals to 000123
Try to set another number and set 000123 afetr it will working.
We need to worr on this problem. I create a ticket.

https://dev.indepnet.net/glpi/ticket/1228


MoYo - Julien Dombre - Association INDEPNET
Contribute to GLPI :    Support     Contribute     References     Freshmeat

Offline

#3 2009-01-28 16:04:06

glpi_user
Member
Registered: 2008-10-28
Posts: 9

Re: Small Question - Field does not change

Thank you very much for the fast answer!

The workaround works great, i changed the field sucessfully.


Thank you for the bugreport.

Offline

#4 2009-02-11 11:54:45

benp
Member
Registered: 2007-01-31
Posts: 6

Re: Small Question - Field does not change

MoYo wrote:

Because GLPI compare the datas and PHp say that 00123 is equals to 000123
Try to set another number and set 000123 afetr it will working.
We need to worr on this problem. I create a ticket.

https://dev.indepnet.net/glpi/ticket/1228

Something like that might help:

<?
$test1 = "00123";
$test2 = "000123";

echo $test1." - ".$test2."\n";

echo ($test1 & $test1)."\n";
echo ($test1 & $test2)."\n";

if ($test1 == $test2)
{
        echo "True";
        echo "\n";
}
else
{
        echo "False";
        echo "\n";
}

if ( ($test1 & $test2) == $test1 )
{
        echo "True";
        echo "\n";
}
else
{
        echo "False";
        echo "\n";
}
?>

Best regards

--
Benjamin PREISS

Last edited by benp (2009-02-11 12:02:08)

Offline

Board footer

Powered by FluxBB