2 /* vim: set expandtab sw=4 ts=4 sts=4: */
4 * Lists available transformation plugins
8 declare(strict_types
=1);
10 use PhpMyAdmin\Response
;
11 use PhpMyAdmin\Transformations
;
14 * Gets some core libraries and displays a top message if required
16 require_once './libraries/common.inc.php';
18 $response = Response
::getInstance();
19 $header = $response->getHeader();
20 $header->disableMenuAndConsole();
22 $transformations = new Transformations();
24 $types = $transformations->getAvailableMimeTypes();
27 <h2
><?php
echo __('Available MIME types'); ?
></h2
>
29 foreach ($types['mimetype'] as $key => $mimetype) {
30 if (isset($types['empty_mimetype'][$mimetype])) {
31 echo '<i>' , htmlspecialchars($mimetype) , '</i><br />';
33 echo htmlspecialchars($mimetype) , '<br />';
36 $transformation_types = [
37 'transformation', 'input_transformation'
40 'transformation' => __('Available browser display transformations'),
41 'input_transformation' => __('Available input transformations')
44 'transformation' => __('Browser display transformation'),
45 'input_transformation' => __('Input transformation')
49 <?php
foreach ($transformation_types as $ttype) { ?
>
50 <a name
="<?php echo $ttype; ?>"></a
>
51 <h2
><?php
echo $label[$ttype] ?
></h2
>
55 <th
><?php
echo $th[$ttype] ?
></th
>
56 <th
><?php
echo _pgettext('for MIME transformation', 'Description'); ?
></th
>
61 foreach ($types[$ttype] as $key => $transform) {
62 $desc = $transformations->getDescription($types[$ttype . '_file'][$key]);
65 <td
><?php
echo htmlspecialchars($transform); ?
></td
>
66 <td
><?php
echo htmlspecialchars($desc); ?
></td
>
74 } // End of foreach ($transformation_types)