Skip to Content

Blogs

Difference Between Include() Vs Include_once() In Php

The include_once() statement includes and evaluates the specified file during the execution of the script. This is a behavior similar to the include() statement, with the only difference being that if the code from a file has already been included, it will not be included again. As the name suggests, it will be included just once.
 
 

ok, what does this mean exactly? lets say for example, i have three files, 

 

FILES: 

FUNCTIONS.PHP 

GLOBALS.PHP 

HEADER.PHP 

this is how each file looks like:

Tags: 

Quickstart guide Varnish on Ubuntu

Lets install Varnish :

Here we will consider the ubuntu as my OS is the same :P.

simply use.
#sudo apt-get install varnish

It will show the dependency tree for the varnish so just install.
In this case you don't have to build the packages and configure like other *nix.

Using varnish Servers :

Varnish has a concept of "backend" or "origin" servers. A backend server is the server providing the content Varnish will accelerate.

The default configuration file located at :
/etc/varnish/default.vcl

Tags: 

Sharing content type, content and users on two different drupal 6 sites

Hello,
I would like to share this blog for those drupal developers who are stuck for sharing the content, users and seperate themes and structures.
You can try this on your local machines windows / linux both.We will be using ip based virtual hosts in this tutorial.
Just follow the steps for installing multisite with same database and same codebase with two different domains.
A. Basic domain setup :
open the "hosts"  file
linux - /etc/hosts
windows - c:/windows/system32/drivers/etc/hosts :
Add the hosts as

Tags: 

Enable SSL or HTTPS on Ubuntu 11.04 with Apache 2

This article refers to those people who want to enable their ssl on their local system or on servers.
More specifically on Ubuntu 11.04 and Apache2 we have to use fullowing commands to install apache2 and ssl.

1. First to install apache2
sudo apt-get install apache2
2. Then to install the ssl-certificate
sudo apt-get install ssl-cert
3. To create the ssl directory
sudo mkdir /etc/apache2/ssl
4. Hardcoding cert lifetime
sudo make-ssl-cert /usr/share/ssl-cert/ssleay.cnf /etc/apache2/ssl/apache.pem

Tags: 

Pages

Subscribe to RSS - blogs