by Mr Me
on April 22, 2011
in general, php
I recently started a new URL shortener service. If you’re bored with old short-url services, you can start using this http://zip.ms Here you can set your-own custom alias, than some random string. I used Phurl library to create this website. I have no spam guard added in the site, please be a real human, I [...]
by Mr Me
on January 6, 2011
in php
I recently use getId3 library to manipulate audio files from PHP. It is very accurate than FFMPEG. For example, FFMPEG is not helpful for audio files having VBR (Various Bit Rate). It returns error max_analyze_duration reached OR “Estimating duration from bitrate, this may be inaccurate” But by using getId3, we can retrieve detailed information about [...]
by Mr Me
on October 1, 2010
in quick-tips
Recently I read an article from IBM regarding the usage of Object Oriented Programming in PHP in a proper way. For an average PHP developer, I recommend it is good to read: Read Article Here I also went this link to understand more about abstract class and interface class Share
by Mr Me
on September 30, 2010
in quicktips
If you develop website using some framework (Symfony, Codeigniter or Zend etc), you need to play with several system defined objects like routing objects, session objects etc. To see what are the functions available inside an object on run time without referring the parent class documentation, here is a trick: print_r( get_class_methods(get_class($YourObject))); Now you can [...]
by Mr Me
on September 8, 2010
in php
Recently I tried Symfony 2 Sandbox for one of my projects. I realised this fact that Symfony 2 is so powerful because they restructured the Symfony 1.4 architecture and made a system like Codeigniter Framework. I wrote a post some months back about Codeigniter vs Symfony here. I need to re-edit that post now, because, [...]
by Mr Me
on July 15, 2010
in general
As you all know recent changes in privacy issues made Facebook to change their basic API and added some security concerns. From my best practise, most of the old applications are safe, but you will be in trouble when you create new application. By default you cannot access user’s photos, profile pictures , albums etc. [...]
album, albums, api, documentation, empty string, error, facebook, featured, functions, graph, graph api, help, missing, permission, photos, php, privacy, problem, rest, rest api, security
by Mr Me
on July 15, 2010
in general
Like the old REST API, you don’t need to add 2-3 files for Facebook PHP SDK. The new graph api comes in a single file which is located at http://github.com/facebook/php-sdk/ Copy the facebook.php file in to your webroot and include this file in your php code. require_once(‘facebook.php’); To work fully functional, you need CURL and [...]
api, apt-get, blank page, curl, error, facebook, graph, install, install curl, install json, json, pear, pecl, php, sdk, solution
by Mr Me
on July 8, 2010
in php
There is a very strange issue with PHP session when you prefer session to save in files other than database (normal session). The problem is: some times you can access all the saved session values from $_SESSION and sometimes it returns a empty array. If you refresh 10 times, perhaps 4 times you will get [...]
$_session, asp, cloud, empty, error, php, refresh, saving, server, session, session not saving, session_save_path, session_start
by Mr Me
on June 11, 2010
in php, php source code, webworld
In PHP coding, we spend most of the time for debugging. Either we use echo, print_r or var_dump to check variable values or check whether a particular function is executing or not. These all things are outputting something to browser. This is not applicable in case of redirection, or image processing (GD) or sometimes with [...]
by Mr Me
on June 6, 2010
in general, php
If you aim to create a multi-language website using PHP + Mysql , remember the following tips. You can use mysql database for this purpose rather than using separate language files as usual content management system does. You can create a table with following structure for this purpose.Table: muli-lang string_id: page_id: en: arb: fr: Here [...]
by Mr Me
on May 12, 2010
in php, php source code
Here is a php function which returns from and to date as an array for a range: <?php function get_rangeof_dates($time_frame = ‘all_time’) { $from_date = ”; $to_date = ”; switch($time_frame) { case ‘all_time’: $from_date = ’1170-01-01 00:00:00′; $to_date = ’2250-12-31 23:59:59′; break; case ‘today’: $from_date = date(‘Y-m-d 00:00:00′); $to_date = date(‘Y-m-d 23:59:59′); [...]
algorithm, date, download, from date, last 7 days, last month, last quarter, last week, php, php code, range, source code, this month, this quarter, this week, this year, to date, today, yesterday
by Mr Me
on May 6, 2010
in php
This is a quick note for myself to remember some tricks while we develop a Facebook application. If you are a beginner in Facebook application development, go here first. If you an expert in Facebook development, go here. The steps in creating a facebook app. 1) Register an application in facebook 2) Add Canvas URL [...]
by Mr Me
on May 1, 2010
in php
We can create a search page for a dynamic website using Database queries and looping over resultant record sets. But what can we do if the website main contains static html files than dynamically populated content. In this case , we usually put Google search box inside website (Google custom search) Sphider is a php [...]
bot, crawl, custom search, google, google like crawl, indexing, location search, php, search, search engine, search html, search static, static page, yahoo
by Mr Me
on August 18, 2009
in php
We like firebug , We like PHP , if so, We also begin to like FirePHP !!! Using firephp , you can debug your php code. Firephp is a firefox plugin which works on firebug console. In our php life, we know we can use echo function to print or debug the value of a [...]
by Mr Me
on June 4, 2009
in php, php source code
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 [...]