<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
<title>Snipplr - ginoplusio</title>
<link>http://snipplr.com/users/ginoplusio</link>
<description>Recent snippets posted on Snipplr.com</description>
<language>en-us</language>
<pubDate>Fri, 24 May 2013 03:16:04 GMT</pubDate>
<item>
<title>(MySQL) Remap values inside a MYSQL query using CASE...WHEN syntax</title>
<link>http://snipplr.com/view/67831/remap-values-inside-a-mysql-query-using-casewhen-syntax/</link>
<description><![CDATA[ <p>How to remap a value to another inside a mysql query select.</p> ]]></description>
<pubDate>Sat, 20 Oct 2012 08:14:57 GMT</pubDate>
<guid>http://snipplr.com/view/67831/remap-values-inside-a-mysql-query-using-casewhen-syntax/</guid>
</item>
<item>
<title>(PHP) Counting how many times a web link has been shared on Twitter</title>
<link>http://snipplr.com/view/67829/counting-how-many-times-a-web-link-has-been-shared-on-twitter/</link>
<description><![CDATA[ <p>Here is a function that read the number of times a url is shared on twitter.</p> ]]></description>
<pubDate>Sat, 20 Oct 2012 07:45:51 GMT</pubDate>
<guid>http://snipplr.com/view/67829/counting-how-many-times-a-web-link-has-been-shared-on-twitter/</guid>
</item>
<item>
<title>(PHP) Facebook Connect Tutorial</title>
<link>http://snipplr.com/view/67677/facebook-connect-tutorial/</link>
<description><![CDATA[ <p>I will show you how to crate an app for facebook to handle the facebook connect process on your web site.
Then I will show you the php code to perform the login on facebook and retrieve the informations you need for your site.
The last suggestion will point how to merge facebook users with your users.
Follow the link above to get the full tutoriall with text and images.</p> ]]></description>
<pubDate>Wed, 10 Oct 2012 20:39:36 GMT</pubDate>
<guid>http://snipplr.com/view/67677/facebook-connect-tutorial/</guid>
</item>
<item>
<title>(PHP) How to read facebook like count for a url with PHP</title>
<link>http://snipplr.com/view/67650/how-to-read-facebook-like-count-for-a-url-with-php/</link>
<description><![CDATA[ <p>When you add facebook like button to your site, probably, you also want to save the number of likes of your pages to your database.These data are very useful and very important because they tell you which of your articles are better than others. Moreover, these pages are better than others because the user has decided to tell his friends about it.</p> ]]></description>
<pubDate>Mon, 08 Oct 2012 22:23:36 GMT</pubDate>
<guid>http://snipplr.com/view/67650/how-to-read-facebook-like-count-for-a-url-with-php/</guid>
</item>
<item>
<title>(JavaScript) Unobtrusive Javascript Overlay</title>
<link>http://snipplr.com/view/60619/unobtrusive-javascript-overlay/</link>
<description><![CDATA[ <p>If you have to add an overlay to a site, here is a fast way to do it with an unobtrusive javascript. Add this file to your site, just before the closing body tag, and customize the overlay() function inside the js file.

This code adds a div to cover your page with an opaque layer (you can customize the color and the opacity in the css, it’s the ovContainer0 div).

After the opaque layer which made unclickable and opaque the page, it’s inserted another div over it, which is not opaque and is used to center the overlay and contain the desidered HTML (your banner or anything else). Inside this div (which is called ovContainer) there is also another div (ovBox) that is, finally, used to contain the button whit an X to close it (ovClose) and your code. The ovBox div is dinamycally centered vertically.

You can customize the CSS of the opaque layer and the overlay box, probably you will never need to customize the CSS of the ovContainer.

Here is the function that overlay the layer that you have to customize inside the overlay.js</p> ]]></description>
<pubDate>Tue, 08 Nov 2011 03:08:43 GMT</pubDate>
<guid>http://snipplr.com/view/60619/unobtrusive-javascript-overlay/</guid>
</item>
<item>
<title>(PHP) How to use Instagram photos on your site</title>
<link>http://snipplr.com/view/58083/how-to-use-instagram-photos-on-your-site/</link>
<description><![CDATA[ <p>Thanks to followgram.me you can read a public feed with your photos. Use this code to retrieve your Instagr.am photos and use them on your web.</p> ]]></description>
<pubDate>Mon, 22 Aug 2011 17:43:38 GMT</pubDate>
<guid>http://snipplr.com/view/58083/how-to-use-instagram-photos-on-your-site/</guid>
</item>
<item>
<title>(PHP) Php Function to resize video from YouTube and Vimeo</title>
<link>http://snipplr.com/view/42560/php-function-to-resize-video-from-youtube-and-vimeo/</link>
<description><![CDATA[ <p>I’ve made this function that receive the input $video string that contains the dirty embed code as it is from youtube. The second parameter $new_width (if specified) permits to resize the embed code proportionally to the width you need for your template. This function removes also unwanted tags added after the important tag (such as happens from Vimeo embeds that have a p tag after the iframe).</p> ]]></description>
<pubDate>Tue, 19 Oct 2010 21:25:47 GMT</pubDate>
<guid>http://snipplr.com/view/42560/php-function-to-resize-video-from-youtube-and-vimeo/</guid>
</item>
<item>
<title>(PHP) How to change Twitter's status with php and Curl without oAuth</title>
<link>http://snipplr.com/view/40287/how-to-change-twitters-status-with-php-and-curl-without-oauth/</link>
<description><![CDATA[ <p>Since the 31 of august 2010, twitter made its API more secure, stopping basic authentication calls.
So, if you used basic authentication you have to change your code and implement oAuth authentication model or you can follow this link and found a mini spider that does the work.</p> ]]></description>
<pubDate>Fri, 10 Sep 2010 22:50:21 GMT</pubDate>
<guid>http://snipplr.com/view/40287/how-to-change-twitters-status-with-php-and-curl-without-oauth/</guid>
</item>
<item>
<title>(PHP) PHP bot to get wikipedia definitions</title>
<link>http://snipplr.com/view/39711/php-bot-to-get-wikipedia-definitions/</link>
<description><![CDATA[ <p>If you need to add some content to your pages without having that content in your database you can use Wikipedia API. You can, for example, need to add automatically a simple description to a city name, or to a band name. Or you could need to add the definition of some technological terms. You can do all of this things using Wikipedia, since Wikipedia has an API that easily lets you do it.</p> ]]></description>
<pubDate>Mon, 30 Aug 2010 20:58:14 GMT</pubDate>
<guid>http://snipplr.com/view/39711/php-bot-to-get-wikipedia-definitions/</guid>
</item>
<item>
<title>(PHP) How to send push notification to iPhone with PHP and pushme.to</title>
<link>http://snipplr.com/view/38798/how-to-send-push-notification-to-iphone-with-php-and-pushmeto/</link>
<description><![CDATA[ <p>Push service is a technology that allows you to send alerts/notifications to a mobile device. Blackberry has its own push service, iPhone has its own, and also Android devices has their own push services (you can learn more on Wikipedia page).\r\nPush notifications are like “sms” but they are free if you have a flat service contract on your mobile.\r\nI want to send push to my iPhone, but I’m not able to develop an iPhone application that receive push alerts, and I don’t want to send only email alerts.\r\nOk, let’s recap: I have an iPhone and I need to send notifications to my mobile from my PHP scripts.\r\nSo I’ve looked deeply in the appStore and I’ve found pushme.to application. This application is made to talk with friends trought web sites and iPhones.\r\nPushme.to is good because after you’ve registered you can go on their widget page and create a widget for your account to put on your web site. Well, in this post, I will not use this widget for my web site (I don’t want users to write me), but I will use their widget with a mini web bot to send alerts directly to my device through a PHP function.\r\nIt happens this way: the cron job calls my php script, my script uses a small bot to call pushme.to widget, pushmeTo sends alerts to my iPhone...</p> ]]></description>
<pubDate>Tue, 10 Aug 2010 02:26:16 GMT</pubDate>
<guid>http://snipplr.com/view/38798/how-to-send-push-notification-to-iphone-with-php-and-pushmeto/</guid>
</item>
<item>
<title>(PHP) Parsing Flickr Feed with PHP tutorial</title>
<link>http://snipplr.com/view/35328/parsing-flickr-feed-with-php-tutorial/</link>
<description><![CDATA[ <p>This is a small tutorial that guide you to use a small php function that parse the flickr\'s feed and output a simply thumbs gallery. Than you can customize the output using css style sheets. Here you can find the functions, follow the link to read the tutorial.</p> ]]></description>
<pubDate>Sun, 30 May 2010 17:19:29 GMT</pubDate>
<guid>http://snipplr.com/view/35328/parsing-flickr-feed-with-php-tutorial/</guid>
</item>
<item>
<title>(Other) Redirect every url to a page as querystring with .htaccess</title>
<link>http://snipplr.com/view/33725/redirect-every-url-to-a-page-as-querystring-with-htaccess/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Mon, 03 May 2010 03:05:40 GMT</pubDate>
<guid>http://snipplr.com/view/33725/redirect-every-url-to-a-page-as-querystring-with-htaccess/</guid>
</item>
<item>
<title>(Other) Add and remove www to urls through .htaccess</title>
<link>http://snipplr.com/view/33724/add-and-remove-www-to-urls-through-htaccess/</link>
<description><![CDATA[ <p>Add and remove www to urls through .htaccess with mod_rewrite</p> ]]></description>
<pubDate>Mon, 03 May 2010 03:03:55 GMT</pubDate>
<guid>http://snipplr.com/view/33724/add-and-remove-www-to-urls-through-htaccess/</guid>
</item>
<item>
<title>(Other) Htaccess to redirect all calls to mp3 files to a PHP proxy</title>
<link>http://snipplr.com/view/33723/htaccess-to-redirect-all-calls-to-mp3-files-to-a-php-proxy/</link>
<description><![CDATA[ <p>Redirects all calls to mp3 files to a proxy (usefull fr example to track stats on db) the +FollowSymlinks should be already setted, but if it isnt' this setting with use it. FollowSymlinks must be on to use the rewrite engine.</p> ]]></description>
<pubDate>Mon, 03 May 2010 03:02:26 GMT</pubDate>
<guid>http://snipplr.com/view/33723/htaccess-to-redirect-all-calls-to-mp3-files-to-a-php-proxy/</guid>
</item>
<item>
<title>(PHP) Remove slashes from $_GET and $_POST arrays</title>
<link>http://snipplr.com/view/33280/remove-slashes-from-get-and-post-arrays/</link>
<description><![CDATA[ <p></p> ]]></description>
<pubDate>Tue, 27 Apr 2010 04:44:40 GMT</pubDate>
<guid>http://snipplr.com/view/33280/remove-slashes-from-get-and-post-arrays/</guid>
</item>
<item>
<title>(PHP) How to get images from Google images with PHP</title>
<link>http://snipplr.com/view/30524/how-to-get-images-from-google-images-with-php/</link>
<description><![CDATA[ <p>This simply php function will retrieve the links of the images from Google Images searched with a keyword. The function just calls images.google.it and parse the html to find the url of the images, in this case the urls are stored in the javascript, so the parsing doesn’t use any html tag to find data. It builds an array of urls and return it.</p> ]]></description>
<pubDate>Tue, 30 Mar 2010 07:36:57 GMT</pubDate>
<guid>http://snipplr.com/view/30524/how-to-get-images-from-google-images-with-php/</guid>
</item>
<item>
<title>(PHP) PHP parse url, mailto, and also twitter’s usernames and arguments</title>
<link>http://snipplr.com/view/29556/php-parse-url-mailto-and-also-twitters-usernames-and-arguments/</link>
<description><![CDATA[ <p>This small function receive a text as input and returns an html text with links if the source text contains urls (http://www… but also ftp://… and every other protocol), emails, twitter’s usernames (with @ at the beginning) and also twitter tags (with # at the beginning).</p> ]]></description>
<pubDate>Wed, 10 Mar 2010 14:43:43 GMT</pubDate>
<guid>http://snipplr.com/view/29556/php-parse-url-mailto-and-also-twitters-usernames-and-arguments/</guid>
</item>
<item>
<title>(jQuery) How to change dynamically input type password to show description inside field</title>
<link>http://snipplr.com/view/29555/how-to-change-dynamically-input-type-password-to-show-description-inside-field/</link>
<description><![CDATA[ <p>Sometime designers put form labels and instrucions into html inputs. One of the common uses is for login boxes when there’s not much space. I wrote a small jQuery plugin which dynamically replaces selected  fields with  fields displaying a chosen value. The replace procedure works forth and back: when the user clicks on the input field it is transformed into a ; if the user inserts some text, then the field remains masked, if he/she does not insert anything, the field is replaced again, letting the chosen value be visible again.</p> ]]></description>
<pubDate>Wed, 10 Mar 2010 14:31:48 GMT</pubDate>
<guid>http://snipplr.com/view/29555/how-to-change-dynamically-input-type-password-to-show-description-inside-field/</guid>
</item>
<item>
<title>(PHP) how to change facebook status with php</title>
<link>http://snipplr.com/view/29070/how-to-change-facebook-status-with-php/</link>
<description><![CDATA[ <p>Changing Facebook Status with PHP, download the Mini Bot PHP class from the blog http://www.barattalo.it</p> ]]></description>
<pubDate>Mon, 01 Mar 2010 15:45:46 GMT</pubDate>
<guid>http://snipplr.com/view/29070/how-to-change-facebook-status-with-php/</guid>
</item>
<item>
<title>(PHP) Retrieve Twitter info from php</title>
<link>http://snipplr.com/view/29069/retrieve-twitter-info-from-php/</link>
<description><![CDATA[ <p>PHP function of mini bot class that lets you retrieve twitter infos from twitter nickname.
($this->attr method is part of the Mini Bot Class)</p> ]]></description>
<pubDate>Mon, 01 Mar 2010 15:44:10 GMT</pubDate>
<guid>http://snipplr.com/view/29069/retrieve-twitter-info-from-php/</guid>
</item>
</channel>
</rss>