•  
  • Archives for javascript (3)

PHP Class to Cache Remote Content by URL

Categories: PHP, WordPress
Comments: No Comments
Published on: Thursday, February 14th, 2013

While developing the NextGEN Facebook OG plugin for WordPress, which adds social buttons from Facebook, Google+, LinkedIn, etc. to content and pages (along with several other features), I found the response time from these websites to be disappointing at times. When speed testing the pages of my websites, the JavaScript and images from these social elements would sometimes be a significant part of the total page load time. You can’t really save a copy of these files and serve them yourself, because they are frequently updated. You could create a cronjob to update them on a regular basis, but the maintenance of this can be cumbersome (as you add or remove files, etc.). It’s much easier to use a PHP method that caches and refreshes the remote files, and translate the URL at the same time. For example, something like:

Continue reading…

Asynchronous JavaScript for Social Website Buttons

Categories: JavaScript
Comments: 2 Comments
Published on: Saturday, January 19th, 2013

Every social website offers some-kind of JavaScript code to insert their button on webpages. Unfortunately, there’s no standard when it comes to the JavaScript code itself — some, like Google+’s +1 button are fairly sophisticated, with different ways to load and render the button, and others like LinkedIn, offer just a simple JavaScript URL to fetch. Here are Google+ and LinkedIn’s suggested buttons for comparison.

Continue reading…

Conceal Email Address with JavaScript

Comments: No Comments
Published on: Saturday, September 29th, 2012

I wrote this perl script years ago when I needed to include my email address on a webpage, but also conceal it from spam bots and spiders.

Continue reading…

page 1 of 1
Freelance UNIX SysAdmin
20121006-095055-jwolfe-49

Looking for a Sr UNIX Systems Administrator specializing in Systems Integration? I may be available for freelance or contract work, either remotely or on-site. You can contact me by email at jsm@surniaulula.com to discuss solutions specific to your needs.

  • Location : Montreal QC, Canada
  • Availability : 4-8 hrs / week freelance

Continue reading…

Social Pages and Feeds
FacebookGooglePlusLinkedInRSS