Absolute vs. Relative Paths

November 30, 2008

When referancing any external item, be it an included file in PHP, a CSS document in HTML, or an image, you have the choice of using either an absolute or relative path. An absolute path says where a file is starting from the root directory of the computer. Such paths are always correct, no matter the location of referencing (parent) file. For example, a PHP script can include a file using 

include( 'c:/php/includes/file.php');
include( '/usr/xyz/includes/file.php');

Assuming file exists in the named location, the inclusion will work (barring any permissions issues). The second example, in case you’re not familiar with the syntax, would be a Unix ( and Mac OS X) absolute path. Absolute paths always start with something like c:/ or / .

A relative path uses the referencing (parent) file as the starting point. To move up one folder, use two periods together. To move into folder, use its name followed by a slash. So assuming the current script is in the www/ex1 folder and you want to include something in www/ex2, the code will be:


A relative path will remain accurate, even if moved to another server, as long as the file keep their current relationship.

I hope this tutorial was helpful. if you any have any question don’t hesitate to ask.


What Are Dynamic Web Sites

November 29, 2008

Dynamic Web sites are flexible and potent creatures, more accurately described as applications than merely sites.

Dynamic Web sites:


  • Respond to diffrent parameters (for example, the time of day or version of the visitors web browser)
  • Have a “memory”, allowing for user registeration and login, e-commerce, and similar processes
  • Almost always have HTML forms, so that people can preform searches, provide feedback, and so forth
  • Often have an interface where adminstrators can manage the site’s content 
  • Are easier to maintain, upgrade, and build upon than statically made sites   
There are manay technologies available for creating a dynamic Web sites. The most common are ASP.NET (Active Server Pages, a Microsoft construct), JSP (Java Server Pages), ColdFusion, Ruby on Rails, and PHP. Dynamic Web sites don’t always rely on database, but more and more of them do, particularly as excellent database applications like MySQL are available at little to no cost. 

Lesson 1 : Getting to know PHP [part 1]

November 27, 2008

In this lesson you will find out what php is all about and see what it is able to do.

PHP Basics

PHP is a programming language that was designed for creating dynamic websites. it slots into your web server and processes instructions contained in a web page before that page is sent through to your web browser. Certain elements of the page can therefore be generated on the fly so that the page changes each time it is loaded. For instance, you can use PHP to show the current date and time at the top of each page in your site, as you’ll see later in this lesson.

The name PHP is a recursive acronym that stands for PHP: Hypertext Preprocessor. It began life called PHP/FI, the “FI” part standing for Forms interpreter . Though the name was  shortened a while back, one of the PHP’s most powerful features is how easy it becomes to process data submitted in HTML forms. PHP can also talk to various database systems, giving you the ability to generate a web page based on SQL query.

For example you could enter a search keyword into a form field on web page, query a database with this value, and produce a page of matching results. You will have seen this kind of application many times before, at virtually any online store as well as many websites that do not sell anything, such as search engines.

The PHP language is flaxible and fairly forgiving, making it easy to learn even if you have not done any in the past . if you already know another language, you will almost certainly find similarities here. PHP looks like a cross between C, Perl and Java, and if you with any of these, you will find that you can adapt you existing programming style to PHP with little effort.

Server-Side Scripting

The most important concept to learn when you starting out with PHP is where exactly it fits into the grand scheme of things in a web enviroment.

When you understand this, you will understand what PHP can and can’t do.

The PHP module attaches to web server, telling it that files with a particular extention should be examined for PHP code. Any PHP code found in the page is executed – with any PHP code replaced by the outputit produces – before the web page is sent to the browser.

To be countinue ….. part 2 .

Seven Ways to Better PHP Code

November 26, 2008

Seven ways to make your PHP code more better and better 

Just wacth the vedio and give your comment .

TwitterFox – Firefox extension for Twitter

November 26, 2008

TwitterFox is a Firefox extension that notifies you of your friends’ tweets of Twitter. (previously known as TwitterNotifier )

This extension adds a tiny icon on the status bar that notifies you when your friends update their tweets. Also it has a small text input field to update your tweets.

New feature of Version 1.7.2

  • Fixed an issue in which favorite function doesn’t work
  • Fixed an issue in which scroll position is reset when TF receives new tweets
Install TwitterFox
Just enjoy it
For more information click here

Using Twitter More Effectively

November 26, 2008

Some bloggers use Twitter to promote their blogs, or use it separately in order to gain more followers.  However, majority of them don’t effectively use the service for what it was intended, so here are a few tips on how to effectively manage using Twitter.

  1. Ask your readers to follow your tweets either via your email newsletter, or an invitation text & link on your blog.
  2. Use WordPress plugins like TwitterTools to update your tweets on your blog.
  3. Participate in the communities within your niche which will naturally draw followers to you. Define your target niche, and eliminate the rest. Follow less but targeted people.
  4. Don’t be too noisy. Keep the noise down. Do not follow noisy people, just purge those people.
  5. Star your favorite tweets. This will help you to save them for future use.
  6. Watch Tao of Twitter by Ed Dale.
  7. Prefer easy to use twittering tools like Twshot or TwitterFox
  8. Your Twitter feed is also available as an RSS feed. Check the bottom of your Twitter homepage, and you will notice your Twitter RSS feed. Get your Twitter RSS feed, and send it to RSS directories.
  9. Customize your Twitter background image. Look at mine: Mert Erkal. It is not so difficult. Believe me it is worth spending your time. Do not forget to publish your blog’s logo and URL for branding.
  10. Integrate your Twitter updates with Facebook using TwitterSync. This little application will publish your latest tweet as your Facebook status.
  11. If you have time, I suggest you to take a look at Caroline Middlebrook’s Twitter Guide.

How do you use Twitter? Please share your best practices with me.

BlueprintCSS hot CSS framework

November 24, 2008




Spend your time innovating not replicating 

Blueprint is a CSS framework, which aims to cut down on your CSS development time. It gives you a solid CSS foundation to build your project on top of, with an easy-to-use grid, sensible typography, and even a stylesheet for printing.

For more information just visit