Welcome Guest, Not a member yet? Register   Sign In
Newbie CI question
#1

[eluser]skaterdav85[/eluser]
Does CI have any kind of CSS library so that you don't have to write this by hand? I wasn't sure if this is in the scope of CI, or if CI only helps you develop the application rather than styling it. Any help would be appreciated!
#2

[eluser]theprodigy[/eluser]
are you referring to the actual css code itself, or the link tag to include an external css file?
#3

[eluser]skaterdav85[/eluser]
not the link tag but the css code itself. I wasnt sure if CI had the power to create a nice looking UI by using certain libraries. I mean I can write all the CSS, but that it time consuming and i hate dealing with browser compatibility.
#4

[eluser]theprodigy[/eluser]
I may be wrong, but I don't believe CI has that capability. Nor do I think that CI will go that route. I think CI's main focus is functionality, not design. Have you tried any of the css frameworks (blueprint, 960 grid, etc)?
#5

[eluser]mddd[/eluser]
CI is more of a backend framework. It focuses more on what happens 'behind the scenes' of your application.
I like that, because it leaves you totally free to build the front-end the way you like. Different from things like
Joomla or Wordpress, that come with a complete front-end that you can change, but only to a certain extent.
#6

[eluser]skaterdav85[/eluser]
No I havent tried any of those CSS frameworks. I didnt even know about them. I'll look into those. Thanks!

also, this is another simple question. How do I link files? Im creating a navigation in my views folder, and say I have a controller called about.php. In my navigation, would i merely place the class name (and function if not index) as the value of the href like this:
Code:
<a href="about">About</a>
?
#7

[eluser]theprodigy[/eluser]
yep, that's pretty much it.
Code:
<a href="about">About</a>
or
Code:
<a href="about/jdoe">About John Doe</a>
Another method is to load the url helper and do something like:
Code:
&lt;?php echo anchor('about','About'); ?&gt;
//or
&lt;?php echo anchor('about/jdoe','About John Doe'); ?&gt;
#8

[eluser]skaterdav85[/eluser]
in the config file where you set the base URL, is it better to include 'index.php' at the end of your URL or is there no difference if you simply leave it off like this:

$config['base_url'] = "http://localhost/CI/test1/";
#9

[eluser]theprodigy[/eluser]
do NOT put index.php in there.

if you take a look a few lines below it, you will see a config setting for the index file. It is named: $config['index_page'].

If you plan to use index.php in your urls, make sure index.php is in this setting.
Code:
$config['index_page'] = "index.php"
If you plan to use an htaccess file to remove index.php from your urls, you can blank this out to an empty string.
Code:
$config['index_page'] = ""
#10

[eluser]skaterdav85[/eluser]
ok thanks for clarifying. I watched a Netuts intro tutorial and they did:
Code:
$config[‘base_url’] = “http://localhost/CI/test1/index.php”;

but in the config file it just has:
Code:
$config[‘base_url’] = “http://www.example.com/”;

so i was not sure.




Theme © iAndrew 2016 - Forum software by © MyBB