Setup Ubuntu as a Web Server
So these are the general steps for setting up a web server (Apache, MySQL and PHP) on a Ubuntu server. If you are not sure on how to use unix command line see: http://www.leonardaustin.com/technical/ssh-commands
Install Apache MySQL and PHP
sudo tasksel install lamp-server sudo /usr/sbin/apache2ctl restart
Install mod_rewrite
sudo a2enmod rewrite sudo /usr/sbin/apache2ctl restart
You also need to find this file:
/etc/apache2/sites-available/default
and change “AllowOverride None” to “AllowOverride All” it appears a couple of times.
Install PHPMyAdmin
sudo apt-get install phpmyadmin
“In /etc/apache2/apache2.conf” Add “Include /etc/phpmyadmin/apache.conf”
The restart apache
sudo /usr/sbin/apache2ctl restart
Install XBedug – Optional for DEV only
sudo apt-get install php5-dev php-pear sudo pecl install xdebug
# Make a note of the location of the xedebug.so then create a xdebug.ini with the below info and put it into “/etc/php5/conf.d”
; xdebug debugger zend_extension="/usr/lib/php5/20060613/xdebug.so" # IN php.ini file make sure html_errors = true sudo /etc/init.d/apache2 restart
PHP Important Folder and Files
# /etc/php5 # /etc/php5/apache2/php.ini
Apache Important Folder and Files
# /etc/apache2/ # /etc/apache2/apache2.conf # /etc/apache2/sites-available/default
Web Folder
# /var/www
Other Steps
Change php.ini errors to show all
Changing Plesk Fast CGI to Apache PHP with ZF
So recently I’ve had to change the php mode from Fast CGI to Apache Module in plesk due to the http authenticate functions in php not working. This caused my Zend Framework website to produce a 500 error, in my case it was something to do with:
Fatal error: Uncaught exception 'Zend_Session_Exception' with message 'session has already been started by session.auto-start or session_start()
The reason for the error is that the session already existed from my first visit and CGI was the owner, when I changed it to Apache module apache did not have permission to change the session data. The solution, shut down your browser (or start a privacy mode) and then try and view your website. Everything should work fine afterwards.
How to Access PUT data in Zend Framework
So I have followed a few tutorials online on how to build a RESTful API in Zend Framework (http://mwop.net/blog/228-Building-RESTful-Services-with-Zend-Framework) and everything seemed to go swimmingly except when it came to retrieveing the PUT request data. Took me a while to find this however there is a controller plugin pre-built in Zend Framework that you have to enable (Zend_Controller_Plugin_PutHandler). Basically it add the PUT data into the standard request object so you can access the data via getParams() or getParam(‘var’).
For more information see:
30 minutes until 30!
So 30 minutes until 30!
A list of things that I am appreciative of:
- Surviving surgery, when the odds where against me
- 11.21s for 100m
- Seeing the sun never set in Iceland
- My Friends
- Buying and renovating a house
- Winning a gold medal in an international Jiu-Jitsu competition
- The Power House
- My 1st class degree in physics
- Setting up a business
- Seeing and experiencing the awesome things in the world, for 10 months
- Got my motorbike licence
- Got my pilots licence
- Learnt to play the piano
- Make at least £1 million
- A black belt in any martial art
- Own an AC Cobra
- Acted or directed in a film
- Experienced fame
- Seeing the remaining awesome things in the world
- Changed to World
Google Analytics Benchmarking Newsletter July 2011
Just clearing through my inbox and found Google Analytics Benchmarking Newsletter. This is exceptionally useful for most of my clients.
| Google Analytics Benchmarking Newsletter 2011, Volume 1, July 2011 |
1. IntroductionWelcome to the first volume of the Analytics Benchmarking Newsletter! This month, we are replacing the standard “benchmarking” report in your Google Analytics account with data shared in this newsletter. We are using this newsletter as an experiment to surface more useful or interesting data to Analytics users. Data contained here comes from all websites which have opted-in anonymous data sharing with Google Analytics. Only those website administrators which have enabled this anonymous data sharing will receive this “benchmarking” newsletter. You may be wondering, how many websites are in this “anonymous data sharing” pool? Currently, hundreds of thousands, and we’ve endeavored to make all of the metrics here statistically significant. The date range of comparison for this newsletter is from November 1, 2010 – February 1, 2011. Comparison is done with data from November 1, 2009 – February 1, 2010. Absolute metrics such as total # visits, pageviews, or conversions for all opted-in websites are not reported. To simplify the prose, the phrase “websites” will represent “websites which have opted into anonymous data sharing with Google Analytics” for the rest of this newsletter. 2. Site MetricsCompared to a year ago, websites have seen reduced pages / visit, average time on site, as well as bounce rate.
2.1 Breakdown by GeographyOur anonymous database has aggregated geographic breakdown at the country level. Here are a few representative countries and their respective aggregate metrics. The first number in each cell represents the metric for the date range 11/1/10-2/1/11. The parenthesized number is the Year over Year delta compared to a year ago.
For bounce rate, the distribution by country is plotted below: ![]() The distribution above is annotated with some countries — which seem to indicate a story of leisure and stage of economic development. For a related metric: average time on site, the distribution by country is plotted below: ![]() The type of countries annotated in the average time on site graph above seem to be in reverse order as those in the bounce rate distribution. 2.2 Breakdown by Traffic SourcesTraffic sources below are identified by how the “source” and “medium”"” parameters are received by the Google Analytics collecting servers. Here is an article describing what these designations refer to.
2.4 Conversion Rate DistributionMany marketers’ favorite metric is conversion rate. Here is the worldwide distribution of Google Analytics “goal conversion rate” by country.
![]() Would anyone have guessed that states which are known for conversions are also high for their citizens’ goal conversion rate? Note that for some states with few population, the statistical significance of the conversion metric comes into doubt. 3. Traffic SourcesTraffic sources below are identified by how the “source” and “medium” parameters are received by the Google Analytics collecting servers. Here is an article describing what these designations refer to.
4. Operating SystemsBrowsers and Operation Systems (OS) are identified by the “referrer” string sent by users’ browsers.
5. CommentsThis is the first volume of our Analytics Benchmarking Newsletter. We hope that it provides useful insights. If you have specific comments or suggestions on how to improve this newsletter, please send your feedback to: analytics-benchmarking@google.com. Happy analyzing, |
Recent Posts
- Diary of a Startup: I’ve Just Applied to Seedcamp
- Diary of a Startup: Create a startup for £14
- Sendmail on Ubuntu
- Adobe Air with Netbeans
- Best Firefox Plugins for SEO aka Addons
- Setup Ubuntu as a Web Server
- Changing Plesk Fast CGI to Apache PHP with ZF
- How to Access PUT data in Zend Framework
- 30 minutes until 30!
- Google Analytics Benchmarking Newsletter July 2011
My External Links
Twitter Updates
- I'm at Earls Restaurant (229 Banff Ave, Wolf St, Banff) http://t.co/mYqKENLt 3 days ago
- New Local Dark Ale. Lovely @ Earl's - Banff http://t.co/otFtzHbQ 1 week ago
- I'm at Calgary International Airport (YYC) (2000 Airport Rd. N.E., Calgary) w/ 7 others http://t.co/IRI8zsHj 1 week ago
- I'm at BA Galleries Club Lounge South (at Terminal 5, LHR Airport, Heathrow) w/ 3 others http://t.co/FikQ8bSQ 1 week ago
- I'm at Terminal 5 (LHR Airport, 234 Bath Rd., Hounslow) w/ 8 others http://t.co/IbyWsNNf 1 week ago
- I'm at Yum Yum (5B Brewery Place, Brewery Wharf, Leeds) http://t.co/DKzTstpt 2 weeks ago
- RT @YahooFinance: The Case for a 21-Hour Work Week http://t.co/UFru9Pwy 3 weeks ago
- How Facebook's Expected $100 Billion IPO Breaks Down [INFOGRAPHIC] http://t.co/GxGMffP6 via @mashable 3 weeks ago
- I'm at Old Broadcasting House (Leeds Metropolitan University, at Civic Quarter, Leeds) w/ 4 others http://t.co/8M32KNy5 3 weeks ago
- Start 2012 by Taking 2 Minutes to Clean Your Apps Permissions. http://t.co/ltxMfrow 1 month ago







