Archive

Archive for the ‘My Works’ Category

my book on cacti

July 8th, 2009 lavluda 28 comments

hi all,

today is my one of the happiest day of my life. today packtpub (www.packtpub.com) declared a new book on cacti that going to release this month. and i am one of the author of that book :)

all credit goes to my wife tania sabnam :) , without your help, it was not possible for me . love you.

my first book on cacti

my first book on cacti

here is the books url http://www.packtpub.com/cacti-0-8-network-monitoring/book :)

buy from amazon: cacti 0.8 network monitoring

number of view: 1312

Popularity: 6% [?]

  • Share/Bookmark

phpmailer for codeigniter (ci)

May 19th, 2008 lavluda 11 comments

on our new server we was getting problem with mail sending. yahoo and some other mail server was not receiving our mails to there inbox. so i imported the most popular php class (phpmailer ) in codeigniter as plugin. it’s install and use is too simple. you have to download the zip file from here, then unzip it to your plugin (system\plugins) folder. then edit phpmailer_pi.php , and edit the default configuration as needed as your mail server (default configuration will work fine with gmail smtp, you only have to edit the user name and pass) .

download:

phpmailer for codeigniter

usage:

you can now use all the functions that phpmailer supported. here is a the example that you will get in phpmailer site, but in ci format.

 < ?php
/*
 * Created on May 19, 2008
 *
 * To change the template for this generated file go to
 * Window - Preferences - PHPeclipse - PHP - Code Templates
 */
 
 class Action extends Controller {
 
	function Action()
	{
		parent::Controller();
	}
 
   function testMailer()
   {
	   error_reporting(E_ERROR);
 
	   $this->load->plugin('phpmailer');
	   $mail=new PHPMailer();
 
	/*$mail->IsSMTP();
	$mail->SMTPAuth   = true;                  // enable SMTP authentication
	$mail->SMTPSecure = "ssl";                 // sets the prefix to the servier
	$mail->Host       = "smtp.gmail.com";      // sets GMAIL as the SMTP server
	$mail->Port       = 465;                   // set the SMTP port 
 
	$mail->Username   = "username@somedomain.com";  // GMAIL username
	$mail->Password   = "xxxxxx";            // GMAIL password
	*/
 
	$mail->From       = "username@somedomain.com";
	$mail->FromName   = "sender name";
	$mail->Subject    = "This is the subject";
	$mail->Body       = "Hi,This is the HTML BODY";                      //HTML Body
	$mail->AltBody    = "This is the body when user views in plain text format"; //Text Body
	//print_r($mail);
	$mail->WordWrap   = 50; // set word wrap
 
	$mail->AddAddress("someone@somedomain.com");
	$mail->AddReplyTo("username@somedomain.com","sender name");
	$mail->AddAttachment("/path/to/file.zip");             // attachment
	$mail->AddAttachment("/path/to/image.jpg", "new.jpg"); // attachment
 
	$mail->IsHTML(true); // send as HTML
 
	if(!$mail->Send()) {
	  echo "Mailer Error: " . $mail->ErrorInfo;
	} else {
	  echo "Message has been sent";
	}
 
   }
}
 
?>
number of view: 1501

Popularity: unranked [?]

  • Share/Bookmark

watch live steaming from softexpo 2008

February 17th, 2008 lavluda 3 comments

can’t go to softexpo ? you can see the live steaming from somewherein pavilion . to see the live steaming visit http://www.somewhereinblog.net, on the right side bar you will get the link or open mmsh://206.222.3.106:1235 with vlc player.

and this totall system is made and maintained by me, thanks to morshed bhai for his help to design the web interface. :)

number of view: 1107

Popularity: 4% [?]

  • Share/Bookmark

how to move your php development environment to linux (Debian/Ubuntu)

August 4th, 2007 lavluda 24 comments

Nowadays, lots of php developers are thinking to move their development environment to linux. And I am writing this tutorial for them. As I like Debian GNU/Linux (www.debian.org) best and ubuntu (www.ubutnulinux.org) is now doing great, in this tutorial I am using the commands for debian & ubuntu.

Ok, now starting:

First on all let’s make a list of software a PHP developer need mostly:

1.Apache
2.PHP
3.Mysql
4.PHP IDE

Ok, let’s start with Apache. Debian & ubuntu use APT to manage the packages. You can easily install apache using apt, here is the command

Debian user:

su

Ubuntu user:

sudo su

Rest of the command ar same for both debian & ubuntu.

apt-get install apache2

It will install all the apache2 & all the related packages (software)
If you need to enable mod_rewrite, follow this link
Now install the PHP

Apt-get install php5 libapache2-mod-php5

This will install the php5 and configure your apache2 server for PHP. You don’t need to do anything.
Lets test the server, if it working ok.

touch /var/www/info.php

Chown www-data:www-data info.php

Now edit this info.php with your feviourate editor and add write code to show phpinfo():
and now browse http://localhost/info.php from your browser. Now check if all your requested library are installed.
if you need any more library, you can check if it already available on your debian/ubuntu package list.

apt-cache search php5-

then you will get the list of available php5 library. Now simple use this command to install it.

apt-get install php5-gd

(example, if you want to install php5 GD library)

Remember: after installing every extra packages, you must need to restart apache server

/etc/init.d/apache2 restart

Ok, so you have now apache2 and php5 installed system. Let’s install mysql:

apt-get install mysql-server-5.0 php5-mysql

It will install all the necessary packages to run mysql-server.
Now restart your apache to take effect.
Complete!!!! Server is allmost ready.
Now i am going to derive how you will transfer your old code to this new environment. Belive me it’s too simple, so don’t worry.

First of all copy your source code to /var/www, here is the details procedure:

mkdir /windows

Here we make a folder for C drive of windows to mount.
mount /dev/hda1 /windows
then we mount the C drive to windows folder (here i use hda1 as example, if your hdd is sata then it will be sda1)

cp -r windows/Apache2/htdocs/xyz /var/www

here we copied our xyz site to /var/www (in debian and ubuntu, default apache2 root folder is /var/www)

cd /var/www

chown -R www-data:www-data xyz

Now change the ownership to www-data

Now we need to move the mysql database, there is two way:

1.use phpmyadmin
2.simple copy the database from data folder
I am deriving the 2nd way.

cp -r /windows/Mysql/data/xyz /var/lib/mysql

chown -R mysql:mysql /var/lib/mysql/xyz

You are done.

PHP Ide for linux environment:

    1.Zend ( i personaly use this)
    2.PHPEd
    3.PHPEclipse
    4.quanta plus
    5.emacs
    6.vi
    7.PHPedit

***I know this tutorial needs more edit, please make your comments if you got anything wrong, or missed anything. I want it a cool tutorial for php developers.

number of view: 951

Popularity: 26% [?]

  • Share/Bookmark

my debian unoffical repository

July 17th, 2007 lavluda 3 comments

Few minutes ago i make a unoffical repository of deb packages for debian (though it’s empty).
you have to add this line to your /etc/apt/sources.list
deb http://debian.lavluda.com binary/

if you want to release any deb file unofficaly for debian and need help to host it, send me the .deb file and don’t forget to add signature to your package.

** for testing i added the d4x on my repository, i will remove it.

please test my repository and give your feedback here.

number of view: 316

Popularity: 17% [?]

  • Share/Bookmark
Categories: Debian, Debian GNU/Linux, My Works Tags:

বাংলা পিএইচপি বই

June 25th, 2007 lavluda 13 comments

গত কাল এক বন্ধুর জন্য পিএইচপিএর বাংলা বই কিনতে গিয়েছিলাম নিলক্ষেত। কিন্তু বইয়ের অবস্থা দেখে খালি হাতেই বাড়ি ফিরলাম। কি আর বলব তাদের বইয়ের কোয়ালিটি। মোট 2 টি বই পেয়েছিলাম। 1তম টায় দেখলাম পিএইচপি আর মাই এসকিউল ইনেস্টলশেন করতে করেতই অর্ধেক বই শেষ বাকিটা যা্ষ্ট ম্যানোয়ালের ট্রানসলেশন। আর দ্বিতীয় বইটিতে দেখলাম যা আলোচনা করা দরকারঁ তার সম্প্রর্কে খুব কমই লিখেছে। শুধু আজে বাজে কথায় ভর্তি।

আমি খু্বই হতাশ হলাম। চিন্তা করছি সময় করতে পারলে একবার চেষ্টা করে দেখব, একটা পিএইচপি বই লেখতে পারি কিনা যা দিয়ে যে কোন ব্যক্তি অন্তত বেসিকটা ভালভাবে বুঝে শিখতে পারবে।

number of view: 552

Popularity: 14% [?]

  • Share/Bookmark
Categories: My Works, PHP Tags:

Wordpress Bangla plugin 1.5 released

May 31st, 2007 lavluda 3 comments

Read this first

At last today it released from ekushey.org

Now you can download it from here

প্লাগিনটি টেস্ট করার জন্য সবাইকে ধন্যবাদ।

number of view: 361

Popularity: 14% [?]

  • Share/Bookmark
Categories: My Works, PHP, wordpress plugin Tags:

Wordpress Bangla plugin updated

May 26th, 2007 lavluda 29 comments

I just done the update of wordpress bangla plugin . That was developed by Hasin Hayder .

Now you can also write comments in bangla (unijoy & phonetic) without installing any extra software.

Everybody are welcome to test it by commenting here. Please write details if you get any bug.

download wordpress bangla plugin

Installation steps:
1. Download the zip file
2. extract it
3. upload the banglakb folder to http://yourdomain.com/wp-content/plugins
4. login to your admin panel and activate the banglakb plugin
5. edit your profile, and uncheck visual editor (to make post in bangla)
6. Add this code < ?php wp_banglakb_comments(); ?> in your comments.php after “comment” textarea.


Done

number of view: 1309

Popularity: 21% [?]

  • Share/Bookmark
Categories: My Works, wordpress plugin Tags:

welcome to lavluda.com

May 24th, 2007 lavluda 1 comment

Hi everybody, i am lavlu from bangladesh. Basically i am a linux fan. Though right now working as Web Application Developer in somewherein….

Yesterday i took this domain for my blog. Please don’t forget to come back. You will get information about me, my works, linux & many more things.

The design is not fixed yet, if you have any opinion, please write in comment.

number of view: 149

Popularity: 8% [?]

  • Share/Bookmark
Categories: My Works, Personal Tags:

hurraaaaaaaaaa I got phpED 5.0

May 17th, 2007 lavluda 4 comments

phpED

At last I got my phpED (license copy). Thanks goes to Hasin Hayder.

Hope it will help me to make batter experience with PHP.

Soon i will write review on phpED 5.0

number of view: 206

Popularity: 11% [?]

  • Share/Bookmark
Categories: My Computer, My Works, PHP, Programming Tags: