Kohana 3.2.x: Master Template Controller [step 1]

Let's create a content module that will handle both static and dynamic content: First enable the module: modules/application/bootstrap.php Kohana::modules(array( . . 'content' => MODPATH . 'content', // Content module . . ));   Second, create the master template controller: modules/content/classes/controller/base/template.php template_name = Kohana::$config->load('content.template.name'); $this->template = 'template/'.$this->template_name.'/index'; parent::before(); if ($this->auto_render) {… Continue reading

LAMP: Installing on Slackware 13.37 64-bit

Ongoing post:   1. Download Apache ( http://httpd.apache.org ) tar -xvjf httpd-2.2.21.tar.bz2 cd httpd-2.2.21 I like Slackware, but I also like the Apache layout installed in Debian distributions, so: ./configure –enable-layout=Debian–enable-module=most –enable-mods-shared=most –enable-ssl=shared make make install 2. PostgreSQL ./configure –with-perl –with-openssl gmake all gmake install     PHP ./configure –with-pgsql… Continue reading

(ve) Installing LAMP on Debian Squeeze – 64bit

aptitude update aptitude safe-upgrade aptitude install mysql-server mysql-client       NGINX aptitude install libpcre3-dev build-essential libssl-dev sudo cd /opt/ http://nginx.org/en/download.html wget http://nginx.org/download/nginx-1.0.8.tar.gz tar -xvzf nginx-1.0.8.tar.gz cd nginx-1.0.8 ./configure –prefix=/opt/nginx –user=nginx –group=nginx –with-http_ssl_module –conf-path=/etc/nginx/nginx.conf –error-log-path=/var/log/nginx/error.log –http-log-path=/var/log/nginx/access_log –with-http_ssl_module –with-http_geoip_module –pid-path=/var/run/nginx.pid nginx path prefix: “/opt/nginx” nginx binary file: “/opt/nginx/sbin/nginx” nginx configuration prefix:… Continue reading

(vps): Noexec and /tmp troubleshooting

Chrooted /tmp directory There is also a new method that ensures that no processes currently accessing /tmp are interrupted in any way. This also ensures that your /tmp that allows execution is never accessible to currently running processes. This limits your exposure to possible exploits. First, create a chrooted environment… Continue reading

Kohana 3.2 tutorial : 2 – Setting up and basic Redirect controller

1. Edit bootstrap.php under “application”: —————————— date_default_timezone_set(‘America/Los_Angeles’); Kohana::init(array( ‘base_url’ => ‘/’, ‘index_file’ => ”, )); ——————– 2. Change the default route to a redirect controller (so we can deal with redirections for misplaced content/old content): Route::set(‘default’, ‘(<request>)’, array( ‘request’ => ‘(.*)’, )) ->defaults(array( ‘controller’ => ‘redirect’, ‘action’ => ‘index’, ));… Continue reading

Kohana 3.2 tutorial : 1 – Installation

1. Go to kohana’s website   http://kohanaframework.org/   2. Download latest stable   $ wget http://dev.kohanaframework.org/attachments/download/1670/kohana-3.2.0.zip –11:08:44– http://dev.kohanaframework.org/attachments/download/1670/kohana-3.2.0.zip => `kohana-3.2.0.zip’ Resolving dev.kohanaframework.org… 173.245.60.22, 173.245.61.87 Connecting to dev.kohanaframework.org[173.245.60.22]:80… connected. HTTP request sent, awaiting response… 200 OK Length: 1,043,281 [application/zip] 100%[==============================================================================================================================================================>] 1,043,281 1.53M/s 11:08:45 (1.53 MB/s) – `kohana-3.2.0.zip’ saved [1043281/1043281] 3. Uncompress… Continue reading

AppSumo: $100 for life per year on Amazon

I can sure use it http://appsumoforlife.com/~OLTM Win $100 A Year For Life At Amazon.com 10 lucky winners will get an Amazon.com $100 Gift Card every year for the rest of their lives! Ends soon!