I can not display my sorted table with Javascript in HTML (innerHTML)

I've sorted an array of integers and have tried to display it in html but i do not know how to do it.

I've already tried to print the elements without using the functions display


    

    

    


        

Expected Result: 2,3,4,5,8
Current result: undefined

When I use the Chrome console, it works perfectly! There is nothing wrong with this sort code.

jsp – I need my servlet to display a modal, which redirects it to a modal

I have a page that is TurmasUsuario.jsp as in the picture below:
enter the description of the image here

Tap the Add Student In Class link to open a modal as shown in the illustration below. By clicking on this link, add student will send the servlet via doGet the identifier of this class and save in the session variable the idTurma. and in this doGet is the response.sendRedirect ("/ jsp / Modal / Add / ModalAddStudent.jsp");
this will open the modal on the page

enter the description of the image here

enter the description of the image here

When you press add on the modal button, he enters the servlet and goes to the doPost servlet method where he will add the student to the class if the student is registered to the system. below, I will show the method of publication

enter the description of the image here

But it redirects the modal as if it were a page and not as if it were a modal of the page TurmasUsuarios
It redirects the modal as if it 's an independent page.
Figure below
enter the description of the image here

My question is, as he redirects a modal inside the servlet, I tried to use the
PrintWriter out = response.getWriter ();
out.println ("");
out.println ("$ (document) .ready (function () {");
out.println ("$ (# modalAdd Student & # 39;). modal ();");
out.println ("});");
out.println ("");
but that does not work, here it is for him to invoke the modal, but does not invoke

navigation – Hide the sidebar or display a small sidebar for a Web application

I am looking for comments on the navigation structure of a web application.

In the application, we have:

  • A sidebar on the left where all projects are listed
  • A list of views with all the tasks of the selected project
  • A task card

We have a problem with real estate when all 3 columns are open.

I like the idea of ​​being in focus mode and have proposed the idea of ​​exploring the navigation to show only what is relevant for the purpose. ;user.

If a user opens a detail of the task map, the sidebar disappears. The goal is to allow the user to focus on the project:
enter the description of the image here

The other option (which is really popular) is to reduce the sidebar.
The problem is that the user can open the sidebar and end up with 3 columns, which can be overwhelming enter the description of the image here

What do you think? Which option works best?
Thank you

usb debugging – allows screen mirroring on the Galaxy S7 (faulty display) with a keyboard

I have a Galaxy S7 device with a black and broken screen. I would like to activate the screenshot on this one to save the data, but it is not possible to use a touch screen.
So I bought an OTG cable to connect a mouse or keyboard to my phone.
The problem is that I do not know what steps I need to perform to touch the screen mirroring button in the top menu.

Is there a way to know the steps to follow for this?

Or, is there an alternative way to access the phone?

I've tried with the Vysor software application, but it is necessary that USB debugging be enabled on the phone. I therefore may need to know the steps to enable USB debugging via the keyboard.

8 – How to display the date as "there is XX" in the comments / node / taxonomy / blocks?

This code works for comments but I have to display the date in two digits (XX minutes, XX hours, X years) and not "XX hours XX minutes" for example. And I have to apply this format for the rest of the pages of the site.

/**
* Implements hook_preprocess_comment
*/
function THEME_NAME_preprocess_comment(&$variables) {
  // Getting the node creation time stamp from the comment object.
  $date = $variables('comment')->getCreatedTime();
  // Here you can use drupal's format_date() function, or some custom php date formatting.
  $variables('created') = Drupal::service('date.formatter')->formatInterval(REQUEST_TIME - $date);
  $variables('submitted') = t('@username commented !datetime', array('@username' => $variables('author'), '!datetime' => '' . $variables('created') . ' ago '));
}

tables – How to better display a long list of parameters: valuable items?

I would like to ask if there is a better way to display a number of categories containing long lists of items "parameter: value" than what I have for the moment :

Category 1

parameter1: value1
parameter2: value2

Category2

parameter1: value1
parameter2: value2

There are 4 categories. The number of parameters in a list can contain up to 15 elements. The value can be a word as well as several sentences. All this information must be visible simultaneously.

Thank you

object oriented – PHP Display Error Wanings Yellow @ bottom of the page with PHP_EOL

I initially started looking for a php script that would produce php errors on the javascript console. As a default behavior, just spit them anywhere and move everything else.
Although it did not succeed, it is the code that I have developed so far. Can any one please re-read it and tell if it can be shortened or optimized? The Css class that I added to the errors just added the relative position and a value in my external css file.

=> (It would be better to have Absolute position, but then all errors overlap
n / PHP_EOL, can be replaced by a float (I'm not sure yet).

Of course, this can be shortened or optimized in one way or another.
But Php is not my strong point and fight.

Are there any security issues with the use of this.

 ErrorHandler.php (File);


        class MyError
                {
        protected static $collected = array();

        public static function getCollectedErrors()
                             {
          return self::$collected;
                             }

        protected static function addError($key, $error)
                                {
          if (!isset(self::$collected($key)))
            self::$collected($key) = array();
            self::$collected($key)() = $error;
                                }
        // CATCHABLE ERRORS
        public static function captureNormal( $number, $message, 
                                              $file, $line )
                             {
            // Insert all in one table
            $error = array( 'type' => $number, 
                            'message' => $message, 
                            'file' => $file, 
                            'line' => $line 
                           );
            // Display content $error variable
            self::addError('error', $message . " at " . $file . ':' . $line);
                             }

        public static function captureException( $exception )                   // Document Name :: errorHandler.php //
                             {
            // Display content $exception variable
            self::addError('exception', $exception);
                             }

        // UNCATCHABLE ERRORS
        public static function captureShutdown( )
                             {
            $error = error_get_last( );
            if( $error ) {
                ## IF YOU WANT TO CLEAR ALL BUFFER, UNCOMMENT NEXT LINE:
                # ob_end_clean( );

                // Display content $error variable
                self::addError('shutdown', $error);
                          } else { self::addError('shutdown', ''); return true; }                                               
                             }
    }

    set_error_handler( array( 'MyError', 'captureNormal' ) );
    set_exception_handler( array( 'MyError', 'captureException' ) );
    register_shutdown_function( array( 'MyError', 'captureShutdown' ) );
    ?>

& in my index & sub-pages =>

>>>>>> Add if Admin Statement in Here & Password Match & Cookie, csrf check. 
    $errors = MyError::getCollectedErrors();        // This is Linked to ErrorHandlers.php
    foreach ($errors as $category => $items) {
        echo "" . $category . ":
              
"; // I added class dispLow to the outputted errors with escape... foreach ($items as $error) { echo "
Error:" . $error . $items . $catergory ."
" .PHP_EOL; } } ?>

Related issues that I could find:

>> Php Error Handler / Logger
>> Echo at the console

Delete cell element if the field is true on a display page

I have a table views page in Drupal 8 that displays the node titles. On the node, there is a checkbox field that, when checked, indicates on the view table page that this title should not display.

I thought about prepocessor_views_view_field To do this, my question is the function of processor views hook below correct?

/**
 * Implements hook_preprocess_views_view_field()
 * @param $variables
 */
function pnc_views_overrides_preprocess_views_view_field(&$variables){

  if ($variables('field')->field === 'field_display') {
    if($variables('field')->getValue($variables('row')) === 1){
      unset($variables('row'));
    }
  }
}

How to display the developed folder on another page?

I'm trying to display the extended folder list on another page in ionic 3 in the same way as the split pane, but I do not use the ionic split pane.
Please, help me

menus – the product title does not display completely

as you can see in the next image enter the description of the image here

in the single product page, the product name is cut off because of the main menu. This occurs only on the single product page.
This is an online commerce WordPress site.
all other pages are fine. only one product page has this problem