PHP Classes

File: apps/views/footer/main.php

Recommend this page to a friend!
  Classes of fathurrahman   mnTemplate   apps/views/footer/main.php   Download  
File: apps/views/footer/main.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: mnTemplate
Route HTTP requests to callback functions
Author: By
Last change:
Date: 1 year ago
Size: 883 bytes
 

 

Contents

Class file image Download
<?php
if (isset($resource) && !empty($resource)) {
    foreach (
$resource as $k => $v) {
        echo
add_resource_group($v, null, 'body:end');
    }
}
if (isset(
$extra_js) && !empty($extra_js)) {
    foreach (
$extra_js as $js) {
        if (
$js['pos'] == 'body:end' && $js['type'] == 'file')
            echo
'<script src="' . $js['src'] . '"></script>';
        elseif (
$js['pos'] == 'body:end' && $js['type'] == 'inline') {
            echo
'<script>' . $js['script'] . '</script>';
        }
    }
}

if (isset(
$extra_css) && !empty($extra_css)) {
    foreach (
$extra_css as $css) {
        if (
$css['pos'] == 'body:end' && $css['type'] == 'file')
            echo
'<script src="' . $css['src'] . '"></script>';
        elseif (
$css['pos'] == 'body:end' && $css['type'] == 'inline') {
            echo
'<style>' . $css['style'] . '</style>';
        }
    }
}
?>
</body>

</html>