hi,
i have this code in my project that combine all the css files into one file.
Page.php
public function init() {
parent::init();
//Set our theme's root folder
$themeFolder = $this->ThemeDir();
//Add all the files to combine into an array
$CSSFiles = array(
$themeFolder . '/css/reset.css',
$themeFolder . '/css/fonts.css',
$themeFolder . '/css/style.css',
$themeFolder . '/css/coupons.css'
);
//Set the folder to inside our theme so that relative css image paths work
Requirements::set_combined_files_folder('assets/' . 'combinedfiles');
//Combine!
Requirements::combine_files("combinedCSS.css", $CSSFiles);
}
without calling it in the template, it is being loaded twice.
I also tried including all my css files in the template, but the same thing also happened. They are loaded twice.
it will be much appreciated if someone can help me on this.
Thanks!