Thule - 0.9.6
  • Welcome
  • Introduction
  • - MVC(Model-View-Controller)
    - Architecture of Framework
    - Flow Chart of Application
    - Services In One Server
    - Developing Guide
    - Features
  • Installation
  • Getting Started
  • - Direct Access HTTP
    - Router Access HTTP
    - Router Direct Access HTTP
    - Reserved Function
    - Convention
    - Bootstrap
    - Pack Javascript , CSS
  • Basic Modules
  • - Model
    - View
    - Controller
  • Libraries
  • - Router
    - Config
    - Response
    - Request
    - Database
    - Query
    - Cache
    - Debug
    - Log
    - Unit Test
    - Registry
    - Profile
  • Helper
  • - Auth
    - Calendar
    - Date
    - Error page
    - Email
    - Form
    - GeoIP
    - Google
    - Html Element
    - Html
    - Http
    - I18n
    - Image
    - Json
    - Jquery
    - Login
    - Layout
    - Locale
    - PHP to Javascript
    - Paging
    - Payflow
    - Soap
    - Text
    - Table
    - Uri
    - Upload
    - Validation
  • Plugins
  • - Smarty Template Engine
  • History
  • Home >Auth

    Cookie configure


    you can chooose the cookie name's prefix ,domain,path and expire time (config/dev_config.php)

    $config['cookie_prefix']='THULE_';
    $config['cookie_domain']='.thuleframework.com';
    $config['cookie_path']='.thuleframework.com';
    $config['cookie_expire']=86500;

    How to load in controller


    more detail in here

    $this->loadHelper("auth);

    Set Cookie


    If there are no property in cookie, the cookie should be defaulted with variable in config/dev_config.php

    $cookie['name']='THULE';
    $cookie['value']='THULE1234';
    $cookie['path']='/';
    $cookie['domain']='.thuleframework.com';
    $this->Auth->set_cookie($cookie);

    Get Cookie


    $this->Auth->get_cookie($cookie);

    Check Cookie value


    If cookie's value is equal to $value, returns true or not false

    $this->Auth->is_cookie($cookie,$value)

    Delete Cookie


    $this->Auth->del_cookie($cookie);