Welcome Guest, Not a member yet? Register   Sign In
AssetLibPro - An advanced CI Asset Library
#41

[eluser]Nicholas Hanks[/eluser]
I must say this community is very active tnanks to Loops and a&w. Finally I figured out this issue somewhat but I am still struggling to get group functionality where I can put certain js and css in group. I first tried class sent to me by a&w but it had bugs. So, I gave second shot to AssetLibPro and this time I solved some part.

This is what I did!!!

Here what you have to change first in csstidy folder change name class.csstidy.php to csstidy.php (Weird huh!!!)

Secondly give write and read access to compressed folder and read access to plugin folder (especially CSSTIDY FOLDER, this might not be necessary but in my case it was)

This is how I setup my directory structure

DemoApp
css
js
compressed
css
js
system
libraries
Assetlibpro.php
........
application
config
assetlibpro.php

Now you have to change Assetlibpro.php little bit (Library)

in __construct() function add $this->CI->config->load('assetlibpro'); //thanks to Michael aka a&w

in output function whereever it says base_url() replace that with $this->CI->config->item('base_url')

in private function _load_css_config() change
$csstidy = BASEPATH.$this->CI->config->item('alp_csstidy_basepath')."class.csstidy.php";
to
$csstidy = BASEPATH.$this->CI->config->item('alp_csstidy_basepath')."csstidy.php";

Now in config file
$config['alp_asset_dir'] = '/';//TRAILING SLASH!
$config['alp_cache_dir_css'] = '/compressed/css/';//TRAILING SLASH!
$config['alp_cache_dir_js'] = '/compressed/js/';//TRAILING SLASH!

But you can change this configuration however you like it I suppose

Finally this is how you can add CSS and JS

$this->load->library('Assetlibpro');
$this->assetlibpro->add_css('css/test.css');
$this->assetlibpro->add_css('js/test.js');

-------------------------------------------------------------------
Now my question and mission is how can I add CSS and JS in groups and how can I call those groups in views. Instruction mentions something about group but it is not clear enough for me. Any suggestion Undecided


Messages In This Thread
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 04:59 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 12:59 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 01:31 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 01:35 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 01:41 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:10 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:18 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:22 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:31 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:37 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-08-2008, 02:50 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-22-2008, 08:17 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-22-2008, 08:29 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-28-2008, 12:05 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-28-2008, 05:57 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-28-2008, 06:50 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-28-2008, 06:55 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-31-2008, 04:07 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-02-2008, 07:10 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-02-2008, 09:05 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-02-2008, 11:20 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-03-2008, 06:00 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-03-2008, 08:11 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-01-2008, 12:19 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-01-2008, 07:19 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-01-2008, 09:21 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-02-2008, 02:41 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-02-2008, 05:44 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-05-2008, 09:38 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 08-05-2008, 04:12 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-05-2008, 11:24 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 02:28 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 08:34 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 09:09 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 10:27 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 12:33 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 12:47 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 04:24 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-06-2008, 09:30 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-07-2008, 03:42 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-09-2008, 02:49 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 11-23-2008, 02:17 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 12-23-2008, 06:30 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 01-09-2009, 07:51 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 01-09-2009, 09:55 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 01-14-2009, 12:13 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 01-28-2009, 07:51 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 01-30-2009, 08:16 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 03-04-2009, 08:37 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 03-05-2009, 08:23 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 03-05-2009, 08:49 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 03-06-2009, 03:02 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 06-11-2009, 03:28 PM
AssetLibPro - An advanced CI Asset Library - by El Forum - 07-23-2009, 02:51 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 07-23-2009, 07:19 AM
AssetLibPro - An advanced CI Asset Library - by El Forum - 05-30-2010, 04:23 PM



Theme © iAndrew 2016 - Forum software by © MyBB