]> jspc29.x-matter.uni-frankfurt.de Git - mvdsensorcontrol.git/commitdiff
corrected bugs
authorMichael Wiebusch <stratomaster@gmx.net>
Wed, 26 Jun 2013 17:24:54 +0000 (19:24 +0200)
committerMichael Wiebusch <stratomaster@gmx.net>
Wed, 26 Jun 2013 17:24:54 +0000 (19:24 +0200)
xml_spielwiese/cgitest.pl

index 86037574fa25b49b18d8d312ffdd77456591d617..db0f9f06b7e831ddecad819cdf81bc67649ce5f0 100755 (executable)
@@ -311,7 +311,7 @@ for my $register (@registers ){
        my $registerName = $register->findvalue("./\@name");
        my $registerId = $register->findvalue("./\@id");
        my $registerSize = $register->findvalue("./\@size");
-  my $registerDescr = prepare_text($spectree->findvalue("/MAPS/register[\@name='""']description") || "n/a");
+  my $registerDescr = prepare_text($spectree->findvalue("/MAPS/register[\@name='".$registerName."']/description") || "n/a");
 
        my $flistid = $xmlfile."//".$registerName;
        
@@ -358,7 +358,7 @@ sub print_fields {
                my $fieldName = $field->findvalue("./\@name");
                my $readOnlyFlag = 0;   
                my $fieldValue = $field->findvalue("./\@value");
-               my $fieldDescr = prepare_text($field->findvalue("./description") || "n/a");
+               my $fieldDescr = prepare_text($spectree->findvalue("/MAPS/register[\@name='".$registerName."']/field[\@name='".$fieldName."']/description") || "n/a");
                my $fieldId = $xmlfile."//".$registerName."/".$fieldName;
                if ($fieldValue eq "") {
                        $fieldValue = $field->findvalue("./\@defaultValue");