From 37f4b9caa02783e06dd7c5318200113409a0deb1 Mon Sep 17 00:00:00 2001
From: Derek Jones The above would produce: <br /><br /><br /> Lets you create HTML <h1> tags. The first parameter will contain the data, the
-second the size of the heading. Example: Lets you create HTML <h1> tags. The first parameter will contain the data, the
+second the size of the heading. Example: The above would produce: <h3>Welcome!</h3> The above would produce: <h3>Welcome!</h3> Additionally, in order to add attributes to the heading tag such as HTML classes, ids or inline styles, a third parameter is available.heading()
-echo heading('Welcome!', 3);
-echo heading('Welcome!', 3, 'class="pink"')
@@ -95,7 +95,7 @@ second the size of the heading. Example:
Lets you create HTML <img /> tags. The first parameter contains the image source. Example:
+Lets you create HTML <img /> tags. The first parameter contains the image source. Example:
echo img('images/picture.jpg');
// gives <img src="http://site.com/images/picture.jpg" />
There is an optional second parameter that is a TRUE/FALSE value that specifics if the src should have the page specified by $config['index_page'] added to the address it creates. Presumably, this would be if you were using a media controller.
@@ -116,7 +116,7 @@ second the size of the heading. Example: // <img src="http://site.com/index.php/images/picture.jpg" alt="Me, demonstrating how to eat 4 slices of pizza at one time" class="post_images" width="200" height="200" title="That was quite a night" rel="lightbox" />Lets you create HTML <link /> tags. This is useful for stylesheet links, as well as other links. The parameters are href, with optional rel, type, title, media and index_page. index_page is a TRUE/FALSE value that specifics if the href should have the page specified by $config['index_page'] added to the address it creates. Lets you create HTML <link /> tags. This is useful for stylesheet links, as well as other links. The parameters are href, with optional rel, type, title, media and index_page. index_page is a TRUE/FALSE value that specifics if the href should have the page specified by $config['index_page'] added to the address it creates. Further examples:
+
echo link_tag('css/mystyles.css');
// gives <link href="http://site.com/css/mystyles.css" rel="stylesheet" type="text/css" />
Helps you generate meta tags. You can pass strings to the function, or simple arrays, or multidimensional ones. Examples:
+Helps you generate meta tags. You can pass strings to the function, or simple arrays, or multidimensional ones. Examples:
echo meta('description', 'My Great site');
-// Generates: <meta name="description" content="My Great Site" />
+// Generates: <meta name="description" content="My Great Site" />
-echo meta('Content-type', 'text/html; charset=utf-8', 'equiv'); // Note the third parameter. Can be "equiv" or "name"
-// Generates: <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
+echo meta('Content-type', 'text/html; charset=utf-8', 'equiv'); // Note the third parameter. Can be "equiv" or "name"
+// Generates: <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
echo meta(array('name' => 'robots', 'content' => 'no-cache'));
-// Generates: <meta name="robots" content="no-cache" />
+// Generates: <meta name="robots" content="no-cache" />
@@ -298,7 +298,7 @@ $meta = array(
echo meta($meta);
-// Generates:
+// Generates:
// <meta name="robots" content="no-cache" />
// <meta name="description" content="My Great Site" />
// <meta name="keywords" content="love, passion, intrigue, deception" />
@@ -319,7 +319,7 @@ echo doctype('html4-trans');
// <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
-The following is a list of doctype choices. These are configurable, and pulled from application/config/doctypes.php
+The following is a list of doctype choices. These are configurable, and pulled from application/config/doctypes.php
CodeIgniter User Guide Version 2.0.3 |
+CodeIgniter User Guide Version 2.1.0 |
Table of Contents Page |