PHP Classes

File: templates/linkedin/script.js

Recommend this page to a friend!
  Classes of Mike  >  PHP Socializer  >  templates/linkedin/script.js  >  Download  
File: templates/linkedin/script.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: PHP Socializer
Embed social buttons and widgets in Web pages
Author: By
Last change:
Date: 9 years ago
Size: 1,566 bytes


Class file image Download
    url: '//',
    id: '<?php echo $this->name; ?>',
    onload: function(f) {

        // Google Analytics tracking
        // @todo check if Linked in callbacks are working & update this
        var trackerName = _ga.buildTrackerName_();
        _ga.trackLinkedIn = {
            // LinkedIn callbacks seem broken, I've included these anyway...
            success: function() {
                _gaq.push([trackerName + '_trackSocial', 'linkedin', 'share', targetUrl, opt_pageUrl]);
            error: function() {
                _gaq.push([trackerName + '_trackSocial', 'linkedin', 'error', targetUrl, opt_pageUrl]);
         // If jQuery is present, bind a click event to the linked in anchor and let Google know about any clicks we capture
         if (typeof jQuery !== 'undefined') {
                _gaq.push([trackerName + '_trackSocial', 'linkedin', 'click', $(this).parents('div.coi-social-button-linkedIn').find('script').data('url')]);

        // Fade button in if desired
        if ('<?php echo $this->fadeIn ?>') {
                buttons: document.getElementsByClassName('coi-social-button-<?php echo $this->name; ?>'),
                duration: '<?php echo $this->fadeIn; ?>',
                isRendered: function(element) {
                    return element.getElementsByClassName('IN-widget').length;
For more information send a message to info at phpclasses dot org.