Do you know you can implement http authentication using php code? HTTP authentications are those you see when  you open control panel or administrative backend website, prompting for username and password in html  authentication prompt.

auth

This can be done in php using following code:

<?php

if (!isset($_SERVER['PHP_AUTH_USER'])) {

header(‘WWW-Authenticate: Basic realm=”My Realm”‘);

header(‘HTTP/1.0 401 Unauthorized’);

echo ‘Text to send if user hits Cancel button’;

exit;

} else {

echo “<p>Hello {$_SERVER['PHP_AUTH_USER']}.</p>”;

echo “<p>You entered {$_SERVER['PHP_AUTH_PW']} as your password.</p>”;

}

?>

Source: http://php.net/manual/en/features.http-auth.php

Tags: , , , , , , , , , , ,

· · · ◊ ◊ ◊ · · ·

Logo-mysql

Of course, it is not my post. But I wrote it here for a back up for myself. I got this from some website, it works !

Steps1)

  1. Stop running Mysql service  first (Administrative tools > Services )
  2. Open command prompt (cmd) and reach the directory  (using CD command) where Mysql bin  is installed (eg: C:/Program Files/Mysql/bin)
  3. type mysqld.exe -u root –skip-grant-tables and press enter (don’t close this command prompt)
  4. Open new command prompt and reach the same  Mysql bin directory
  5. type mysql and press enter (This time, it never prompts for any passwords and you can enter mysql console)
  6. type command use mysql to switch your database into mysql
  7. Execute the usual command to change password for rootUPDATE user SET Password = PASSWORD(‘your_new_password’) WHERE User = ‘root’;
  8. Close the command prompts and go to services , start mysql. Now you can login with your new root password

Thanks and have a nice day
Sajith

Tags: , , , , , , , , , , , , ,

· · · ◊ ◊ ◊ · · ·

Hello programmer,

If you are a programmer, you  might experience on saving your different ftp , email , website credintals (usernames and passwords) . Someone uses google documents for saving passwords. Some use email itself as a password storing medium. To be more secured, you have to save your passwords in you local machine rather than putting them into any other 3rd party online medium.

Truecrypt is an open source software for saving secured data (Folders and files). It is available for most of the operating systems (Windows, Linux, Mac etc). The advantage of TrueCrypt is, it creates a seperate partition or storage device as a normal USB memory stick. When you mount the partition it asks for a secured password. You can save your personal and secret files inside this partition. You can creates more than on partition using this software. So you can seperate your data files if you needed.

Here is the website url: http://www.truecrypt.org/

It also provides two level security. It adds a hidden file inside another secured file, so that when an adversary forces you to reveal your password, or forces you to open the secured folder, there is no chance for them to view the hidden encrypted file.

For more details visit:

http://www.truecrypt.org/hiddenvolume.php

Tags: , , , , , , ,

· · · ◊ ◊ ◊ · · ·

Contact Grabber

06 Nov 2008

If you are a social media website developer , sometimes you might search for grabbing contacts from a particular email account if the password is given. I also did the same.  In most of the cases it did not work properly. But recently i got a contact grabber from phpclasses.org which works perfectly on Gmail, Hotmail, Rediff, Yahoo, Orkut, MySpace, Indiatimes, Linkedin , AOL and lycos

screen shot

screen shot

But the zip file i got is not well arranged, so it shows some errors . I arranged it in proper way and uploaded here:

Download:

http://sajithmr.com/downloads/grabber.zip

(Under GNU Public License)

Using this php code , you can export the email contacts as csv file.

Here is the actual source website : http://www.phpclasses.org/browse/package/3895.html

Tags: , , , , , , , , , , , , , , , , , , , ,

· · · ◊ ◊ ◊ · · ·

وظائف 2011 تحويل العملات برامج برنامج تسريع التحميل برنامج الفلاش برنامج محول الصوتيات عربي hotel 2011 زيادة رواتب العساكر 1431