Mysql Table Editor
Posted by Sajith M.R in php, php source code on 04. Jun, 2009 | 2 Comments
In a php project, if we get the requirement , we usually start design and database. But the data entry procedure is very hard. In this case PhpMyadmin is a good comfort.
Here is another tool from phpguru.org , MySQL Table Editor. Using this library you can make your database table editable from your php code.
You [...]
XAJAX
Posted by Sajith M.R in php, php source code on 03. Jun, 2009 | 0 Comments
Basically using xajax “You can directly call php functions from your javascript code”
Xajax will do the rest.
For example, if you are going to write a javascript function Capitalize which captilaze your textbox content when you press a button.
Here is the pure html/javascript code for that:
=============================================
<script>
function Capitalize()
{
var t = document.getElementById(’cap’).value;
document.getElementById(’update’).innerHTML [...]
Contact Grabber
Posted by Sajith M.R in Downloads, php, php source code on 06. Nov, 2008 | 38 Comments
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, [...]
Intelligent Watermark (php + gd)
Posted by Sajith M.R in Downloads, php, php source code on 09. Aug, 2008 | 2 Comments
Online Photoshop in PHP Part (5) >>
(image after watermarked with gmail logo)
Those who haven’t seen the online photoshop tool created by me, just click here: http://www.sajithmr.com/photoshop
Today we will implement the watermarking on images using php gd library. Intelligent watermarking means, apply a logo or a watermark image on another image by measuring the color [...]
Crop Image Like Orkut
Posted by Sajith M.R in Downloads, php, php source code on 05. Jun, 2008 | 15 Comments
Online Photoshop in PHP (Series Part 4) >>
Today we will discuss about cropping of images using php and gd library.
Look at the simple example here:
http://www.sajithmr.com/photoshop-tuts/crop/simplecrop.php
$x1 = $_GET['x1'];
$y1 = $_GET['y1'];
$x2 = $_GET['x2'];
$y2 = $_GET['y2'];
$image_object = imagecreatefromjpeg(’hari.jpg’);
$image_cropped = Crop($image_object,$x1, $y1, $x2,$y2);
$temp_path = rand(1,99999).”hari.jpg”;
imagejpeg( $image_cropped,$temp_path);
header(’Location: simplecrop.php?img=’.$temp_path );
?>
Here the Crop function is doing [...]
Download Youtube Videos using PHP Code
Posted by Sajith M.R in php, php source code on 29. May, 2008 | 35 Comments
If you want to get the FLV file of any youtube video url using php code, here is the solution.
If you are a PHP Programmer and if you are working with any video website, and if you need to grab videos (FLV files) from youtube and to put it yourown site (not object embedding) [...]
Online Photoshop in PHP (Series Part 3)
Posted by Sajith M.R in php, php source code on 26. May, 2008 | 0 Comments
Resize a Photo >>
Today we will implement hows to resize photo into a particular width and height (or keeping aspect ratio)
See the live example from: http://www.sajithmr.com/photoshop-tuts/resize/resize.php
You need to install php-gd library to do this. To functions, imagecreatetruecolor and imagecopyresampled will do the resizing.
Those who have not seen the Online Photo Editing tool yet, have a [...]
Online Photoshop in PHP (Series Part 2)
Posted by Sajith M.R in php, php source code on 21. May, 2008 | 1 Comment
Implementation of the Browse Photos Area >>
Today we will implement the browse photos area of online photoshop
Those who haven’t seen the online photo editing tool, click on the above icon (baloon)
You can see the browse area implementation here: http://www.sajithmr.com/photoshop-tuts/browse.php
What you need for this is 4 php functions: is_dir , opendir, readdir, filetype
Normal [...]
Online Photoshop in PHP (Series Part 1)
Posted by Sajith M.R in php, php source code on 20. May, 2008 | 6 Comments
Introduction >>
As i announced in my birthday post: celebrating-1st-year-of-sajithmr.com , i am starting my post series How to make Photoshop Express in PHP
Before we starting the step by step procedure, have a look at : http://www.sajithmr.com/photoshop/index.php
This is a basic version of online photo editing tool.
You can either upload a photo to this tool [...]
PHP post without curl
Posted by Sajith M.R in Downloads, php, php source code on 04. Apr, 2008 | 8 Comments
You can simulate the post method using php without the help of curl library.
download full source code:
See the code below:
function do_post_request($url, $data, $optional_headers = null) {
$params = array(’http’ =>; array(’method’ =>; ‘POST’,
‘content’ =>; $data
));
if ($optional_headers !== null) {
$params['http']['header'] = $optional_headers;
}
$ctx = stream_context_create($params);
$fp = @fopen($url, ‘rb’, false, $ctx);
if (!$fp) {
throw new Exception(”Problem with $url, $php_errormsg”);
}
$response = [...]
OpenID Integration PHP
Posted by Sajith M.R in Downloads, php, php source code, webworld on 03. Apr, 2008 | 3 Comments
I think you know the use of OpenID. Else go here and learn
http://en.wikipedia.org/wiki/OpenID
http://openid.net/what/
http://openiddirectory.com/
In a nutshell, the OpenID technology makes life simpler by having only one username and password to remember – yahoo OpenID tour
Here the php source code for integrating your site with OpenID. If you have a website which has user login / [...]
Simple steps to create a wordpress theme
Posted by Sajith M.R in php, php source code, webworld on 03. Apr, 2008 | 9 Comments
Wordpress theme is merely a folder which is to be placed in wp-content folder of wordpress hierarchy .
The basic files needed in that theme folder is index.php and style.css
In this style.css the following lines are very essential.
/*
Theme Name: Theme Namet
Theme URI: http://www.sajithmr.com/
Description: Details of your theme
Author: Author name
Author URI: http://www.sajithmr.com/
This theme was designed and built [...]


