Subversion Repositories oidplus

Rev

Rev 1143 | Rev 1148 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1143 Rev 1144
Line 692... Line 692...
692
                        }
692
                        }
693
 
693
 
694
                        // ---
694
                        // ---
695
 
695
 
696
                        if ($obj) {
696
                        if ($obj) {
697
                                $title = $obj->getTitle();
697
                                $title = $obj->getTitle() ?? '';
698
                                $description = $obj->getDescription();
698
                                $description = $obj->getDescription() ?? '';
699
                                if (empty(strip_tags($description)) && (stripos($description,'<img') === false)) {
699
                                if (empty(strip_tags($description)) && (stripos($description,'<img') === false)) {
700
                                        if (empty($title)) {
700
                                        if (empty($title)) {
701
                                                $desc = '<p><i>'._L('No description for this object available').'</i></p>';
701
                                                $desc = '<p><i>'._L('No description for this object available').'</i></p>';
702
                                        } else {
702
                                        } else {
703
                                                $desc = $title;
703
                                                $desc = $title;
704
                                        }
704
                                        }
705
                                } else {
705
                                } else {
706
                                        $desc = self::objDescription($description);
706
                                        $desc = self::objDescription($description);
707
                                }
707
                                }
708
 
708
 
-
 
709
                                // $description is the description in the OID table (which the user edits)
-
 
710
                                // $desc is the thing that is shown (it can be a title if no description is there, or an MCE editor if the user has write rights)
-
 
711
 
709
                                if ($obj->userHasWriteRights()) {
712
                                if ($obj->userHasWriteRights()) {
710
                                        $rand = ++self::$crudCounter;
713
                                        $rand = ++self::$crudCounter;
711
                                        $desc = '<noscript><p><b>'._L('You need to enable JavaScript to edit title or description of this object.').'</b></p>'.$desc.'</noscript>';
714
                                        $desc = '<noscript><p><b>'._L('You need to enable JavaScript to edit title or description of this object.').'</b></p>'.$desc.'</noscript>';
712
                                        $desc .= '<div class="container box" style="display:none" id="descbox_'.$rand.'">';
715
                                        $desc .= '<div class="container box" style="display:none" id="descbox_'.$rand.'">';
713
                                        $desc .= _L('Title').': <input type="text" name="title" id="titleedit" value="'.htmlentities($title).'"><br><br>'._L('Description').':<br>';
716
                                        $desc .= _L('Title').': <input type="text" name="title" id="titleedit" value="'.htmlentities($title).'"><br><br>'._L('Description').':<br>';