CAFPE Docs
  • Class

Classes

  • Article_model
  • Articles
  • Auth
  • Auth_controller
  • Bcrypt
  • Hierarchical_controllers
  • Ion_auth
  • Ion_auth_model
  • MY_Controller
  • MY_Lang
  • MY_Model
  • Pages
  • Private_pages
  • Public_controller
  • Seeder
  • Slug
  • User_sessions
  • Users

Functions

  • action_result
  • actions_widget
  • admin_area_buttons
  • base64_current_url_encode
  • base64_url_decode
  • base64_url_encode
  • current_lang
  • jscript_tag
  • lang_switcher
  • logged_in
  • redirect_lang
  • site_url_lang
  • style_tag
 1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 
<?php defined('BASEPATH') or exit('No direct script access allowed');
/**
 * Assets Helper
 *
 * @usage     $autoload['config'] = array('asset');
 *            $autoload['helper'] = array('asset');
 *
 */

/**
 * Get css main file URL
 *
 * @access  public
 * @return  string CSS main file location
 */
 if (! function_exists('style_tag')) {
    function style_tag($styles)
    {
        $CI =& get_instance();
        $base_css_path = base_url() . $CI->config->item('css_path');
        $output = '';

        foreach ($styles as $style) {
            $output .= "<link rel=\"stylesheet\" href=\"".$base_css_path;
            $output .= "$style.css\">\n";
        }
        return $output;
    }
}

/**
 * Get main js file URL
 *
 * @access  public
 * @return  string
 */
if (! function_exists('jscript_tag')) {
    function jscript_tag($jscripts)
    {
        $CI =& get_instance();
        $base_jscript_path = base_url() . $CI->config->item('jscript_path');
        $output = '';
        foreach ($jscripts as $jscript) {
            $output .= "<script src=\"$base_jscript_path";
            $output .= "$jscript.js\" charset=\"utf-8\"></script>\n";
        }

        return $output;
    }
}
CAFPE Docs API documentation generated by ApiGen