Posts In "PHP"

PHP Tutorial Collection: Build Your Own PHP Framework

October 1st, 2011 by aditia rahman / 4 Comments  

     

In today world of web development, we cannot escape the term of a framework, whether in server side or client side scripting, PHP framework are the most common used in today application, but there are so many choices of PHP Framework that can a developer confuse what to choose, especially for the beginner.

php framework tutorial

Here a collection of tutorial of creating your own PHP framework in case you don’t satisfied enough of the available framework or maybe you have more time to create your own, these tutorial might help you to get started.

Prevent Login With Same ID

June 6th, 2011 by aditia rahman / 5 Comments  

     

Today post I want to share a little idea to avoiding two or more different user login using the same user ID or username in one application, this feature might be implemented in some specific application that have many restriction and tracking of logged user action in the system. In this post I am not showing any full code to test, just my simple thought.

Users Table

The users table is most commonly used name in application, and the typical column name are id, username, password, first_name, last_name, etc. My idea is to adding one more field in users table that flagging if the user logged in or not. The simple SQL query might be something like this code below.

CREATE TABLE IF NOT EXISTS `users` (
  `id` int(11) NOT NULL,
  `username` varchar(255) NOT NULL,
  `password` varchar(255) NOT NULL,
  `is_logged_id` int(1) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

The flag column in this example is is_logged_id field set to INT type with one length, this will only consist the value between 1 (user logged in) or 0 (user not logged in).

5 Free PHP Scripts To Start Video Sharing Site

May 3rd, 2011 by aditia rahman / 1 Comment  

     

Few months ago I collecting some free PHP scripts to create social networking site, yes maybe with common social networking feature the video sharing must be included there, but all this scripts that I mention from the start focusing just for video sharing site.

Vimp

The community edition of Vimp available for free download and free just for personal and non-commercial use. The ViMP flash player can also be integrated into other webpages without the slightest effort, due to the automatically generated embed code

vimp

Getting Started With Doctrine 2: Database Abstraction Layer

March 7th, 2011 by aditia rahman / No Comments  

     

doctrine logoDoctrine Project is a set of PHP libraries that focused on providing persistence services and related functionality. The projects are a Object Relational Mapper and the Database Abstraction Layer. I want to discuss a little about using Doctrine 2 Database Abstraction Layer (DBAL), this is an important thing if we want to learn doctrine from the basic, before we move further to ORM, a Database Abstraction Layer is something that PDO handle in PHP, and what make me interested about doctrine is because their presentation statement, which it said the insert performance is better than raw php code that using mysql_query function.

Free PHP Social Network Script Collection

February 14th, 2011 by aditia rahman / 16 Comments  

     

Have you ever thinking to starting your own online community, it becoming easier these day, there are so much available free CMS to download, maybe this list can be use as a consideration for everyone who want to start online community but don’t want to start from scratch, but still there are always some learning curve to take to mastering of each CMS.

Dolphin

Created by BoonEx, Dolphin is CMS focus on social community feature, it been on the this field for quite some time, it have many features such as video, chat, mailbox, forum, photos, blogs, store, events, and many more, and some features for admin section like membership and access levels, customizable database field and form, etc, also have hundred extensions from the community

Example site: [ Apostolic Singles Network, Jam2gether ]

boonex-dolphin

Basic PHP Image Watermark With GD Library

February 1st, 2011 by aditia rahman / 3 Comments  

     

For today just wanna go back to a little PHP code again, I want share to creating a very basic image watermarking in PHP, watermark  feature are already widely used in some popular digital art, and photo websites like istockphotos, deviantart and any other sites, that maybe I don’t even know. Now here it goes, first make sure you have GD installed with PHP, you can check on your default phpinfo page using <?php phpinfo(); ?>, or you can use this php script

if (!function_exists("gd_info")) {
	echo "GD not installed";
} else {
	echo "GD installed";
}

Google Web Seach With ExtJS Grid and PHP

January 24th, 2011 by aditia rahman / 1 Comment  

     

This time I want to make a simple example in displaying google web search result in ExtJS grid, other ExtJS component that can be used to displaying this result is dataview, but grid is more common in displaying data in ExtJS, to use google search API you have to signup to get an API key, one key is only for one domain.

Google API Key

Digg Like URL Submitter Using JQuery and PHP

January 18th, 2011 by aditia rahman / 16 Comments  

     

Today I want to create something that fetching the submitted url data, some kind that many social bookmarking have, beside facebook, the other famous one is digg, this image below is something that I share in this post.

Not all feature I create, like fetch the url images, auto submit when user paste an url, etc.  But I make the look and feel like a digg style, digg use very cool blue color combination.

Simple Guest Book With Sencha Touch and PHP

January 7th, 2011 by aditia rahman / 35 Comments  

     

A Guest Book application is one of the oldest tutorial in programming, I remember when I first learning PHP, guestbook simple guestbook application give me a good example to show how the the PHP script communicating with the html interface including the javascript. Now I want port it in Sencha Touch interface, this example will be very simple there no validation, only insert data and show existing data.

Building RSS Reader With Sencha Touch and PHP

December 18th, 2010 by aditia rahman / 10 Comments  

     

Sencha Touch is one of the mobile web appication framework available that we can download for free, it targeted for iPhone, Android or Tablet devices, if you have some experience with ExtJS, I believe you have one advantage in learning Sencha Touch, most of the component, code structure built similar with ExtJS.  This is my first bite, tasting sencha touch I have created RSS reader that read from FeedBurner .

Ok lets get our finger dirty, first I created the main html file, this will include the sencha touch files (javascript and css) and my custom script for creating this application, this main html file I called rss-list.html

<!DOCTYPE html>
<html>
<head>
	<title>RSS List</title>
	<link rel="stylesheet" href="sencha-touch/resources/css/sencha-touch.css"/>
	<script type="text/javascript" src="sencha-touch/sencha-touch-debug.js"></script>
	<script type="text/javascript" src="apps.js"></script>
</head>
<body>
</body>
</html>