The Little Guy Posted June 4, 2011 Share Posted June 4, 2011 I am building a Library filled with common tasks, what common tasks do you normally do when building a website? Some current tasks/features the library has: - Plugins - Plugin session manager (so plugin sessions names don't get crossed) - Threading (run multiple tasks at once) - HTTP (get info from webpage) - get_http() (give it a url and it will save the page title, links, and clean version of the page into some properties) - MySQL (Some mysql functions) - mysql_get_one() (gets the item at 0,0 from a returned result) - mysql_get_row() (gets a row and returns it as an array) - mysql_query() (executes a mysql query) - mysql_field() (returns the value of a field) - File methods - save() (saves a file) - open() (opens a file) - duplicate() (duplicates a file) - truncate() (truncates a file) - read() (reads content from a file) - delete() (deletes a file) So basically to do something kinda fancy... require_once '../../phpLive/phpLive.php'; $url = "http://sarcasticgamer.com/wp/wp-content/uploads/2008/02/firefly.jpg"; // Get info about the URL $info = (object)parse_url($url); // Get the pathinfo so we can get the filename: $pi = (object)pathinfo($info->path); // The main part of the library: $_live->thumbDir = 'thumbs'; $_live->get_http($url)->save($pi->basename)->makeThumb($pi->basename, 100); The above code will get the image from the url, save it, and then make a thumb nail 100px wide. So what I would like to know, is what other features should I add to this library to make it better!? Any thoughts/suggestions would be great! Quote Link to comment Share on other sites More sharing options...
The Little Guy Posted June 9, 2011 Author Share Posted June 9, 2011 Anyone have some suggestions? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.