You've already forked codeigniter_test2
first commit
This commit is contained in:
6
application/.htaccess
Normal file
6
application/.htaccess
Normal file
@ -0,0 +1,6 @@
|
||||
|
||||
RewriteEngine on
|
||||
RewriteCond $1 !^(index\.php|images|robots\.txt)
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteRule ^(.*)$ index.php/$1 [L,QSA]
|
1
application/cache/.htaccess
vendored
Normal file
1
application/cache/.htaccess
vendored
Normal file
@ -0,0 +1 @@
|
||||
deny from all
|
10
application/cache/index.html
vendored
Normal file
10
application/cache/index.html
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
116
application/config/autoload.php
Normal file
116
application/config/autoload.php
Normal file
@ -0,0 +1,116 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| AUTO-LOADER
|
||||
| -------------------------------------------------------------------
|
||||
| This file specifies which systems should be loaded by default.
|
||||
|
|
||||
| In order to keep the framework as light-weight as possible only the
|
||||
| absolute minimal resources are loaded by default. For example,
|
||||
| the database is not connected to automatically since no assumption
|
||||
| is made regarding whether you intend to use it. This file lets
|
||||
| you globally define which systems you would like loaded with every
|
||||
| request.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| Instructions
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| These are the things you can load automatically:
|
||||
|
|
||||
| 1. Packages
|
||||
| 2. Libraries
|
||||
| 3. Helper files
|
||||
| 4. Custom config files
|
||||
| 5. Language files
|
||||
| 6. Models
|
||||
|
|
||||
*/
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Packges
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['packages'] = array(APPPATH.'third_party', '/usr/local/shared');
|
||||
|
|
||||
*/
|
||||
|
||||
$autoload['packages'] = array();
|
||||
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Libraries
|
||||
| -------------------------------------------------------------------
|
||||
| These are the classes located in the system/libraries folder
|
||||
| or in your application/libraries folder.
|
||||
|
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['libraries'] = array('database', 'session', 'xmlrpc');
|
||||
*/
|
||||
|
||||
$autoload['libraries'] = array('form_validation');
|
||||
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Helper Files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['helper'] = array('url', 'file');
|
||||
*/
|
||||
|
||||
$autoload['helper'] = array('url','form');
|
||||
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Config files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['config'] = array('config1', 'config2');
|
||||
|
|
||||
| NOTE: This item is intended for use ONLY if you have created custom
|
||||
| config files. Otherwise, leave it blank.
|
||||
|
|
||||
*/
|
||||
|
||||
$autoload['config'] = array();
|
||||
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Language files
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['language'] = array('lang1', 'lang2');
|
||||
|
|
||||
| NOTE: Do not include the "_lang" part of your file. For example
|
||||
| "codeigniter_lang.php" would be referenced as array('codeigniter');
|
||||
|
|
||||
*/
|
||||
|
||||
$autoload['language'] = array();
|
||||
|
||||
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Auto-load Models
|
||||
| -------------------------------------------------------------------
|
||||
| Prototype:
|
||||
|
|
||||
| $autoload['model'] = array('model1', 'model2');
|
||||
|
|
||||
*/
|
||||
|
||||
$autoload['model'] = array();
|
||||
$autoload['libraries'] = array('database','session','table');
|
||||
|
||||
/* End of file autoload.php */
|
||||
/* Location: ./application/config/autoload.php */
|
362
application/config/config.php
Normal file
362
application/config/config.php
Normal file
@ -0,0 +1,362 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Base Site URL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| URL to your CodeIgniter root. Typically this will be you base URL,
|
||||
| WITH a trailing slash:
|
||||
|
|
||||
| http://example.com/
|
||||
|
|
||||
| If this is not set then CodeIgniter will guess the protocol, domain and
|
||||
| path to your installation.
|
||||
|
|
||||
*/
|
||||
$config['base_url'] = 'http://localhost:8080/kape';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Index File
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Typically this will be your index.php file, unless you've renamed it to
|
||||
| something else. If you are using mod_rewrite to remove the page set this
|
||||
| variable so that it is blank.
|
||||
|
|
||||
*/
|
||||
$config['index_page'] = 'index.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URI PROTOCOL
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item determines which server global should be used to retrieve the
|
||||
| URI string. The default setting of 'AUTO' works for most servers.
|
||||
| If your links do not seem to work, try one of the other delicious flavors:
|
||||
|
|
||||
| 'AUTO' Default - auto detects
|
||||
| 'PATH_INFO' Uses the PATH_INFO
|
||||
| 'QUERY_STRING' Uses the QUERY_STRING
|
||||
| 'REQUEST_URI' Uses the REQUEST_URI
|
||||
| 'ORIG_PATH_INFO' Uses the ORIG_PATH_INFO
|
||||
|
|
||||
*/
|
||||
$config['uri_protocol'] = 'AUTO';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| URL suffix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This option allows you to add a suffix to all URLs generated by CodeIgniter.
|
||||
| For more information please see the user guide:
|
||||
|
|
||||
| http://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
|
||||
$config['url_suffix'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Language
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which set of language files should be used. Make sure
|
||||
| there is an available translation if you intend to use something other
|
||||
| than english.
|
||||
|
|
||||
*/
|
||||
$config['language'] = 'english';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Default Character Set
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This determines which character set is used by default in various methods
|
||||
| that require a character set to be provided.
|
||||
|
|
||||
*/
|
||||
$config['charset'] = 'UTF-8';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable System Hooks
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you would like to use the 'hooks' feature you must enable it by
|
||||
| setting this variable to TRUE (boolean). See the user guide for details.
|
||||
|
|
||||
*/
|
||||
$config['enable_hooks'] = FALSE;
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Extension Prefix
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This item allows you to set the filename/classname prefix when extending
|
||||
| native libraries. For more information please see the user guide:
|
||||
|
|
||||
| http://codeigniter.com/user_guide/general/core_classes.html
|
||||
| http://codeigniter.com/user_guide/general/creating_libraries.html
|
||||
|
|
||||
*/
|
||||
$config['subclass_prefix'] = 'MY_';
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Allowed URL Characters
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This lets you specify with a regular expression which characters are permitted
|
||||
| within your URLs. When someone tries to submit a URL with disallowed
|
||||
| characters they will get a warning message.
|
||||
|
|
||||
| As a security measure you are STRONGLY encouraged to restrict URLs to
|
||||
| as few characters as possible. By default only these are allowed: a-z 0-9~%.:_-
|
||||
|
|
||||
| Leave blank to allow all characters -- but only if you are insane.
|
||||
|
|
||||
| DO NOT CHANGE THIS UNLESS YOU FULLY UNDERSTAND THE REPERCUSSIONS!!
|
||||
|
|
||||
*/
|
||||
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable Query Strings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| By default CodeIgniter uses search-engine friendly segment based URLs:
|
||||
| example.com/who/what/where/
|
||||
|
|
||||
| By default CodeIgniter enables access to the $_GET array. If for some
|
||||
| reason you would like to disable it, set 'allow_get_array' to FALSE.
|
||||
|
|
||||
| You can optionally enable standard query string based URLs:
|
||||
| example.com?who=me&what=something&where=here
|
||||
|
|
||||
| Options are: TRUE or FALSE (boolean)
|
||||
|
|
||||
| The other items let you set the query string 'words' that will
|
||||
| invoke your controllers and its functions:
|
||||
| example.com/index.php?c=controller&m=function
|
||||
|
|
||||
| Please note that some of the helpers won't work as expected when
|
||||
| this feature is enabled, since CodeIgniter is designed primarily to
|
||||
| use segment based URLs.
|
||||
|
|
||||
*/
|
||||
$config['allow_get_array'] = TRUE;
|
||||
$config['enable_query_strings'] = FALSE;
|
||||
$config['controller_trigger'] = 'c';
|
||||
$config['function_trigger'] = 'm';
|
||||
$config['directory_trigger'] = 'd'; // experimental not currently in use
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Threshold
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you have enabled error logging, you can set an error threshold to
|
||||
| determine what gets logged. Threshold options are:
|
||||
| You can enable error logging by setting a threshold over zero. The
|
||||
| threshold determines what gets logged. Threshold options are:
|
||||
|
|
||||
| 0 = Disables logging, Error logging TURNED OFF
|
||||
| 1 = Error Messages (including PHP errors)
|
||||
| 2 = Debug Messages
|
||||
| 3 = Informational Messages
|
||||
| 4 = All Messages
|
||||
|
|
||||
| For a live site you'll usually only enable Errors (1) to be logged otherwise
|
||||
| your log files will fill up very fast.
|
||||
|
|
||||
*/
|
||||
$config['log_threshold'] = 0;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Error Logging Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| application/logs/ folder. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['log_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Date Format for Logs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Each item that is logged has an associated date. You can use PHP date
|
||||
| codes to set your own date formatting
|
||||
|
|
||||
*/
|
||||
$config['log_date_format'] = 'Y-m-d H:i:s';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cache Directory Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Leave this BLANK unless you would like to set something other than the default
|
||||
| system/cache/ folder. Use a full server path with trailing slash.
|
||||
|
|
||||
*/
|
||||
$config['cache_path'] = '';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Encryption Key
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If you use the Encryption class or the Session class you
|
||||
| MUST set an encryption key. See the user guide for info.
|
||||
|
|
||||
*/
|
||||
$config['encryption_key'] = '213124mnm';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Session Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'sess_cookie_name' = the name you want for the cookie
|
||||
| 'sess_expiration' = the number of SECONDS you want the session to last.
|
||||
| by default sessions last 7200 seconds (two hours). Set to zero for no expiration.
|
||||
| 'sess_expire_on_close' = Whether to cause the session to expire automatically
|
||||
| when the browser window is closed
|
||||
| 'sess_encrypt_cookie' = Whether to encrypt the cookie
|
||||
| 'sess_use_database' = Whether to save the session data to a database
|
||||
| 'sess_table_name' = The name of the session database table
|
||||
| 'sess_match_ip' = Whether to match the user's IP address when reading the session data
|
||||
| 'sess_match_useragent' = Whether to match the User Agent when reading the session data
|
||||
| 'sess_time_to_update' = how many seconds between CI refreshing Session Information
|
||||
|
|
||||
*/
|
||||
$config['sess_cookie_name'] = 'ci_session';
|
||||
$config['sess_expiration'] = 7200;
|
||||
$config['sess_expire_on_close'] = FALSE;
|
||||
$config['sess_encrypt_cookie'] = FALSE;
|
||||
$config['sess_use_database'] = FALSE;
|
||||
$config['sess_table_name'] = 'ci_sessions';
|
||||
$config['sess_match_ip'] = FALSE;
|
||||
$config['sess_match_useragent'] = TRUE;
|
||||
$config['sess_time_to_update'] = 300;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cookie Related Variables
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| 'cookie_prefix' = Set a prefix if you need to avoid collisions
|
||||
| 'cookie_domain' = Set to .your-domain.com for site-wide cookies
|
||||
| 'cookie_path' = Typically will be a forward slash
|
||||
| 'cookie_secure' = Cookies will only be set if a secure HTTPS connection exists.
|
||||
|
|
||||
*/
|
||||
$config['cookie_prefix'] = "";
|
||||
$config['cookie_domain'] = "";
|
||||
$config['cookie_path'] = "/";
|
||||
$config['cookie_secure'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Global XSS Filtering
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Determines whether the XSS filter is always active when GET, POST or
|
||||
| COOKIE data is encountered
|
||||
|
|
||||
*/
|
||||
$config['global_xss_filtering'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Cross Site Request Forgery
|
||||
|--------------------------------------------------------------------------
|
||||
| Enables a CSRF cookie token to be set. When set to TRUE, token will be
|
||||
| checked on a submitted form. If you are accepting user data, it is strongly
|
||||
| recommended CSRF protection be enabled.
|
||||
|
|
||||
| 'csrf_token_name' = The token name
|
||||
| 'csrf_cookie_name' = The cookie name
|
||||
| 'csrf_expire' = The number in seconds the token should expire.
|
||||
*/
|
||||
$config['csrf_protection'] = FALSE;
|
||||
$config['csrf_token_name'] = 'csrf_test_name';
|
||||
$config['csrf_cookie_name'] = 'csrf_cookie_name';
|
||||
$config['csrf_expire'] = 7200;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Output Compression
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Enables Gzip output compression for faster page loads. When enabled,
|
||||
| the output class will test whether your server supports Gzip.
|
||||
| Even if it does, however, not all browsers support compression
|
||||
| so enable only if you are reasonably sure your visitors can handle it.
|
||||
|
|
||||
| VERY IMPORTANT: If you are getting a blank page when compression is enabled it
|
||||
| means you are prematurely outputting something to your browser. It could
|
||||
| even be a line of whitespace at the end of one of your scripts. For
|
||||
| compression to work, nothing can be sent before the output buffer is called
|
||||
| by the output class. Do not 'echo' any values with compression enabled.
|
||||
|
|
||||
*/
|
||||
$config['compress_output'] = FALSE;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Master Time Reference
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Options are 'local' or 'gmt'. This pref tells the system whether to use
|
||||
| your server's local time as the master 'now' reference, or convert it to
|
||||
| GMT. See the 'date helper' page of the user guide for information
|
||||
| regarding date handling.
|
||||
|
|
||||
*/
|
||||
$config['time_reference'] = 'local';
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Rewrite PHP Short Tags
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your PHP installation does not have short tag support enabled CI
|
||||
| can rewrite the tags on-the-fly, enabling you to utilize that syntax
|
||||
| in your view files. Options are TRUE or FALSE (boolean)
|
||||
|
|
||||
*/
|
||||
$config['rewrite_short_tags'] = FALSE;
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Reverse Proxy IPs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If your server is behind a reverse proxy, you must whitelist the proxy IP
|
||||
| addresses from which CodeIgniter should trust the HTTP_X_FORWARDED_FOR
|
||||
| header in order to properly identify the visitor's IP address.
|
||||
| Comma-delimited, e.g. '10.0.1.200,10.0.1.201'
|
||||
|
|
||||
*/
|
||||
$config['proxy_ips'] = '';
|
||||
|
||||
|
||||
/* End of file config.php */
|
||||
/* Location: ./application/config/config.php */
|
41
application/config/constants.php
Normal file
41
application/config/constants.php
Normal file
@ -0,0 +1,41 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File and Directory Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These prefs are used when checking and setting modes when working
|
||||
| with the file system. The defaults are fine on servers with proper
|
||||
| security, but you may wish (or even need) to change the values in
|
||||
| certain environments (Apache running a separate process for each
|
||||
| user, PHP under CGI with Apache suEXEC, etc.). Octal values should
|
||||
| always be used to set the mode correctly.
|
||||
|
|
||||
*/
|
||||
define('FILE_READ_MODE', 0644);
|
||||
define('FILE_WRITE_MODE', 0666);
|
||||
define('DIR_READ_MODE', 0755);
|
||||
define('DIR_WRITE_MODE', 0777);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| File Stream Modes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| These modes are used when working with fopen()/popen()
|
||||
|
|
||||
*/
|
||||
|
||||
define('FOPEN_READ', 'rb');
|
||||
define('FOPEN_READ_WRITE', 'r+b');
|
||||
define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care
|
||||
define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care
|
||||
define('FOPEN_WRITE_CREATE', 'ab');
|
||||
define('FOPEN_READ_WRITE_CREATE', 'a+b');
|
||||
define('FOPEN_WRITE_CREATE_STRICT', 'xb');
|
||||
define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b');
|
||||
|
||||
|
||||
/* End of file constants.php */
|
||||
/* Location: ./application/config/constants.php */
|
69
application/config/database.php
Normal file
69
application/config/database.php
Normal file
@ -0,0 +1,69 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| DATABASE CONNECTIVITY SETTINGS
|
||||
| -------------------------------------------------------------------
|
||||
| This file will contain the settings needed to access your database.
|
||||
|
|
||||
| For complete instructions please consult the 'Database Connection'
|
||||
| page of the User Guide.
|
||||
|
|
||||
| -------------------------------------------------------------------
|
||||
| EXPLANATION OF VARIABLES
|
||||
| -------------------------------------------------------------------
|
||||
|
|
||||
| ['hostname'] The hostname of your database server.
|
||||
| ['username'] The username used to connect to the database
|
||||
| ['password'] The password used to connect to the database
|
||||
| ['database'] The name of the database you want to connect to
|
||||
| ['dbdriver'] The database type. ie: mysql. Currently supported:
|
||||
mysql, mysqli, postgre, odbc, mssql, sqlite, oci8
|
||||
| ['dbprefix'] You can add an optional prefix, which will be added
|
||||
| to the table name when using the Active Record class
|
||||
| ['pconnect'] TRUE/FALSE - Whether to use a persistent connection
|
||||
| ['db_debug'] TRUE/FALSE - Whether database errors should be displayed.
|
||||
| ['cache_on'] TRUE/FALSE - Enables/disables query caching
|
||||
| ['cachedir'] The path to the folder where cache files should be stored
|
||||
| ['char_set'] The character set used in communicating with the database
|
||||
| ['dbcollat'] The character collation used in communicating with the database
|
||||
| NOTE: For MySQL and MySQLi databases, this setting is only used
|
||||
| as a backup if your server is running PHP < 5.2.3 or MySQL < 5.0.7
|
||||
| (and in table creation queries made with DB Forge).
|
||||
| There is an incompatibility in PHP with mysql_real_escape_string() which
|
||||
| can make your site vulnerable to SQL injection if you are using a
|
||||
| multi-byte character set and are running versions lower than these.
|
||||
| Sites using Latin-1 or UTF-8 database character set and collation are unaffected.
|
||||
| ['swap_pre'] A default table prefix that should be swapped with the dbprefix
|
||||
| ['autoinit'] Whether or not to automatically initialize the database.
|
||||
| ['stricton'] TRUE/FALSE - forces 'Strict Mode' connections
|
||||
| - good for ensuring strict SQL while developing
|
||||
|
|
||||
| The $active_group variable lets you choose which connection group to
|
||||
| make active. By default there is only one group (the 'default' group).
|
||||
|
|
||||
| The $active_record variables lets you determine whether or not to load
|
||||
| the active record class
|
||||
*/
|
||||
|
||||
$active_group = 'default';
|
||||
$active_record = TRUE;
|
||||
|
||||
$db['default']['hostname'] = 'localhost';
|
||||
$db['default']['username'] = 'root';
|
||||
$db['default']['password'] = '';
|
||||
$db['default']['database'] = 'barang';
|
||||
$db['default']['dbdriver'] = 'mysql';
|
||||
$db['default']['dbprefix'] = '';
|
||||
$db['default']['pconnect'] = TRUE;
|
||||
$db['default']['db_debug'] = TRUE;
|
||||
$db['default']['cache_on'] = FALSE;
|
||||
$db['default']['cachedir'] = '';
|
||||
$db['default']['char_set'] = 'utf8';
|
||||
$db['default']['dbcollat'] = 'utf8_general_ci';
|
||||
$db['default']['swap_pre'] = '';
|
||||
$db['default']['autoinit'] = TRUE;
|
||||
$db['default']['stricton'] = FALSE;
|
||||
|
||||
|
||||
/* End of file database.php */
|
||||
/* Location: ./application/config/database.php */
|
15
application/config/doctypes.php
Normal file
15
application/config/doctypes.php
Normal file
@ -0,0 +1,15 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
$_doctypes = array(
|
||||
'xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">',
|
||||
'xhtml1-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">',
|
||||
'xhtml1-trans' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">',
|
||||
'xhtml1-frame' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">',
|
||||
'html5' => '<!DOCTYPE html>',
|
||||
'html4-strict' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">',
|
||||
'html4-trans' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">',
|
||||
'html4-frame' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">'
|
||||
);
|
||||
|
||||
/* End of file doctypes.php */
|
||||
/* Location: ./application/config/doctypes.php */
|
64
application/config/foreign_chars.php
Normal file
64
application/config/foreign_chars.php
Normal file
@ -0,0 +1,64 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| Foreign Characters
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of foreign characters for transliteration
|
||||
| conversion used by the Text helper
|
||||
|
|
||||
*/
|
||||
$foreign_characters = array(
|
||||
'/ä|æ|ǽ/' => 'ae',
|
||||
'/ö|œ/' => 'oe',
|
||||
'/ü/' => 'ue',
|
||||
'/Ä/' => 'Ae',
|
||||
'/Ü/' => 'Ue',
|
||||
'/Ö/' => 'Oe',
|
||||
'/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ/' => 'A',
|
||||
'/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª/' => 'a',
|
||||
'/Ç|Ć|Ĉ|Ċ|Č/' => 'C',
|
||||
'/ç|ć|ĉ|ċ|č/' => 'c',
|
||||
'/Ð|Ď|Đ/' => 'D',
|
||||
'/ð|ď|đ/' => 'd',
|
||||
'/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě/' => 'E',
|
||||
'/è|é|ê|ë|ē|ĕ|ė|ę|ě/' => 'e',
|
||||
'/Ĝ|Ğ|Ġ|Ģ/' => 'G',
|
||||
'/ĝ|ğ|ġ|ģ/' => 'g',
|
||||
'/Ĥ|Ħ/' => 'H',
|
||||
'/ĥ|ħ/' => 'h',
|
||||
'/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ/' => 'I',
|
||||
'/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı/' => 'i',
|
||||
'/Ĵ/' => 'J',
|
||||
'/ĵ/' => 'j',
|
||||
'/Ķ/' => 'K',
|
||||
'/ķ/' => 'k',
|
||||
'/Ĺ|Ļ|Ľ|Ŀ|Ł/' => 'L',
|
||||
'/ĺ|ļ|ľ|ŀ|ł/' => 'l',
|
||||
'/Ñ|Ń|Ņ|Ň/' => 'N',
|
||||
'/ñ|ń|ņ|ň|ʼn/' => 'n',
|
||||
'/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ/' => 'O',
|
||||
'/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º/' => 'o',
|
||||
'/Ŕ|Ŗ|Ř/' => 'R',
|
||||
'/ŕ|ŗ|ř/' => 'r',
|
||||
'/Ś|Ŝ|Ş|Š/' => 'S',
|
||||
'/ś|ŝ|ş|š|ſ/' => 's',
|
||||
'/Ţ|Ť|Ŧ/' => 'T',
|
||||
'/ţ|ť|ŧ/' => 't',
|
||||
'/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ/' => 'U',
|
||||
'/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ/' => 'u',
|
||||
'/Ý|Ÿ|Ŷ/' => 'Y',
|
||||
'/ý|ÿ|ŷ/' => 'y',
|
||||
'/Ŵ/' => 'W',
|
||||
'/ŵ/' => 'w',
|
||||
'/Ź|Ż|Ž/' => 'Z',
|
||||
'/ź|ż|ž/' => 'z',
|
||||
'/Æ|Ǽ/' => 'AE',
|
||||
'/ß/'=> 'ss',
|
||||
'/IJ/' => 'IJ',
|
||||
'/ij/' => 'ij',
|
||||
'/Œ/' => 'OE',
|
||||
'/ƒ/' => 'f'
|
||||
);
|
||||
|
||||
/* End of file foreign_chars.php */
|
||||
/* Location: ./application/config/foreign_chars.php */
|
16
application/config/hooks.php
Normal file
16
application/config/hooks.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Hooks
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you define "hooks" to extend CI without hacking the core
|
||||
| files. Please see the user guide for info:
|
||||
|
|
||||
| http://codeigniter.com/user_guide/general/hooks.html
|
||||
|
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/* End of file hooks.php */
|
||||
/* Location: ./application/config/hooks.php */
|
10
application/config/index.html
Normal file
10
application/config/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
41
application/config/migration.php
Normal file
41
application/config/migration.php
Normal file
@ -0,0 +1,41 @@
|
||||
<?php defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Enable/Disable Migrations
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Migrations are disabled by default but should be enabled
|
||||
| whenever you intend to do a schema migration.
|
||||
|
|
||||
*/
|
||||
$config['migration_enabled'] = FALSE;
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations version
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This is used to set migration version that the file system should be on.
|
||||
| If you run $this->migration->latest() this is the version that schema will
|
||||
| be upgraded / downgraded to.
|
||||
|
|
||||
*/
|
||||
$config['migration_version'] = 0;
|
||||
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Migrations Path
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Path to your migrations folder.
|
||||
| Typically, it will be within your application path.
|
||||
| Also, writing permission is required within the migrations path.
|
||||
|
|
||||
*/
|
||||
$config['migration_path'] = APPPATH . 'migrations/';
|
||||
|
||||
|
||||
/* End of file migration.php */
|
||||
/* Location: ./application/config/migration.php */
|
106
application/config/mimes.php
Normal file
106
application/config/mimes.php
Normal file
@ -0,0 +1,106 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| MIME TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of mime types. It is used by the
|
||||
| Upload class to help identify allowed file types.
|
||||
|
|
||||
*/
|
||||
|
||||
$mimes = array( 'hqx' => 'application/mac-binhex40',
|
||||
'cpt' => 'application/mac-compactpro',
|
||||
'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel'),
|
||||
'bin' => 'application/macbinary',
|
||||
'dms' => 'application/octet-stream',
|
||||
'lha' => 'application/octet-stream',
|
||||
'lzh' => 'application/octet-stream',
|
||||
'exe' => array('application/octet-stream', 'application/x-msdownload'),
|
||||
'class' => 'application/octet-stream',
|
||||
'psd' => 'application/x-photoshop',
|
||||
'so' => 'application/octet-stream',
|
||||
'sea' => 'application/octet-stream',
|
||||
'dll' => 'application/octet-stream',
|
||||
'oda' => 'application/oda',
|
||||
'pdf' => array('application/pdf', 'application/x-download'),
|
||||
'ai' => 'application/postscript',
|
||||
'eps' => 'application/postscript',
|
||||
'ps' => 'application/postscript',
|
||||
'smi' => 'application/smil',
|
||||
'smil' => 'application/smil',
|
||||
'mif' => 'application/vnd.mif',
|
||||
'xls' => array('application/excel', 'application/vnd.ms-excel', 'application/msexcel'),
|
||||
'ppt' => array('application/powerpoint', 'application/vnd.ms-powerpoint'),
|
||||
'wbxml' => 'application/wbxml',
|
||||
'wmlc' => 'application/wmlc',
|
||||
'dcr' => 'application/x-director',
|
||||
'dir' => 'application/x-director',
|
||||
'dxr' => 'application/x-director',
|
||||
'dvi' => 'application/x-dvi',
|
||||
'gtar' => 'application/x-gtar',
|
||||
'gz' => 'application/x-gzip',
|
||||
'php' => 'application/x-httpd-php',
|
||||
'php4' => 'application/x-httpd-php',
|
||||
'php3' => 'application/x-httpd-php',
|
||||
'phtml' => 'application/x-httpd-php',
|
||||
'phps' => 'application/x-httpd-php-source',
|
||||
'js' => 'application/x-javascript',
|
||||
'swf' => 'application/x-shockwave-flash',
|
||||
'sit' => 'application/x-stuffit',
|
||||
'tar' => 'application/x-tar',
|
||||
'tgz' => array('application/x-tar', 'application/x-gzip-compressed'),
|
||||
'xhtml' => 'application/xhtml+xml',
|
||||
'xht' => 'application/xhtml+xml',
|
||||
'zip' => array('application/x-zip', 'application/zip', 'application/x-zip-compressed'),
|
||||
'mid' => 'audio/midi',
|
||||
'midi' => 'audio/midi',
|
||||
'mpga' => 'audio/mpeg',
|
||||
'mp2' => 'audio/mpeg',
|
||||
'mp3' => array('audio/mpeg', 'audio/mpg', 'audio/mpeg3', 'audio/mp3'),
|
||||
'aif' => 'audio/x-aiff',
|
||||
'aiff' => 'audio/x-aiff',
|
||||
'aifc' => 'audio/x-aiff',
|
||||
'ram' => 'audio/x-pn-realaudio',
|
||||
'rm' => 'audio/x-pn-realaudio',
|
||||
'rpm' => 'audio/x-pn-realaudio-plugin',
|
||||
'ra' => 'audio/x-realaudio',
|
||||
'rv' => 'video/vnd.rn-realvideo',
|
||||
'wav' => array('audio/x-wav', 'audio/wave', 'audio/wav'),
|
||||
'bmp' => array('image/bmp', 'image/x-windows-bmp'),
|
||||
'gif' => 'image/gif',
|
||||
'jpeg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpg' => array('image/jpeg', 'image/pjpeg'),
|
||||
'jpe' => array('image/jpeg', 'image/pjpeg'),
|
||||
'png' => array('image/png', 'image/x-png'),
|
||||
'tiff' => 'image/tiff',
|
||||
'tif' => 'image/tiff',
|
||||
'css' => 'text/css',
|
||||
'html' => 'text/html',
|
||||
'htm' => 'text/html',
|
||||
'shtml' => 'text/html',
|
||||
'txt' => 'text/plain',
|
||||
'text' => 'text/plain',
|
||||
'log' => array('text/plain', 'text/x-log'),
|
||||
'rtx' => 'text/richtext',
|
||||
'rtf' => 'text/rtf',
|
||||
'xml' => 'text/xml',
|
||||
'xsl' => 'text/xml',
|
||||
'mpeg' => 'video/mpeg',
|
||||
'mpg' => 'video/mpeg',
|
||||
'mpe' => 'video/mpeg',
|
||||
'qt' => 'video/quicktime',
|
||||
'mov' => 'video/quicktime',
|
||||
'avi' => 'video/x-msvideo',
|
||||
'movie' => 'video/x-sgi-movie',
|
||||
'doc' => 'application/msword',
|
||||
'docx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip'),
|
||||
'xlsx' => array('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'application/zip'),
|
||||
'word' => array('application/msword', 'application/octet-stream'),
|
||||
'xl' => 'application/excel',
|
||||
'eml' => 'message/rfc822',
|
||||
'json' => array('application/json', 'text/json')
|
||||
);
|
||||
|
||||
|
||||
/* End of file mimes.php */
|
||||
/* Location: ./application/config/mimes.php */
|
17
application/config/profiler.php
Normal file
17
application/config/profiler.php
Normal file
@ -0,0 +1,17 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| Profiler Sections
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you determine whether or not various sections of Profiler
|
||||
| data are displayed when the Profiler is enabled.
|
||||
| Please see the user guide for info:
|
||||
|
|
||||
| http://codeigniter.com/user_guide/general/profiling.html
|
||||
|
|
||||
*/
|
||||
|
||||
|
||||
|
||||
/* End of file profiler.php */
|
||||
/* Location: ./application/config/profiler.php */
|
46
application/config/routes.php
Normal file
46
application/config/routes.php
Normal file
@ -0,0 +1,46 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------------
|
||||
| URI ROUTING
|
||||
| -------------------------------------------------------------------------
|
||||
| This file lets you re-map URI requests to specific controller functions.
|
||||
|
|
||||
| Typically there is a one-to-one relationship between a URL string
|
||||
| and its corresponding controller class/method. The segments in a
|
||||
| URL normally follow this pattern:
|
||||
|
|
||||
| example.com/class/method/id/
|
||||
|
|
||||
| In some instances, however, you may want to remap this relationship
|
||||
| so that a different class/function is called than the one
|
||||
| corresponding to the URL.
|
||||
|
|
||||
| Please see the user guide for complete details:
|
||||
|
|
||||
| http://codeigniter.com/user_guide/general/routing.html
|
||||
|
|
||||
| -------------------------------------------------------------------------
|
||||
| RESERVED ROUTES
|
||||
| -------------------------------------------------------------------------
|
||||
|
|
||||
| There area two reserved routes:
|
||||
|
|
||||
| $route['default_controller'] = 'welcome';
|
||||
|
|
||||
| This route indicates which controller class should be loaded if the
|
||||
| URI contains no data. In the above example, the "welcome" class
|
||||
| would be loaded.
|
||||
|
|
||||
| $route['404_override'] = 'errors/page_missing';
|
||||
|
|
||||
| This route will tell the Router what URI segments to use if those provided
|
||||
| in the URL cannot be matched to a valid route.
|
||||
|
|
||||
*/
|
||||
|
||||
$route['default_controller'] = "welcome";
|
||||
$route['404_override'] = '';
|
||||
|
||||
|
||||
/* End of file routes.php */
|
||||
/* Location: ./application/config/routes.php */
|
66
application/config/smileys.php
Normal file
66
application/config/smileys.php
Normal file
@ -0,0 +1,66 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| SMILEYS
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains an array of smileys for use with the emoticon helper.
|
||||
| Individual images can be used to replace multiple simileys. For example:
|
||||
| :-) and :) use the same image replacement.
|
||||
|
|
||||
| Please see user guide for more info:
|
||||
| http://codeigniter.com/user_guide/helpers/smiley_helper.html
|
||||
|
|
||||
*/
|
||||
|
||||
$smileys = array(
|
||||
|
||||
// smiley image name width height alt
|
||||
|
||||
':-)' => array('grin.gif', '19', '19', 'grin'),
|
||||
':lol:' => array('lol.gif', '19', '19', 'LOL'),
|
||||
':cheese:' => array('cheese.gif', '19', '19', 'cheese'),
|
||||
':)' => array('smile.gif', '19', '19', 'smile'),
|
||||
';-)' => array('wink.gif', '19', '19', 'wink'),
|
||||
';)' => array('wink.gif', '19', '19', 'wink'),
|
||||
':smirk:' => array('smirk.gif', '19', '19', 'smirk'),
|
||||
':roll:' => array('rolleyes.gif', '19', '19', 'rolleyes'),
|
||||
':-S' => array('confused.gif', '19', '19', 'confused'),
|
||||
':wow:' => array('surprise.gif', '19', '19', 'surprised'),
|
||||
':bug:' => array('bigsurprise.gif', '19', '19', 'big surprise'),
|
||||
':-P' => array('tongue_laugh.gif', '19', '19', 'tongue laugh'),
|
||||
'%-P' => array('tongue_rolleye.gif', '19', '19', 'tongue rolleye'),
|
||||
';-P' => array('tongue_wink.gif', '19', '19', 'tongue wink'),
|
||||
':P' => array('raspberry.gif', '19', '19', 'raspberry'),
|
||||
':blank:' => array('blank.gif', '19', '19', 'blank stare'),
|
||||
':long:' => array('longface.gif', '19', '19', 'long face'),
|
||||
':ohh:' => array('ohh.gif', '19', '19', 'ohh'),
|
||||
':grrr:' => array('grrr.gif', '19', '19', 'grrr'),
|
||||
':gulp:' => array('gulp.gif', '19', '19', 'gulp'),
|
||||
'8-/' => array('ohoh.gif', '19', '19', 'oh oh'),
|
||||
':down:' => array('downer.gif', '19', '19', 'downer'),
|
||||
':red:' => array('embarrassed.gif', '19', '19', 'red face'),
|
||||
':sick:' => array('sick.gif', '19', '19', 'sick'),
|
||||
':shut:' => array('shuteye.gif', '19', '19', 'shut eye'),
|
||||
':-/' => array('hmm.gif', '19', '19', 'hmmm'),
|
||||
'>:(' => array('mad.gif', '19', '19', 'mad'),
|
||||
':mad:' => array('mad.gif', '19', '19', 'mad'),
|
||||
'>:-(' => array('angry.gif', '19', '19', 'angry'),
|
||||
':angry:' => array('angry.gif', '19', '19', 'angry'),
|
||||
':zip:' => array('zip.gif', '19', '19', 'zipper'),
|
||||
':kiss:' => array('kiss.gif', '19', '19', 'kiss'),
|
||||
':ahhh:' => array('shock.gif', '19', '19', 'shock'),
|
||||
':coolsmile:' => array('shade_smile.gif', '19', '19', 'cool smile'),
|
||||
':coolsmirk:' => array('shade_smirk.gif', '19', '19', 'cool smirk'),
|
||||
':coolgrin:' => array('shade_grin.gif', '19', '19', 'cool grin'),
|
||||
':coolhmm:' => array('shade_hmm.gif', '19', '19', 'cool hmm'),
|
||||
':coolmad:' => array('shade_mad.gif', '19', '19', 'cool mad'),
|
||||
':coolcheese:' => array('shade_cheese.gif', '19', '19', 'cool cheese'),
|
||||
':vampire:' => array('vampire.gif', '19', '19', 'vampire'),
|
||||
':snake:' => array('snake.gif', '19', '19', 'snake'),
|
||||
':exclaim:' => array('exclaim.gif', '19', '19', 'excaim'),
|
||||
':question:' => array('question.gif', '19', '19', 'question') // no comma after last item
|
||||
|
||||
);
|
||||
|
||||
/* End of file smileys.php */
|
||||
/* Location: ./application/config/smileys.php */
|
178
application/config/user_agents.php
Normal file
178
application/config/user_agents.php
Normal file
@ -0,0 +1,178 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
/*
|
||||
| -------------------------------------------------------------------
|
||||
| USER AGENT TYPES
|
||||
| -------------------------------------------------------------------
|
||||
| This file contains four arrays of user agent data. It is used by the
|
||||
| User Agent Class to help identify browser, platform, robot, and
|
||||
| mobile device data. The array keys are used to identify the device
|
||||
| and the array values are used to set the actual name of the item.
|
||||
|
|
||||
*/
|
||||
|
||||
$platforms = array (
|
||||
'windows nt 6.0' => 'Windows Longhorn',
|
||||
'windows nt 5.2' => 'Windows 2003',
|
||||
'windows nt 5.0' => 'Windows 2000',
|
||||
'windows nt 5.1' => 'Windows XP',
|
||||
'windows nt 4.0' => 'Windows NT 4.0',
|
||||
'winnt4.0' => 'Windows NT 4.0',
|
||||
'winnt 4.0' => 'Windows NT',
|
||||
'winnt' => 'Windows NT',
|
||||
'windows 98' => 'Windows 98',
|
||||
'win98' => 'Windows 98',
|
||||
'windows 95' => 'Windows 95',
|
||||
'win95' => 'Windows 95',
|
||||
'windows' => 'Unknown Windows OS',
|
||||
'os x' => 'Mac OS X',
|
||||
'ppc mac' => 'Power PC Mac',
|
||||
'freebsd' => 'FreeBSD',
|
||||
'ppc' => 'Macintosh',
|
||||
'linux' => 'Linux',
|
||||
'debian' => 'Debian',
|
||||
'sunos' => 'Sun Solaris',
|
||||
'beos' => 'BeOS',
|
||||
'apachebench' => 'ApacheBench',
|
||||
'aix' => 'AIX',
|
||||
'irix' => 'Irix',
|
||||
'osf' => 'DEC OSF',
|
||||
'hp-ux' => 'HP-UX',
|
||||
'netbsd' => 'NetBSD',
|
||||
'bsdi' => 'BSDi',
|
||||
'openbsd' => 'OpenBSD',
|
||||
'gnu' => 'GNU/Linux',
|
||||
'unix' => 'Unknown Unix OS'
|
||||
);
|
||||
|
||||
|
||||
// The order of this array should NOT be changed. Many browsers return
|
||||
// multiple browser types so we want to identify the sub-type first.
|
||||
$browsers = array(
|
||||
'Flock' => 'Flock',
|
||||
'Chrome' => 'Chrome',
|
||||
'Opera' => 'Opera',
|
||||
'MSIE' => 'Internet Explorer',
|
||||
'Internet Explorer' => 'Internet Explorer',
|
||||
'Shiira' => 'Shiira',
|
||||
'Firefox' => 'Firefox',
|
||||
'Chimera' => 'Chimera',
|
||||
'Phoenix' => 'Phoenix',
|
||||
'Firebird' => 'Firebird',
|
||||
'Camino' => 'Camino',
|
||||
'Netscape' => 'Netscape',
|
||||
'OmniWeb' => 'OmniWeb',
|
||||
'Safari' => 'Safari',
|
||||
'Mozilla' => 'Mozilla',
|
||||
'Konqueror' => 'Konqueror',
|
||||
'icab' => 'iCab',
|
||||
'Lynx' => 'Lynx',
|
||||
'Links' => 'Links',
|
||||
'hotjava' => 'HotJava',
|
||||
'amaya' => 'Amaya',
|
||||
'IBrowse' => 'IBrowse'
|
||||
);
|
||||
|
||||
$mobiles = array(
|
||||
// legacy array, old values commented out
|
||||
'mobileexplorer' => 'Mobile Explorer',
|
||||
// 'openwave' => 'Open Wave',
|
||||
// 'opera mini' => 'Opera Mini',
|
||||
// 'operamini' => 'Opera Mini',
|
||||
// 'elaine' => 'Palm',
|
||||
'palmsource' => 'Palm',
|
||||
// 'digital paths' => 'Palm',
|
||||
// 'avantgo' => 'Avantgo',
|
||||
// 'xiino' => 'Xiino',
|
||||
'palmscape' => 'Palmscape',
|
||||
// 'nokia' => 'Nokia',
|
||||
// 'ericsson' => 'Ericsson',
|
||||
// 'blackberry' => 'BlackBerry',
|
||||
// 'motorola' => 'Motorola'
|
||||
|
||||
// Phones and Manufacturers
|
||||
'motorola' => "Motorola",
|
||||
'nokia' => "Nokia",
|
||||
'palm' => "Palm",
|
||||
'iphone' => "Apple iPhone",
|
||||
'ipad' => "iPad",
|
||||
'ipod' => "Apple iPod Touch",
|
||||
'sony' => "Sony Ericsson",
|
||||
'ericsson' => "Sony Ericsson",
|
||||
'blackberry' => "BlackBerry",
|
||||
'cocoon' => "O2 Cocoon",
|
||||
'blazer' => "Treo",
|
||||
'lg' => "LG",
|
||||
'amoi' => "Amoi",
|
||||
'xda' => "XDA",
|
||||
'mda' => "MDA",
|
||||
'vario' => "Vario",
|
||||
'htc' => "HTC",
|
||||
'samsung' => "Samsung",
|
||||
'sharp' => "Sharp",
|
||||
'sie-' => "Siemens",
|
||||
'alcatel' => "Alcatel",
|
||||
'benq' => "BenQ",
|
||||
'ipaq' => "HP iPaq",
|
||||
'mot-' => "Motorola",
|
||||
'playstation portable' => "PlayStation Portable",
|
||||
'hiptop' => "Danger Hiptop",
|
||||
'nec-' => "NEC",
|
||||
'panasonic' => "Panasonic",
|
||||
'philips' => "Philips",
|
||||
'sagem' => "Sagem",
|
||||
'sanyo' => "Sanyo",
|
||||
'spv' => "SPV",
|
||||
'zte' => "ZTE",
|
||||
'sendo' => "Sendo",
|
||||
|
||||
// Operating Systems
|
||||
'symbian' => "Symbian",
|
||||
'SymbianOS' => "SymbianOS",
|
||||
'elaine' => "Palm",
|
||||
'palm' => "Palm",
|
||||
'series60' => "Symbian S60",
|
||||
'windows ce' => "Windows CE",
|
||||
|
||||
// Browsers
|
||||
'obigo' => "Obigo",
|
||||
'netfront' => "Netfront Browser",
|
||||
'openwave' => "Openwave Browser",
|
||||
'mobilexplorer' => "Mobile Explorer",
|
||||
'operamini' => "Opera Mini",
|
||||
'opera mini' => "Opera Mini",
|
||||
|
||||
// Other
|
||||
'digital paths' => "Digital Paths",
|
||||
'avantgo' => "AvantGo",
|
||||
'xiino' => "Xiino",
|
||||
'novarra' => "Novarra Transcoder",
|
||||
'vodafone' => "Vodafone",
|
||||
'docomo' => "NTT DoCoMo",
|
||||
'o2' => "O2",
|
||||
|
||||
// Fallback
|
||||
'mobile' => "Generic Mobile",
|
||||
'wireless' => "Generic Mobile",
|
||||
'j2me' => "Generic Mobile",
|
||||
'midp' => "Generic Mobile",
|
||||
'cldc' => "Generic Mobile",
|
||||
'up.link' => "Generic Mobile",
|
||||
'up.browser' => "Generic Mobile",
|
||||
'smartphone' => "Generic Mobile",
|
||||
'cellphone' => "Generic Mobile"
|
||||
);
|
||||
|
||||
// There are hundreds of bots but these are the most common.
|
||||
$robots = array(
|
||||
'googlebot' => 'Googlebot',
|
||||
'msnbot' => 'MSNBot',
|
||||
'slurp' => 'Inktomi Slurp',
|
||||
'yahoo' => 'Yahoo',
|
||||
'askjeeves' => 'AskJeeves',
|
||||
'fastcrawler' => 'FastCrawler',
|
||||
'infoseek' => 'InfoSeek Robot 1.0',
|
||||
'lycos' => 'Lycos'
|
||||
);
|
||||
|
||||
/* End of file user_agents.php */
|
||||
/* Location: ./application/config/user_agents.php */
|
65
application/controllers/barang_controller.php
Normal file
65
application/controllers/barang_controller.php
Normal file
@ -0,0 +1,65 @@
|
||||
<?php
|
||||
class barang_controller extends CI_Controller{
|
||||
|
||||
function __Construct()
|
||||
{
|
||||
parent ::__construct();
|
||||
$this->load->helper(array('form', 'url'));
|
||||
$this->load->library('form_validation');
|
||||
$this->load->model('barang_model');
|
||||
}
|
||||
|
||||
function barang()
|
||||
{
|
||||
if( $this->session->userdata('isLoggedIn') ) {
|
||||
$this->load->model('barang_model');
|
||||
$data['judul'] = 'Tampil barang';
|
||||
$data['daftar_barang'] = $this->barang_model->get_barang_all();
|
||||
$this->load->view('HalamanUtama', $data);
|
||||
} else {
|
||||
redirect('user_controller/login');
|
||||
}
|
||||
}
|
||||
|
||||
function add_Barang()
|
||||
{
|
||||
$data['judul'] = 'Tambah Barang';
|
||||
$this->load->view('add_barang',$data);
|
||||
}
|
||||
|
||||
function simpan_barang()
|
||||
{
|
||||
$this->barang_model->simpan_barang();
|
||||
redirect('barang_controller/barang','refresh');
|
||||
}
|
||||
|
||||
function edit($id)
|
||||
{
|
||||
$data['judul']='Update Barang';
|
||||
$data['edit']=$this->barang_model->update_barang($id);
|
||||
$this->load->view('edit_barang', $data);
|
||||
}
|
||||
|
||||
function simpan_update_barang()
|
||||
{
|
||||
$id = $this->input->post('id');
|
||||
$nama = $this->input->post('nama_barang');
|
||||
$harga = $this->input->post('harga');
|
||||
|
||||
$data['judul'] = 'Update Data Codeigniter';
|
||||
$this->load->model('user_model');
|
||||
$data['edit'] = $this->barang_model->simpan_update_barang($id, $nama, $harga);
|
||||
echo ("<SCRIPT LANGUAGE='JavaScript'>
|
||||
window.alert('Succesfully Updated')
|
||||
</SCRIPT>");
|
||||
redirect('barang_controller/barang','refresh');
|
||||
|
||||
}
|
||||
function delete($id)
|
||||
{
|
||||
$id = $this->barang_model->delete_barang($id);
|
||||
|
||||
redirect('barang_controller/barang');
|
||||
}
|
||||
|
||||
}
|
10
application/controllers/index.html
Normal file
10
application/controllers/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
62
application/controllers/user_controller.php
Normal file
62
application/controllers/user_controller.php
Normal file
@ -0,0 +1,62 @@
|
||||
<?php
|
||||
class User_controller extends CI_Controller{
|
||||
|
||||
function __Construct()
|
||||
{
|
||||
parent ::__construct();
|
||||
$this->load->model('user_model');
|
||||
}
|
||||
|
||||
function insert_user()
|
||||
{
|
||||
$data['judul'] = 'Insert Data User';
|
||||
$this->load->view('user', $data);
|
||||
}
|
||||
|
||||
function simpan_user()
|
||||
{
|
||||
$this->user_model->simpan_user();
|
||||
$data['notifikasi'] = 'Data berhasil disimpan';
|
||||
$data['judul']='Insert Data Berhasil';
|
||||
}
|
||||
|
||||
function login()
|
||||
{
|
||||
$data['judul'] = 'Halaman Login';
|
||||
$this->load->view('login', $data);
|
||||
}
|
||||
|
||||
function validasi()
|
||||
{
|
||||
$user = $this->input->post('username');
|
||||
$pass = $this->input->post('password');
|
||||
$cek = $this->user_model->login($user,$pass);
|
||||
//echo $cek;
|
||||
if ($cek)
|
||||
{
|
||||
$session = array(
|
||||
'username' => $user,
|
||||
'isLoggedIn' => TRUE
|
||||
);
|
||||
|
||||
$this->session->set_userdata($session);
|
||||
redirect('barang_controller/barang');
|
||||
echo $this->session->all_userdata();
|
||||
}
|
||||
else {
|
||||
|
||||
$this->load->view('login');
|
||||
//echo 'salah';
|
||||
}
|
||||
}
|
||||
function logout()
|
||||
{
|
||||
$array_items = array('username' => '', 'isLoggedin' => false);
|
||||
$this->session->unset_userdata($array_items);
|
||||
$this->session->sess_destroy();
|
||||
//$session_destroy();
|
||||
$data['judul'] = 'Halaman Login';
|
||||
$this->load->view('login', $data);
|
||||
}
|
||||
}
|
||||
?>
|
35
application/controllers/welcome.php
Normal file
35
application/controllers/welcome.php
Normal file
@ -0,0 +1,35 @@
|
||||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Welcome extends CI_Controller {
|
||||
|
||||
/**
|
||||
* Index Page for this controller.
|
||||
*
|
||||
* Maps to the following URL
|
||||
* http://example.com/index.php/welcome
|
||||
* - or -
|
||||
* http://example.com/index.php/welcome/index
|
||||
* - or -
|
||||
* Since this controller is set as the default controller in
|
||||
* config/routes.php, it's displayed at http://example.com/
|
||||
*
|
||||
* So any other public methods not prefixed with an underscore will
|
||||
* map to /index.php/welcome/<method_name>
|
||||
* @see http://codeigniter.com/user_guide/general/urls.html
|
||||
*/
|
||||
|
||||
|
||||
public function index()
|
||||
{
|
||||
$this->load->view('welcome_message');
|
||||
}
|
||||
|
||||
public function login()
|
||||
{
|
||||
$data['judul'] = 'Halaman Login';
|
||||
$this->load->view('login', $data);
|
||||
}
|
||||
}
|
||||
|
||||
/* End of file welcome.php */
|
||||
/* Location: ./application/controllers/welcome.php */
|
10
application/core/index.html
Normal file
10
application/core/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
62
application/errors/error_404.php
Normal file
62
application/errors/error_404.php
Normal file
@ -0,0 +1,62 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>404 Page Not Found</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection{ background-color: #E13300; color: white; }
|
||||
::moz-selection{ background-color: #E13300; color: white; }
|
||||
::webkit-selection{ background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
-webkit-box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
62
application/errors/error_db.php
Normal file
62
application/errors/error_db.php
Normal file
@ -0,0 +1,62 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Database Error</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection{ background-color: #E13300; color: white; }
|
||||
::moz-selection{ background-color: #E13300; color: white; }
|
||||
::webkit-selection{ background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
-webkit-box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
62
application/errors/error_general.php
Normal file
62
application/errors/error_general.php
Normal file
@ -0,0 +1,62 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<title>Error</title>
|
||||
<style type="text/css">
|
||||
|
||||
::selection{ background-color: #E13300; color: white; }
|
||||
::moz-selection{ background-color: #E13300; color: white; }
|
||||
::webkit-selection{ background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#container {
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
-webkit-box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
|
||||
p {
|
||||
margin: 12px 15px 12px 15px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div id="container">
|
||||
<h1><?php echo $heading; ?></h1>
|
||||
<?php echo $message; ?>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
10
application/errors/error_php.php
Normal file
10
application/errors/error_php.php
Normal file
@ -0,0 +1,10 @@
|
||||
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: <?php echo $severity; ?></p>
|
||||
<p>Message: <?php echo $message; ?></p>
|
||||
<p>Filename: <?php echo $filepath; ?></p>
|
||||
<p>Line Number: <?php echo $line; ?></p>
|
||||
|
||||
</div>
|
10
application/errors/index.html
Normal file
10
application/errors/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/helpers/index.html
Normal file
10
application/helpers/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/hooks/index.html
Normal file
10
application/hooks/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/index.html
Normal file
10
application/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/language/english/index.html
Normal file
10
application/language/english/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/libraries/index.html
Normal file
10
application/libraries/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
10
application/logs/index.html
Normal file
10
application/logs/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
39
application/models/barang_model.php
Normal file
39
application/models/barang_model.php
Normal file
@ -0,0 +1,39 @@
|
||||
<?php
|
||||
class barang_model extends CI_Model{
|
||||
|
||||
function get_barang_all()
|
||||
{
|
||||
$query=$this->db->query("SELECT * FROM barang ORDER BY id DESC");
|
||||
return $query->result();
|
||||
}
|
||||
function update_barang($id)
|
||||
{
|
||||
$q="SELECT * FROM barang WHERE id='$id'";
|
||||
$query=$this->db->query($q);
|
||||
return $query->row();
|
||||
}
|
||||
function simpan_update_barang($id, $nama, $harga)
|
||||
{
|
||||
$data = array(
|
||||
'id' => $id,
|
||||
'nama' => $nama,
|
||||
'harga' => $harga
|
||||
);
|
||||
$this->db->where('id', $id);
|
||||
$this->db->update('barang', $data);
|
||||
}
|
||||
function delete_barang($id)
|
||||
{
|
||||
$query=$this->db->query("DELETE FROM barang WHERE id='$id'");
|
||||
}
|
||||
function simpan_barang()
|
||||
{
|
||||
$simpan_data=array(
|
||||
'nama' => $this->input->post('nama_barang'),
|
||||
'harga' => $this->input->post('harga'),
|
||||
);
|
||||
$simpan = $this->db->insert('barang', $simpan_data);
|
||||
return $simpan;
|
||||
redirect('barang_controller/barang','refresh');
|
||||
}
|
||||
}
|
10
application/models/index.html
Normal file
10
application/models/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
24
application/models/user_model.php
Normal file
24
application/models/user_model.php
Normal file
@ -0,0 +1,24 @@
|
||||
<?php
|
||||
class User_model extends CI_Model{
|
||||
|
||||
function simpan_user()
|
||||
{
|
||||
$simpan_data=array(
|
||||
'nama_lengkap' => $this->input->post('nama_lengkap'),
|
||||
'username' => $this->input->post('username'),
|
||||
'password' => md5($this->input->post('password')),
|
||||
'email' => $this->input->post('email'),
|
||||
'alamat' => $this->input->post('alamat')
|
||||
);
|
||||
$simpan = $this->db->insert('user', $simpan_data);
|
||||
return $simpan;
|
||||
}
|
||||
function login($user,$pass)
|
||||
{
|
||||
$pass = md5($pass);
|
||||
$sql1 = "SELECT * FROM USER WHERE username = '$user' AND password = '$pass'";
|
||||
$rs = mysql_query($sql1);
|
||||
$r = mysql_num_rows($rs);
|
||||
if ($r=='1'){return true;}
|
||||
}
|
||||
}
|
10
application/third_party/index.html
vendored
Normal file
10
application/third_party/index.html
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
68
application/views/HalamanUtama.php
Normal file
68
application/views/HalamanUtama.php
Normal file
@ -0,0 +1,68 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../css/css2.css">
|
||||
<script>
|
||||
function myFunction(id)
|
||||
{
|
||||
var url="<?php echo base_url();?>";
|
||||
var r=confirm("Do you want to delete this?");
|
||||
if (r==true)
|
||||
{
|
||||
window.location = url+"index.php/barang_controller/delete/"+id;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="../../image/Untitled-2.png"class="img" />
|
||||
<a href="<?php echo base_url().'index.php/user_controller/logout'; ?>" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li id="menuchoosen"><a href="">Dashboard</a></li>
|
||||
<li id="menuunchoosen"><a href="add_barang">Tambah Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Data Barang</p>
|
||||
<table class="tabel" width=700 >
|
||||
<tr>
|
||||
<th>Nama Barang</th>
|
||||
<th>Harga Barang</th>
|
||||
<th colspan="2">Aksi</th>
|
||||
</tr>
|
||||
<tbody>
|
||||
<?php
|
||||
foreach($daftar_barang as $barang){
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $barang->nama; ?></td>
|
||||
<td><?php echo $barang->harga; ?></td>
|
||||
<td><?php echo '<a href="'.base_url().'index.php/barang_controller/edit/'.$barang->id.'"><button id="bt">Edit</button></a>' ?>
|
||||
<button id="bt" onclick="myFunction(<?php echo $barang->id;?>)">Delete</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
50
application/views/add_barang.php
Normal file
50
application/views/add_barang.php
Normal file
@ -0,0 +1,50 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../css/css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="image/Untitled-2.png"class="img" />
|
||||
<a href="" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="<?php echo base_url().'index.php/barang_controller/barang'; ?>">Dashboard</a></li>
|
||||
<li><a href="">Tambah Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Tambah Data</p></div>
|
||||
<form action="http://localhost/cirestful/api/barang/add_barang" method="post">
|
||||
<table class="add" cellspacing="20">
|
||||
<tr>
|
||||
<td>Nama Barang</td>
|
||||
<td colspan="3"><input type="text" name="nama_barang" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Harga</td>
|
||||
<td colspan="3"><input type="text" name="harga" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr><td></td>
|
||||
<td></td>
|
||||
<td><input type="submit" name="submit" value="Simpan"/></td>
|
||||
<td><button type="button" name="Cancel" value="OK">Cancel</button></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
53
application/views/edit_barang.php
Normal file
53
application/views/edit_barang.php
Normal file
@ -0,0 +1,53 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>css/css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="image/Untitled-2.png"class="img" />
|
||||
<a href="<?php echo base_url().'index.php/user_controller/logout'; ?>" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li id="menuunchoosen"><a href="<?php echo base_url().'index.php/barang_controller/barang'; ?>">Dashboard</a></li>
|
||||
<li id="menuchoosen"><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<?php
|
||||
$att = array('id' => 'biodata-form');
|
||||
echo form_open('barang_controller/simpan_update_barang', $att);
|
||||
echo form_hidden('id',$edit->id);
|
||||
?>
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Edit Data</p></div>
|
||||
<table class="add" cellspacing="20">
|
||||
<tr>
|
||||
<td>Nama Barang</td>
|
||||
<td colspan="3"><input type="text" name="nama_barang" value="<?php echo $edit->nama; ?>" class="input"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Harga</td>
|
||||
<td colspan="3"><input type="text" name="harga" value="<?php echo $edit->harga; ?>" class="input"/></td>
|
||||
</tr>
|
||||
<tr><td></td>
|
||||
<td></td>
|
||||
<td><input type="submit" name="submit" value="Simpan"/></td>
|
||||
<td><button type="button" name="Cancel" value="OK">Cancel</button></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
10
application/views/index.html
Normal file
10
application/views/index.html
Normal file
@ -0,0 +1,10 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>403 Forbidden</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<p>Directory access is forbidden.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
53
application/views/login.php
Normal file
53
application/views/login.php
Normal file
@ -0,0 +1,53 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Login Form</title>
|
||||
|
||||
<link href="../../css/style.css" rel="stylesheet" type="text/css" />
|
||||
|
||||
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div id="wrapper">
|
||||
|
||||
|
||||
<div class="user-icon"></div>
|
||||
<div class="pass-icon"></div>
|
||||
|
||||
|
||||
|
||||
<form name="loginform" class="form" action="validasi" method="post">
|
||||
|
||||
|
||||
<div class="header">
|
||||
<h1>Login</h1>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="content">
|
||||
<p>Email</p>
|
||||
<input name="username" type="text" class="input" value="Username" onfocus="{this.value = '';}" onblur="if (this.value == '') {this.value = 'Username';}"/> <br /><br />
|
||||
<p>Password</p>
|
||||
<input name="password" type="password" class="input" value="Password" onfocus="{this.value = '';}" onblur="if (this.value == '') {this.value = 'Password'}" />
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="footer">
|
||||
<input type="submit" name="submit" value="Login" class="button" />
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
55
application/views/tes/HalamanUtama.php
Normal file
55
application/views/tes/HalamanUtama.php
Normal file
@ -0,0 +1,55 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title><?php echo $judul; ?></title>
|
||||
<link href="../../css/barang.css" rel="stylesheet" type="text/css" />
|
||||
<script>
|
||||
function myFunction(id)
|
||||
{
|
||||
var url="<?php echo base_url();?>";
|
||||
var r=confirm("Do you want to delete this?");
|
||||
if (r==true)
|
||||
{
|
||||
window.location = url+"index.php/barang_controller/delete/"+id;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
</head>
|
||||
<body class="bg">
|
||||
<div class="content">
|
||||
<a href="<?php echo base_url().'index.php/user_controller/logout'; ?>">Logout</a>
|
||||
<div class="barang">
|
||||
<h3>Daftar Barang</h3>
|
||||
<table border="5">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Nama Barang</th>
|
||||
<th>Harga</th>
|
||||
<th>Action</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
foreach($daftar_barang as $barang){
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $barang->nama; ?></td>
|
||||
<td><?php echo $barang->harga; ?></td>
|
||||
<td><?php echo '<a href="'.base_url().'index.php/barang_controller/edit/'.$barang->id.'"><button id="bt">Edit</button></a>' ?>
|
||||
<button id="bt" onclick="myFunction(<?php echo $barang->id;?>)">Delete</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
53
application/views/tes/View_login.php
Normal file
53
application/views/tes/View_login.php
Normal file
@ -0,0 +1,53 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Login Form</title>
|
||||
|
||||
<link href="style.css" rel="stylesheet" type="text/css" />
|
||||
|
||||
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div id="wrapper">
|
||||
|
||||
|
||||
<div class="user-icon"></div>
|
||||
<div class="pass-icon"></div>
|
||||
|
||||
|
||||
|
||||
<form name="loginform" class="form" action="validasi" method="post">
|
||||
|
||||
|
||||
<div class="header">
|
||||
<h1>Login</h1>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="content">
|
||||
<p>Email</p>
|
||||
<input name="username" type="text" class="input" value="email" onfocus="[this.value='']"/> <br /><br />
|
||||
<p>Password</p>
|
||||
<input name="password" type="password" class="input" value="Password" onfocus="[this.value='']" />
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="footer">
|
||||
<input type="submit" name="submit" value="Login" class="button" />
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
BIN
application/views/tes/image/Untitled-3.png
Normal file
BIN
application/views/tes/image/Untitled-3.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.0 KiB |
38
application/views/tes/login.php
Normal file
38
application/views/tes/login.php
Normal file
@ -0,0 +1,38 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Login</title>
|
||||
<link href="../../css/login.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body class="bg">
|
||||
<div class="login">
|
||||
<!--
|
||||
<h1 style="padding-left:20px;padding-top:30px">Login</h1>
|
||||
<form action="validasi" method="post">
|
||||
<table width="390" style="padding-left:15px;border-spacing:10px">
|
||||
<tr><td width="70"><a3>Username</a3></td><td width="3">:</td><td width="144"><input type="text" name="username" /></td></tr>
|
||||
<tr><td><a3>Password</a3></td><td>:</td><td><input type="password" name="password" /></td></tr>
|
||||
<tr><td></td></td><td></td><td width="151" style="padding-left:100px"><input type="submit" name="login" onclick="halo" /></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
-->
|
||||
<form id="form1" action="validasi" method="post">
|
||||
|
||||
<fieldset>
|
||||
<legend><h3 style="font-family:'Palatino Linotype', 'Book Antiqua', Palatino, serif">Login</h3></legend>
|
||||
<table width="200" style="border-spacing:10px;margin-left:10%">
|
||||
<tr>
|
||||
<td><input type="text" name="username" value="Username" onfocus="{this.value = '';}" onblur="if (this.value == '') {this.value = 'Username';}"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><input type="password" name="password" value="password" onfocus="{this.value = '';}" onblur="if (this.value == '') {this.value = 'Password';}/></td>
|
||||
<tr>
|
||||
<td colspan="2"><p class="submit"><button type="submit">Login</button></p><td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
29
application/views/tes/v_admin.dwt
Normal file
29
application/views/tes/v_admin.dwt
Normal file
@ -0,0 +1,29 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="css2.css">
|
||||
|
||||
</style></head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"></a>
|
||||
</div>
|
||||
|
||||
<div class="header2"></a>
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<br />
|
||||
<ul class="nav">
|
||||
<li><a href="">Kelola Data Admin</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
28
application/views/tes/v_admin.php
Normal file
28
application/views/tes/v_admin.php
Normal file
@ -0,0 +1,28 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><a href="v_admin.php"><img src="image/Untitled-3.png" /></a>
|
||||
</div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
118
application/views/tes/v_admin_contoh.php
Normal file
118
application/views/tes/v_admin_contoh.php
Normal file
@ -0,0 +1,118 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Admin Pemesanan Tiket</title>
|
||||
|
||||
<base href="<?php echo base_url() ?>" />
|
||||
|
||||
<link type="text/css" rel="stylesheet" href="file:///C|/wamp/www/tiket_rai/application/views/admin/css/smoothness/jquery-ui-1.8.2.custom.css" />
|
||||
<link type="text/css" rel="stylesheet" href="styles.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="ajaxLoadAni">
|
||||
<img src="file:///C|/wamp/www/tiket_rai/application/views/admin/images/ajax-loader.gif" alt="Ajax Loading Animation" />
|
||||
<span>Loading...</span>
|
||||
</div>
|
||||
<center><h1>List Admin</h1></center>
|
||||
<div id="tabs">
|
||||
|
||||
<ul>
|
||||
<li><a href="#read">List Admin</a></li>
|
||||
<li><a href="#create">Admin Baru</a></li>
|
||||
</ul>
|
||||
|
||||
<div id="read">
|
||||
<div class="testing"></div>
|
||||
<table id="records">
|
||||
<thead>
|
||||
<tr>
|
||||
<td>ID Admin</td><td>Nama Admin</td><td>Email</td><td>Aksi</td>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
<div id="create">
|
||||
<form action="http://localhost/tiket_rai/index.php/admin/admin/insert" method="post">
|
||||
<table>
|
||||
<tr>
|
||||
<td width="300px"><label for="id_admin">ID Admin</label></td>
|
||||
<td><input type="text" name="id_admin" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><label for="nama_admin">Nama</label></td>
|
||||
<td><input type="text" name="nama_admin" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><label for="email">Email</label></td>
|
||||
<td><input type="text" name="email" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><label for="sandi">Sandi</label></td>
|
||||
<td><input type="password" name="sandi" /></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<td><input type="submit" value="Tambah"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</div> <!-- end tabs -->
|
||||
|
||||
<!-- update form in dialog box -->
|
||||
<div id="updateDialog" title="Update">
|
||||
<div>
|
||||
<form action="" method="post">
|
||||
<p>
|
||||
<label for="nama_admin">Nama:</label>
|
||||
<input type="text" id="nama_admin" name="nama_admin" />
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<label for="email">Email:</label>
|
||||
<input type="text" id="email" name="email" />
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<label for="sandi">Sandi:</label>
|
||||
<input type="password" id="sandi" name="sandi" />
|
||||
</p>
|
||||
|
||||
<input type="hidden" id="id_admin" name="id_admin" />
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- delete confirmation dialog box -->
|
||||
<div id="delConfDialog" title="Confirm">
|
||||
<p>Apakah Anda Yakin</p>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- message dialog box -->
|
||||
<div id="msgDialog"><p></p></div>
|
||||
|
||||
|
||||
<script type="text/javascript" src="file:///C|/wamp/www/tiket_rai/application/views/admin/js/jquery-1.4.2.min.js"></script>
|
||||
<script type="text/javascript" src="file:///C|/wamp/www/tiket_rai/application/views/admin/js/jquery-ui-1.8.2.min.js"></script>
|
||||
<script type="text/javascript" src="file:///C|/wamp/www/tiket_rai/application/views/admin/js/jquery-templ.js"></script>
|
||||
|
||||
<script type="text/template" id="readTemplate">
|
||||
<tr id="${id_admin}">
|
||||
<td>${id_admin}</td>
|
||||
<td>${nama_admin}</td>
|
||||
<td>${email}</td>
|
||||
<td><a class="updateBtn" href="${updateLink}">Ubah</a> | <a class="deleteBtn" href="${deleteLink}">Hapus</a></td>
|
||||
</tr>
|
||||
</script>
|
||||
|
||||
<script type="text/javascript" src="file:///C|/wamp/www/tiket_rai/application/views/admin/js/adminall.js"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
73
application/views/tess2/HalamanUtama.php
Normal file
73
application/views/tess2/HalamanUtama.php
Normal file
@ -0,0 +1,73 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title><?php echo $judul; ?></title>
|
||||
<link rel="stylesheet" type="text/css" href="../../css/css2.css">
|
||||
<script>
|
||||
function myFunction(id)
|
||||
{
|
||||
var url="<?php echo base_url();?>";
|
||||
var r=confirm("Do you want to delete this?");
|
||||
if (r==true)
|
||||
{
|
||||
window.location = url+"index.php/barang_controller/delete/"+id;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><a href="v_admin.php"><img src="../../image/Untitled-3.png" /></a>
|
||||
</div>
|
||||
|
||||
<div class="header2">
|
||||
<a href="<?php echo base_url().'index.php/user_controller/logout'; ?>"><button id="bt2">Logout</button></a>
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
|
||||
<div class="barang">
|
||||
<h3>Daftar Barang</h3>
|
||||
<table border="3">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Nama Barang</th>
|
||||
<th>Harga</th>
|
||||
<th>Action</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
foreach($daftar_barang as $barang){
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $barang->nama; ?></td>
|
||||
<td><?php echo $barang->harga; ?></td>
|
||||
<td><?php echo '<a href="'.base_url().'index.php/barang_controller/edit/'.$barang->id.'"><button id="bt">Edit</button></a>' ?>
|
||||
<button id="bt" onclick="myFunction(<?php echo $barang->id;?>)">Delete</button>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
53
application/views/tess2/View_login.php
Normal file
53
application/views/tess2/View_login.php
Normal file
@ -0,0 +1,53 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<title>Login Form</title>
|
||||
|
||||
<link href="style.css" rel="stylesheet" type="text/css" />
|
||||
|
||||
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div id="wrapper">
|
||||
|
||||
|
||||
<div class="user-icon"></div>
|
||||
<div class="pass-icon"></div>
|
||||
|
||||
|
||||
|
||||
<form name="loginform" class="form" action="" method="post">
|
||||
|
||||
|
||||
<div class="header">
|
||||
<h1>Login</h1>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="content">
|
||||
<p>Email</p>
|
||||
<input name="email" type="text" class="input" value="email" onfocus="[this.value='']"/> <br /><br />
|
||||
<p>Password</p>
|
||||
<input name="password" type="password" class="input" value="Password" onfocus="[this.value='']" />
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="footer">
|
||||
<input type="submit" name="submit" value="Login" class="button" />
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
237
application/views/tess2/css2.css
Normal file
237
application/views/tess2/css2.css
Normal file
@ -0,0 +1,237 @@
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: 1;
|
||||
}
|
||||
|
||||
ul, ol, dl {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
h1, h2, h3, h4, h5, h6, p {
|
||||
margin-top: 0;
|
||||
padding-right: 15px;
|
||||
padding-left: 15px;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #ededed;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
color: #000;
|
||||
font:"Segoe UI";
|
||||
}
|
||||
|
||||
|
||||
.wrapper {
|
||||
width: 100%;
|
||||
min-height: 596px;
|
||||
background-color: #efefef;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.wrapper .header {
|
||||
background-color: #2f2f2f;
|
||||
min-height:45px;
|
||||
min-width:100%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
.wrapper .header .img{
|
||||
margin-top:12px;
|
||||
margin-left:15px;
|
||||
}
|
||||
|
||||
.wrapper .header .link {
|
||||
float:right;
|
||||
margin-right:23px;
|
||||
margin-top:14px;
|
||||
font-size:13px;
|
||||
color:#d1d1d1;
|
||||
text-decoration:none;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
.wrapper .header .link:hover {
|
||||
background-color:#5f5f5f;
|
||||
}
|
||||
.wrapper .header2 {
|
||||
background-color: #dadde1;
|
||||
min-height:15px;
|
||||
min-width:100%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
|
||||
.wrapper .sidebar1 {
|
||||
float: left;
|
||||
width: 200px;
|
||||
min-height:530px;
|
||||
background-color: #dadde1;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
|
||||
|
||||
ul.nav {
|
||||
list-style: none;
|
||||
float:left;
|
||||
font-size:12px;
|
||||
width: 200px;
|
||||
}
|
||||
|
||||
/*ul.nav li {
|
||||
border-top: 1px solid #cecccc;
|
||||
border-bottom: 1px solid #cecccc;
|
||||
}*/
|
||||
ul.nav a, ul.nav a:visited {
|
||||
|
||||
font-weight:bold;
|
||||
color: #D1D1D1;
|
||||
display: block;
|
||||
text-decoration:none;
|
||||
padding:10px 10px 10px 10px;
|
||||
background-color: #eeeeee;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #eeeeee), color-stop(100%, #cccccc));
|
||||
background-image: -webkit-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -moz-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -ms-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -o-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: linear-gradient(top, #eeeeee, #cccccc);
|
||||
border: 1px solid #ccc;
|
||||
border-bottom: 1px solid #bbb;
|
||||
border-right: 1px solid #bbb;
|
||||
color: #333;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
text-shadow: 0 1px 0 #eee;
|
||||
transition: all 0.5s;
|
||||
-moz-transition: all 0.5s;
|
||||
-webkit-transition: all 0.5s;
|
||||
-o-transition: all 0.5s;
|
||||
-ms-transition: all 0.5s;
|
||||
}
|
||||
|
||||
ul.nav a:hover, ul.nav a:active, ul.nav a:focus {
|
||||
font-weight:bold;
|
||||
width:215px;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
color: #ffffff;
|
||||
padding: 10px 10px 10px 15px;
|
||||
background: -moz-linear-gradient(
|
||||
top,
|
||||
#439bff 0%,
|
||||
#2b7cff 50%,
|
||||
#2b7cff 50%,
|
||||
#0062ff);
|
||||
background: -webkit-gradient(
|
||||
linear, left top, left bottom,
|
||||
from(#439bff),
|
||||
color-stop(0.50, #2b7cff),
|
||||
color-stop(0.50, #2b7cff),
|
||||
to(#0062ff));
|
||||
border: 1px solid #a3a3a3;
|
||||
-moz-box-shadow:
|
||||
0px 0px 0px rgba(000,000,000,0),
|
||||
inset 0px 0px 0px rgba(255,255,255,0);
|
||||
-webkit-box-shadow:
|
||||
0px 0px 0px rgba(000,000,000,0),
|
||||
inset 0px 0px 0px rgba(255,255,255,0);
|
||||
box-shadow:
|
||||
0px 0px 0px rgba(000,000,000,0),
|
||||
inset 0px 0px 0px rgba(255,255,255,0);
|
||||
text-shadow:
|
||||
0px -1px 0px rgba(000,000,000,0),
|
||||
0px 1px 0px rgba(255,255,255,0);
|
||||
}
|
||||
|
||||
.wrapper .content {
|
||||
background:#efefef;
|
||||
min-width: 85%;
|
||||
min-height:538px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.wrapper .content .border{
|
||||
border-left: 1px solid #cccccc;
|
||||
border-right: 1px solid #cccccc;
|
||||
border-bottom: 1px solid #cccccc;
|
||||
border-radius:3px;
|
||||
width : 90%;
|
||||
min-height : 30%;
|
||||
margin-left: 50px;
|
||||
margin-top: 35px;
|
||||
}
|
||||
|
||||
.wrapper .content .border .bordhead{
|
||||
border: 1px solid #F00;
|
||||
width : 100%;
|
||||
min-height:35px;
|
||||
max-height: 35px;
|
||||
display: block;
|
||||
text-decoration:none;
|
||||
background-color: #eeeeee;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #eeeeee), color-stop(100%, #cccccc));
|
||||
background-image: -webkit-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -moz-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -ms-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: -o-linear-gradient(top, #eeeeee, #cccccc);
|
||||
background-image: linear-gradient(top, #eeeeee, #cccccc);
|
||||
border: 1px solid #ccc;
|
||||
border-bottom: 1px solid #bbb;
|
||||
border-right: 1px solid #bbb;
|
||||
border-radius:3px;
|
||||
color: #333;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
text-shadow: 0 1px 0 #eee;
|
||||
}
|
||||
|
||||
.wrapper .content .border .bordhead p{
|
||||
font-size:12px;
|
||||
font-weight:bold;
|
||||
color:#333;
|
||||
padding: 9px 10px 10px 10px;
|
||||
}
|
||||
|
||||
.wrapper .content .border th{
|
||||
font-size:12px;
|
||||
font-weight:bold;
|
||||
color:#333;
|
||||
text-align:center;
|
||||
}
|
||||
.wrapper .content .add{
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size:12px;
|
||||
font-weight:Bold;
|
||||
color: #333;
|
||||
margin-left:30px;
|
||||
margin-top:20px;
|
||||
border: 1px
|
||||
}
|
||||
|
||||
|
||||
|
||||
.wrapper .content .add .input{
|
||||
width: 188px;
|
||||
padding: 5px 10px;
|
||||
font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
|
||||
font-weight: 400;
|
||||
font-size: 12px;
|
||||
color: #9d9e9e;
|
||||
background: #ffffff;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.wrapper .footer {
|
||||
padding: 10px 0;
|
||||
background-color: #CCC49F;
|
||||
position: relative;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.clearfloat {
|
||||
clear:both;
|
||||
height:0;
|
||||
font-size: 1px;
|
||||
line-height: 0px;
|
||||
}
|
35
application/views/tess2/edit_barang.php
Normal file
35
application/views/tess2/edit_barang.php
Normal file
@ -0,0 +1,35 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
<title><?php echo $judul; ?></title>
|
||||
<link href="../../css/edit_barang.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body style="background-color:#CF9">
|
||||
<div style="background-color:#FFF;border-radius:10px 10px 10px 10px;width:40%;height:180px;margin-top:5%;margin-left:30%;position:fixed">
|
||||
|
||||
<?php
|
||||
$att = array('id' => 'biodata-form');
|
||||
echo form_open('barang_controller/simpan_update_barang', $att);
|
||||
echo form_hidden('id',$edit->id);
|
||||
?>
|
||||
<fieldset style="margin:5% 5% 5% 5%">
|
||||
<legend>Update Data Barang</legend>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Nama Barang</td>
|
||||
<td><input type="text" name="nama_barang" value="<?php echo $edit->nama; ?>"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Harga</td>
|
||||
<td><input type="text" name="harga" value="<?php echo $edit->harga; ?>"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td><input type="submit" value="Simpan" alert("Berhasil");/></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
143
application/views/tess2/style.css
Normal file
143
application/views/tess2/style.css
Normal file
@ -0,0 +1,143 @@
|
||||
* {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color:#f9f9f9;
|
||||
font-weight:300;
|
||||
text-align: left;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#wrapper {
|
||||
width: 300px;
|
||||
height: 400px;
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 50%;
|
||||
margin-left: -150px;
|
||||
margin-top: -200px;
|
||||
}
|
||||
|
||||
.form {
|
||||
width: 300px;
|
||||
margin: 0 auto;
|
||||
position: relative;
|
||||
z-index: 5;
|
||||
background: #eaeaea;
|
||||
box-shadow: 0 3px 3px rgba(0,0,0,0.50);
|
||||
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
|
||||
-webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
|
||||
}
|
||||
|
||||
|
||||
.form .header {
|
||||
padding: 30px 30px 15px 30px;
|
||||
background: #eaeaea;
|
||||
}
|
||||
|
||||
.form .header h1 {
|
||||
font-family: 'Sylfaen';
|
||||
font-weight: 300;
|
||||
font-size: 28px;
|
||||
line-height:34px;
|
||||
color: #7f7f7f;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.form .header span {
|
||||
font-size: 11px;
|
||||
line-height: 16px;
|
||||
color: #678889;
|
||||
text-shadow: 1px 1px 0 rgba(256,256,256,1.0);
|
||||
}
|
||||
|
||||
.form .content {
|
||||
padding: 20px 30px 25px 30px;
|
||||
}
|
||||
|
||||
.form .content p {
|
||||
font-size: 16px;
|
||||
font-family: 'Sylfaen';
|
||||
color: #7f7f7f;
|
||||
}
|
||||
|
||||
.form .content .input {
|
||||
width: 188px;
|
||||
padding: 15px 25px;
|
||||
font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
|
||||
font-weight: 400;
|
||||
font-size: 14px;
|
||||
color: #9d9e9e;
|
||||
background: #ffffff;
|
||||
box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
|
||||
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
|
||||
-webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
|
||||
}
|
||||
|
||||
.form .content .input:hover {
|
||||
background: #ffffff;
|
||||
color: #414848;
|
||||
}
|
||||
|
||||
.form .content .input:focus {
|
||||
background: #fff9d9;
|
||||
color: #414848;
|
||||
|
||||
box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
|
||||
-moz-box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
|
||||
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
|
||||
}
|
||||
|
||||
|
||||
.input {
|
||||
transition: all 0.5s;
|
||||
-moz-transition: all 0.5s;
|
||||
-webkit-transition: all 0.5s;
|
||||
-o-transition: all 0.5s;
|
||||
-ms-transition: all 0.5s;
|
||||
}
|
||||
|
||||
|
||||
.form .footer {
|
||||
padding: 20px 30px 20px 30px;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
|
||||
.form .footer .button {
|
||||
float:right;
|
||||
padding: 8px 15px;
|
||||
font-family: 'Bree Serif', serif;
|
||||
font-weight: 300;
|
||||
font-size: 18px;
|
||||
color: #ffffff;
|
||||
text-shadow: 0px 2px 2px rgba(0,0,0,0.25);
|
||||
background: #438BFF;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.form .footer .button:hover {
|
||||
background: #438BFF;
|
||||
text-shadow: 0px 2px 2px rgba(0,0,0,0.25);
|
||||
box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
-webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
}
|
||||
|
||||
.form .footer .button:focus {
|
||||
position: relative;
|
||||
bottom: -1px;
|
||||
color: #5e5e5e;
|
||||
background: #438BFF;
|
||||
box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
-webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
|
||||
transition: all 0.2s;
|
||||
-moz-transition: all 0.2s;
|
||||
-webkit-transition: all 0.2s;
|
||||
-o-transition: all 0.2s;
|
||||
-ms-transition: all 0.2s;
|
||||
}
|
40
application/views/tess2/v_admin.php
Normal file
40
application/views/tess2/v_admin.php
Normal file
@ -0,0 +1,40 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="image/Untitled-2.png"class="img" />
|
||||
<a href="" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="">Dashboard</a></li>
|
||||
<li><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Data Barang</p></div>
|
||||
<table class="tabel" width=700 >
|
||||
<tr>
|
||||
<th>ID Barang</th>
|
||||
<th>Nama Barang</th>
|
||||
<th>Harga Barang</th>
|
||||
<th colspan="2">Aksi</th>
|
||||
</tr>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
48
application/views/tess2/v_adminadd.php
Normal file
48
application/views/tess2/v_adminadd.php
Normal file
@ -0,0 +1,48 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="image/Untitled-2.png"class="img" />
|
||||
<a href="" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="">Dashboard</a></li>
|
||||
<li><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Tambah Data</p></div>
|
||||
<table class="add" cellspacing="20">
|
||||
<tr>
|
||||
<td>Nama Barang</td>
|
||||
<td colspan="3"><input type="text" name="nama_barang" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Harga</td>
|
||||
<td colspan="3"><input type="text" name="harga" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr><td></td>
|
||||
<td></td>
|
||||
<td><input type="submit" name="submit" value="Simpan"/></td>
|
||||
<td><button type="button" name="Cancel" value="OK">Cancel</button></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
48
application/views/tess2/v_adminedit.php
Normal file
48
application/views/tess2/v_adminedit.php
Normal file
@ -0,0 +1,48 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>Halaman Admin</title>
|
||||
<link rel="stylesheet" type="text/css" href="css2.css">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="header"><img src="image/Untitled-2.png"class="img" />
|
||||
<a href="" class="link">logout</a></div>
|
||||
|
||||
<div class="header2">
|
||||
</div>
|
||||
|
||||
<div class="sidebar1">
|
||||
<ul class="nav">
|
||||
<li><a href="">Dashboard</a></li>
|
||||
<li><a href="">Kelola Data Barang</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="content">
|
||||
<div class="border">
|
||||
<div class="bordhead"><p>Edit Data</p></div>
|
||||
<table class="add" cellspacing="20">
|
||||
<tr>
|
||||
<td>Nama Barang</td>
|
||||
<td colspan="3"><input type="text" name="nama_barang" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Harga</td>
|
||||
<td colspan="3"><input type="text" name="harga" value="" class="input"/></td>
|
||||
</tr>
|
||||
<tr><td></td>
|
||||
<td></td>
|
||||
<td><input type="submit" name="submit" value="Simpan"/></td>
|
||||
<td><button type="button" name="Cancel" value="OK">Cancel</button></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
42
application/views/user.php
Normal file
42
application/views/user.php
Normal file
@ -0,0 +1,42 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><?php echo $judul; ?></title>
|
||||
<link href="../../css/user.css" rel="stylesheet" type="text/css">
|
||||
</head>
|
||||
<body class="bg">
|
||||
<div class="reg">
|
||||
<h3 style="padding-left:20px;padding-top:30px">Insert Data User</h3>
|
||||
<form id="form" action"simpan_user" method="post">
|
||||
<fieldset >
|
||||
|
||||
<table class="tabel">
|
||||
<tr>
|
||||
<td>Nama Lengkap</td>
|
||||
<td><input type="text" name="nama_lengkap"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Username</td>
|
||||
<td><input type="text" name="username"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Password</td>
|
||||
<td><input type="password" name="password"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Email</td>
|
||||
<td><input type="text" name="email"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Alamat</td>
|
||||
<td><textarea name="alamat" style="height: 80px;"></textarea></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td><button>SUBMIT</button></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
</form>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
90
application/views/welcome_message.php
Normal file
90
application/views/welcome_message.php
Normal file
@ -0,0 +1,90 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Welcome to CodeIgniter</title>
|
||||
|
||||
<style type="text/css">
|
||||
|
||||
::selection{ background-color: #E13300; color: white; }
|
||||
::moz-selection{ background-color: #E13300; color: white; }
|
||||
::webkit-selection{ background-color: #E13300; color: white; }
|
||||
|
||||
body {
|
||||
background-color: #fff;
|
||||
margin: 40px;
|
||||
font: 13px/20px normal Helvetica, Arial, sans-serif;
|
||||
color: #4F5155;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #003399;
|
||||
background-color: transparent;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #444;
|
||||
background-color: transparent;
|
||||
border-bottom: 1px solid #D0D0D0;
|
||||
font-size: 19px;
|
||||
font-weight: normal;
|
||||
margin: 0 0 14px 0;
|
||||
padding: 14px 15px 10px 15px;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: Consolas, Monaco, Courier New, Courier, monospace;
|
||||
font-size: 12px;
|
||||
background-color: #f9f9f9;
|
||||
border: 1px solid #D0D0D0;
|
||||
color: #002166;
|
||||
display: block;
|
||||
margin: 14px 0 14px 0;
|
||||
padding: 12px 10px 12px 10px;
|
||||
}
|
||||
|
||||
#body{
|
||||
margin: 0 15px 0 15px;
|
||||
}
|
||||
|
||||
p.footer{
|
||||
text-align: right;
|
||||
font-size: 11px;
|
||||
border-top: 1px solid #D0D0D0;
|
||||
line-height: 32px;
|
||||
padding: 0 10px 0 10px;
|
||||
margin: 20px 0 0 0;
|
||||
}
|
||||
|
||||
#container{
|
||||
margin: 10px;
|
||||
border: 1px solid #D0D0D0;
|
||||
-webkit-box-shadow: 0 0 8px #D0D0D0;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div id="container">
|
||||
<h1>Welcome to CodeIgniter!</h1>
|
||||
|
||||
<div id="body">
|
||||
<a href="http://localhost/kepra/index.php/user_controller/login ">Main Site</a>
|
||||
|
||||
<p>The page you are looking at is being generated dynamically by CodeIgniter.</p>
|
||||
|
||||
<p>If you would like to edit this page you'll find it located at:</p>
|
||||
<code>application/views/welcome_message.php</code>
|
||||
|
||||
<p>The corresponding controller for this page is found at:</p>
|
||||
<code>application/controllers/welcome.php</code>
|
||||
|
||||
<p>If you are exploring CodeIgniter for the very first time, you should start by reading the <a href="user_guide/">User Guide</a>.</p>
|
||||
</div>
|
||||
|
||||
<p class="footer">Page rendered in <strong>{elapsed_time}</strong> seconds</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user