News Feed
Jobs Feed
Sections




News Archive
feed this:

9Lessons.info:
Facebook Style Tag Friends with Jquery, Ajax and PHP
August 26, 2010 @ 09:58:49

On 9Lessons.info today there's a tutorial posted by Srinivas Tamada about creating a simple "tag my friends" system (like Facebook's) with PHP, jQuery and a bit of Ajax magic.

I received a request from my reader that asked to me how to implement Facebook like tag friends in your status or update box. It is great feature to adding friends start with @ symbol. I had tried this with Jquery, Ajax and PHP, it's simple just collaboration of my previous posts.

If you want to skip to the good part, there's a demo and code download otherwise you can follow along with his code that creates a database table, includes the HTML for the interface, a backend PHP script to connect to and some CSS to make it all look a bit nicer.

0 comments voice your opinion now!
facebook friends tutorial jquery ajax demo


Jaanus' Blog:
How to retrieve remote files in your web apps and still be friends with the server
January 18, 2006 @ 07:19:36

In this post on Jaanus' blog today, they show how you can grab remote files from a server and still "remain friends" with the server.

It often happens that when you're building a web page or app, you may want to include some content from a remote server. Say that it's some statistic figure that the remote outputs as HTML or TXT and you then want to retrieve it and either do something with it or directly display as part of your own page. And you're working in PHP.

PHP provides a fancy way of opening and including files directly over HTTP, which they call "URL wrappers". As tempting as it may seem, in the long run doing remote opens with URL wrappers is not the best practice. So here's what I came up with when needing to do this kind of caching thing in my own scenarios. It requires you have the cURL module installed and that the webserver can read and write from /tmp.

They provide the short script that does the work inside a function (easy to drop into a class), and grabs the remote file, and pulls down to /tmp for the script to use. It even allows you to specify a timeout for the file, forcing the script to grab a new copy every so often...

1 comment voice your opinion now!
retrieve remote files friends with server curl timeout retrieve remote files friends with server curl timeout



Community Events









Don't see your event here?
Let us know!


example interview language podcast testing opinion tool framework introduction development database event composer object release community functional api zendframework2 code

All content copyright, 2013 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework