This is a quick howto install NetBeans and needed plugins to start creating 3D java programs, including games in. Tested on Ubuntu 9.04 Jaunty. Read more…
Buffer IO error while booting Ubuntu from pendrive?
I’m in a hurry so this will be quick:
Try disabling floppy drive in BIOS config.
Think #1
Don’t forget your errors
Pen,
Learn,
Pencil,
Forget
Haiku of mine.
Amazing #1

Helicopter in Alaska attempting to tow a barge
Free unused RAM memory in linux
I needed to free some garbage in my ram due to my bad coded OpenGL experiments and their memory leaks. So I found this technique which freed about 1.2GB of my RAM:
# Generate a 2000MB file
dd if=/dev/zero of=junk bs=10MB count=200
# by now top will show not much free memory left.
rm junk
Pading numbers with zeros in PHP and MySQL
PHP:
$Num = 99
echo str_pad($Num, 3, "0", STR_PAD_LEFT);
// outputs: 099
MySQL:
SELECT LPAD(Num,3,"000") FROM table
Keep studying Bruno, keep studying

Keep studying Bruno, keep studying.
Test your PHP in: http://www.zend.com/store/education/certification/self-test.php
Also:
Hello!
I just finished the PHP Syntax Exam at http://www.blueshoes.org/en/developer/syntax_exam/ in 3045 seconds and had 7 errors in 69 questions.
Do you think you can beat me?
![]()
Greetings
Find files by name and text inside them in Linux
find /var/www -iname '*.php' | xargs grep 'print_r' -sl
/var/www/blog/www/wp-admin/includes/upgrade.php
/var/www/blog/www/wp-admin/install-helper.php
/var/www/blog/www/wp-admin/user-edit.php
/var/www/blog/www/wp-admin/import/blogger.php
/var/www/blog/www/wp-app.php
/var/www/blog/www/wp-content/themes/default/functions.php
/var/www/blog/www/wp-includes/cache.php
/var/www/blog/www/wp-includes/atomlib.php
The command above:
- searches in /var/www
- for files with .php extension
- for files that contain the “print_r” string
Taken from: http://www.liamdelahunty.com/tips/linux_find_string_files.php
PHP Session name. Or how to separate sessions from different sites on the same server
Recently I had to work on an environment that had many sites hosted on the same machine.
For my shock they all the websites where using the same PHP session name! That alone was the main source of conflicts, bugs and HUGE unbelievable security holes. Imagine logging in one site and appear as logged also on another but as a different user? Imagine chaos.
Fortunately the fix is easy if you know what you are doing. I just had to name PHP sessions for each site. Here are two simple methods:
1) call session_name() in beginning of every page
session_name('My_Site_Name');
session_start();
2) .htaccess file in site root directory containing:
php_value session.name My_Site_Name
Have a nice day.




