Social Media Flying Icons | Floating Social Media Icon - Version 4.2.2

Version Description

= Social Media Floating Icons - 4.2.2 = * Fix - Perfomance Improvements * Fix - Optimized Loading Speed

= Social Media Floating Icons - 4.2.1 = * Fix - Perfomance Improvements * Fix - Update Bug Fixes

= Social Media Floating Icons - 4.2 = * Fix - Perfomance Improvements * Fix - Update Bug Fixes * New Feature - Easy Option to Install Addons

= Social Media Floating Icons - 4.1.4 = * Fix - Perfomance Improvements

= Social Media Floating Icons - 4.1.3 = * Fix - Perfomance Improvements * 6 New Icon Styles * Instagram Support Added * Code Improvements * Fixes for wordpress deprecated functions

= Social Media Floating Icons - 4.1.2 = * Fix - Perfomance Improvements * Stable Release

= Social Media Floating Icons - 4.1.1 = * Fix - Perfomance Improvements * Stable Release

= Social Media Floating Icons - 4.1 = * New - Added Translation Support * Fix - Perfomance Improvements * New - Addon Support * Stable Release

= Floating Social Media Icon - 4.0 = * Total Programming Logic Changes * Perfomance Improvements * Addon Support * Optimized Speed * Improved and Solid Structure * Stable Release

= Floating Social Media Icon - 3.0 = * Big Improvements on User Interface * Perfomance Improvements * Updated Twitter Icons * Updated Google Plus Icons * Icon Links No Follow Support * Stable Release

= Floating Social Media Icon - 2.3 = * Aug 25, 2015 | NOTE: Updating Plugin Will Not Change Your Settings/Configuration.. Update With Confidence :) * Code Optimization * Stable Release

= Floating Social Media Icon - 2.2 = * Aug 19, 2015 | NOTE: Updating Plugin Will Not Change Your Settings/Configuration.. Update With Confidence :) * Security Fix * Stable Release

= Floating Social Media Icon - 2.1 = * May 30, 2015 | NOTE: Updating Plugin Will Not Change Your Settings/Configuration.. Update With Confidence :) * Optimized Codes * Performance Improvements * Stable Release

= Floating Social Media Icon - 2.0 = * April 18, 2015 | NOTE: Updating Plugin Will Not Change Your Settings/Configuration.. Update With Confidence :) * Optimized Codes * Fixed Bugs With Facebook * Stable Release

= Floating Social Media Icon - 1.3.9 = * Feb 20, 2015 | NOTE: Updating Plugin Will Not Change Your Settings/Configuration.. Update With Confidence :) * Optimized Codes * Stable Release

= Floating Social Media Icon - 1.3.8 = * Dec 25, 2014 | NOTE: Updating Plugin Wwill Not Change Your Settings/Configuration.. Update With Confidence :) * UI Design Improvements * Improved Floating Icon Display Logic * Improved Programming * Fixed Icon Display CSS Bugs * Added Width and Height Attributes to Icons SRC * Completely Removed Green Menu Highlighting * Now you can align php/shortcode icons to left, right or centre * Stable Release

= Floating Social Media Icon - 1.3.7 = * Nov 02, 2014 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Minor Bug Fixes * Stable Release

= Floating Social Media Icon - 1.3.6 = * Sep 22, 2014 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Minor Bug Fixes * Stable Release

= Floating Social Media Icon - 1.3.5 = * June 04, 2014 | NOTE: Upgrading Will Not Make Any Changes to Settings/Configurations. Upgrade With Confidence :) * Added Option to Disable Floating Icons on Mobile Devices * Theme Warning Ignore Option * Added Troubleshooting Options * Improved User Interface * Stable Release

= Floating Social Media Icon - 1.3.4 = * March 07, 2014 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Added Theme Warning Ignore Option * Optimized Codes * Updated Option Description

= Floating Social Media Icon - 1.3.3 = * January 05, 2014 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Minor Bug Fixes * Optimized Codes * Spelling Corrections

= Floating Social Media Icon - 1.3.2 = * October 10, 2013 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Stable Release * Minor Bug Fixes * Optimized Codes

= Floating Social Media Icon - 1.3.1 = * August 28, 2013 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Stable Release * Security Improvements * Bug Fixes

= Floating Social Media Icon - 1.3 = * June 26, 2013 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Stable Release * Improved UI * Improved Programming Structure

= Floating Social Media Icon - 1.2 = * February 20, 2013 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Added Option to disable highlighting menu on admin area * Added Option to disable highlighting plugin on plugin list * Improved CSS Styling * Improved Programming Structure * Stable Release

= Floating Social Media Icon - 1.1.5 = * November 29, 2012 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :) * Added Misc settings. * Now in Misc settings - You have option to fix icons displaying in vertical issue. * Added alt tags to icons. * Fixed Missing Argument Issue. * Added title tags to icon links. * Graphics Improvements

= Floating Social Media Icon - 1.1.4 = * July 14, 2012 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :).. * Added Align Option In Widget Settings * Fixed Conflict With Other Plugins Settings Menu so Acx Social Icon Menu will not Disappear

= Floating Social Media Icon - 1.1.3 = * June 01, 2012 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :).. * Optimized Images * Stable Release

= Floating Social Media Icon - 1.1.2 = * May 08, 2012 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :).. * Added Rss Feed Support * Better Icon Quality

= Floating Social Media Icon - 1.1.1 = * April 20, 2012 | NOTE: UPGRADING PLUGIN WILL NOT CHANGE YOUR SETTINGS/CONFIGURATION.. UPGRADE WITH CONFIDENCE :).. * Fixed Minor Styling Problem * Fixed Icon Size Problem on Manual Icon Display via Php

= Floating Social Media Icon - 1.1 = * April 06, 2012 * Added Code Security * Now You can have as many widgets where you can define icon size and icon design for each widget. * Now You can have Shortcode customization where you can define icon size and icon design for each shortcodes (Check Faq for more info).

= Floating Social Media Icon - 1.0.9 = * March 21, 2012 * Added Pinterest * Added drag and drop reorder option * AFTER UPDATE YOU NEED TO VISIT THE PLUGIN SETTINGS PAGE TO START SHOWING THE ICONS (Upgrade Will Not Alter Your Settings).

= Floating Social Media Icon - 1.0.8 = * March 14, 2012 * Added More Icon Designs * Fixed Minor Layout Issues

= Floating Social Media Icon - 1.0.7 = * March 12, 2012 * More Icon Theme/Style * Updated User Interface * Updated Faq * Added Google Plus Support

= Floating Social Media Icon - 1.0.6 = * March 11, 2012 * Fixed Alignment Problem When Displaying All Icons With Bigger Size

= Floating Social Media Icon - 1.0.5 = * March 10, 2012 * Major Fix For More Theme Compatibility

= Floating Social Media Icon - 1.0.4 = * March 09, 2012 * Fixed Some Reported Bugs

= Floating Social Media Icon - 1.0.3 = * Major Fix to Support Older Versions of Wordpress

= Floating Social Media Icon - 1.0.2 = * Fixed Design Icon Clarity

Download this release

Release Info

Developer Acurax
Plugin Icon 128x128 Social Media Flying Icons | Floating Social Media Icon
Version 4.2.2
Comparing to
See all releases

Code changes from version 4.2.1 to 4.2.2

acurax-social-icon.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Social Media Flying Icons | Floating Social Media Icon
4
  Plugin URI: http://www.acurax.com/products/floating-social-media-icon-plugin-wordpress/
5
  Description: Floating Social Media Icon / Social Media Floating Icons is a complete solution that help you to have Interactive Social Media Icons on your website which links to your social media profiles. The icons will catch your visitors attention by flying from top left to bottom right of your website.Its highly customizable with Drag and Drop Icon Reorder, Icon Size, Multiple Icon Styles etc.
6
  Author: Acurax
7
- Version: 4.2.1
8
  Author URI: http://www.acurax.com/home.php
9
  License: GPLv2 or later
10
  Text Domain: floating-social-media-icon
@@ -31,7 +31,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
31
  define("ACX_FSMI_BASE_LOCATION",plugin_dir_url( __FILE__ ));
32
  define("ACX_FSMI_WP_SLUG","floating-social-media-icon");
33
  define('ACX_FSMI_TOTAL_STATIC_SERVICES', 8);
34
- define('ACX_FSMI_C_VERSION', '4.2.1');
35
  include_once(plugin_dir_path( __FILE__ ).'/function.php');
36
  include_once(plugin_dir_path( __FILE__ ).'/includes/hooks.php');
37
  include_once(plugin_dir_path( __FILE__ ).'/includes/hook_functions.php');
4
  Plugin URI: http://www.acurax.com/products/floating-social-media-icon-plugin-wordpress/
5
  Description: Floating Social Media Icon / Social Media Floating Icons is a complete solution that help you to have Interactive Social Media Icons on your website which links to your social media profiles. The icons will catch your visitors attention by flying from top left to bottom right of your website.Its highly customizable with Drag and Drop Icon Reorder, Icon Size, Multiple Icon Styles etc.
6
  Author: Acurax
7
+ Version: 4.2.2
8
  Author URI: http://www.acurax.com/home.php
9
  License: GPLv2 or later
10
  Text Domain: floating-social-media-icon
31
  define("ACX_FSMI_BASE_LOCATION",plugin_dir_url( __FILE__ ));
32
  define("ACX_FSMI_WP_SLUG","floating-social-media-icon");
33
  define('ACX_FSMI_TOTAL_STATIC_SERVICES', 8);
34
+ define('ACX_FSMI_C_VERSION', '4.2.2');
35
  include_once(plugin_dir_path( __FILE__ ).'/function.php');
36
  include_once(plugin_dir_path( __FILE__ ).'/includes/hooks.php');
37
  include_once(plugin_dir_path( __FILE__ ).'/includes/hook_functions.php');
css/style.css CHANGED
@@ -2,7 +2,7 @@
2
  {
3
  position:absolute;
4
  z-index:10000;
5
- min-width: 142px;
6
  }
7
  #divBottomRight img, #acurax_si_simple img, #short_code_si_icon img
8
  {
2
  {
3
  position:absolute;
4
  z-index:10000;
5
+ /* min-width: 142px; */
6
  }
7
  #divBottomRight img, #acurax_si_simple img, #short_code_si_icon img
8
  {
function.php CHANGED
@@ -1546,6 +1546,196 @@ function acx_fsmi_saveorder_callback()
1546
  }
1547
  die(); // this is required to return a proper result
1548
  } add_action('wp_ajax_acx_fsmi_saveorder', 'acx_fsmi_saveorder_callback');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1549
  function acx_fsmi_load_plugin_textdomain() {
1550
  load_plugin_textdomain( 'floating-social-media-icon', FALSE, basename( dirname( __FILE__ ) ) . '/lang/' );
1551
  }
1546
  }
1547
  die(); // this is required to return a proper result
1548
  } add_action('wp_ajax_acx_fsmi_saveorder', 'acx_fsmi_saveorder_callback');
1549
+ // refresh
1550
+ function acx_fsmi_install_licence_refresh_callback()
1551
+ {
1552
+ if (!isset($_POST['acx_fsmi_install_licence_refresh_w_c_n'])) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
1553
+ if (!wp_verify_nonce($_POST['acx_fsmi_install_licence_refresh_w_c_n'],'acx_fsmi_install_licence_refresh_w_c_n')) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
1554
+
1555
+ $key = $licence = $id = "";
1556
+ $response_stat = "failed";
1557
+ if(ISSET($_POST['key']))
1558
+ {
1559
+ $key = $_POST['key'];
1560
+ }
1561
+ if(ISSET($_POST['licence']))
1562
+ {
1563
+ $licence = $_POST['licence'];
1564
+ }
1565
+ if(function_exists('check_acx_pfsmi_license') && !function_exists('acx_check_fsmip_offline_license'))
1566
+ {
1567
+ $result = check_acx_pfsmi_license($licence,'',true,$id);
1568
+ } else
1569
+ {
1570
+ $result = array();
1571
+ }
1572
+ if(ISSET($result["localkey"]))
1573
+ {
1574
+ $local_key = $result["localkey"];
1575
+ }
1576
+ else{
1577
+ $local_key = "";
1578
+ }
1579
+ $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
1580
+ if(is_serialized($acx_fsmip_licence_array))
1581
+ {
1582
+ $acx_fsmip_licence_array = unserialize($acx_fsmip_licence_array);
1583
+ }
1584
+ if($acx_fsmip_licence_array == "" || !is_array($acx_fsmip_licence_array))
1585
+ {
1586
+ $acx_fsmip_licence_array = array();
1587
+ }
1588
+ $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
1589
+ if(is_serialized($acx_fsmi_purchased_li_array))
1590
+ {
1591
+ $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
1592
+ }
1593
+ if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
1594
+ {
1595
+ $acx_fsmi_purchased_li_array = array();
1596
+ }
1597
+ if(ISSET($result["status"]))
1598
+ {
1599
+ if($result["status"] == 'Active')
1600
+ {
1601
+ if(ISSET($acx_fsmip_licence_array[$key]))
1602
+ {
1603
+ if($local_key != "")
1604
+ {
1605
+ $acx_fsmip_licence_array[$key]['local_key'] = $local_key;
1606
+
1607
+ if(!is_serialized($acx_fsmip_licence_array))
1608
+ {
1609
+ $acx_fsmip_licence_array = serialize($acx_fsmip_licence_array);
1610
+ }
1611
+ update_option('acx_fsmip_licence_array',$acx_fsmip_licence_array);
1612
+
1613
+ }
1614
+ }
1615
+
1616
+ }
1617
+ $acx_fsmi_purchased_li_array[$licence]['status'] = $result['status'];
1618
+ if(!is_serialized($acx_fsmi_purchased_li_array))
1619
+ {
1620
+ $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
1621
+ }
1622
+ update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
1623
+ $response_stat = "success";
1624
+ }
1625
+ echo $response_stat;
1626
+ die();
1627
+ }
1628
+ add_action("wp_ajax_acx_fsmi_install_licence_refresh","acx_fsmi_install_licence_refresh_callback");
1629
+ function acx_fsmi_license_refresh_with_forcing($acx_license,$addon_key)
1630
+ {
1631
+ $acx_fsmi_ip = isset($_SERVER['SERVER_ADDR']) ? $_SERVER['SERVER_ADDR'] : $_SERVER['LOCAL_ADDR'];
1632
+ $acx_fsmi_domain = $_SERVER['SERVER_NAME'];
1633
+ $acx_fsmi_directory = dirname(__FILE__);
1634
+ $acx_fsmi_args = array(
1635
+ 'action' => 'acx-li-check-latest-version',
1636
+ 'method' => 'addon_activation',
1637
+ 'directory' => $acx_fsmi_directory,
1638
+ 'unique_id' => $addon_key,
1639
+ 'domain' => $acx_fsmi_domain,
1640
+ 'ip' => $acx_fsmi_ip,
1641
+ 'licence' => $acx_license
1642
+ );
1643
+ $acx_fsmi_unique_id = "";
1644
+ $response_stat = "failed";
1645
+ $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
1646
+ if(is_serialized($acx_fsmip_licence_array))
1647
+ {
1648
+ $acx_fsmip_licence_array = unserialize($acx_fsmip_licence_array);
1649
+ }
1650
+ if($acx_fsmip_licence_array == "" || !is_array($acx_fsmip_licence_array))
1651
+ {
1652
+ $acx_fsmip_licence_array = array();
1653
+ }
1654
+ $acx_fsmip_retry_array = get_option('acx_fsmip_retry_array');
1655
+ if(is_serialized($acx_fsmip_retry_array))
1656
+ {
1657
+ $acx_fsmip_retry_array = unserialize($acx_fsmip_retry_array);
1658
+ }
1659
+ if($acx_fsmip_retry_array == "")
1660
+ {
1661
+ $acx_fsmip_retry_array = array();
1662
+ }
1663
+ if(!is_array($acx_fsmip_retry_array))
1664
+ {
1665
+ $acx_fsmip_retry_array = array();
1666
+ }
1667
+ if(ISSET($acx_fsmip_retry_array[$acx_license]['activation_licence_check']))
1668
+ {
1669
+ if($acx_fsmip_retry_array[$acx_license]['activation_licence_check'] >= 3)
1670
+ {
1671
+ $retry = false;
1672
+ }
1673
+ }
1674
+ if($retry == true)
1675
+ {
1676
+ $response = acx_fsmi_licence_activation_api_request( $acx_fsmi_args );
1677
+ $response = json_decode($response, true);
1678
+ }
1679
+
1680
+ if(!ISSET($response['response_status']) && !ISSET($response['status']))
1681
+ {
1682
+ if(ISSET($acx_fsmip_retry_array[$acx_license]['activation_licence_check']))
1683
+ {
1684
+ $acx_fsmip_retry_array[$acx_license]['activation_licence_check'] = $acx_fsmip_retry_array[$acx_license]['activation_licence_check'] + 1;
1685
+ }
1686
+ else{
1687
+ $acx_fsmip_retry_array[$acx_license]['activation_licence_check'] = 1;
1688
+ }
1689
+ }
1690
+ else
1691
+ {
1692
+ if($response['response_status'] == "success" && $response['status'] == "Active")
1693
+ {
1694
+ $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
1695
+ if(is_serialized($acx_fsmi_purchased_li_array))
1696
+ {
1697
+ $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
1698
+ }
1699
+ if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
1700
+ {
1701
+ $acx_fsmi_purchased_li_array = array();
1702
+ }
1703
+ $acx_fsmi_unique_id = trim($response['unique_id']);
1704
+ $acx_fsmi_purchased_li_array[$acx_license] = array(
1705
+ 'slug' => $response['slug'],
1706
+ 'status' => $response['status'],
1707
+ 'download_dynamic_url' => $response['download_dynamic_url']
1708
+ );
1709
+ // update licence array
1710
+
1711
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['addon_name'] = $response['name'];
1712
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['licence_code'] = $acx_license;
1713
+ if($response['localkey'] != "")
1714
+ {
1715
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['local_key'] = $response['localkey'];
1716
+ }
1717
+ if(!is_serialized($acx_fsmip_licence_array))
1718
+ {
1719
+ $acx_fsmip_licence_array = serialize($acx_fsmip_licence_array);
1720
+ }
1721
+ update_option('acx_fsmip_licence_array',$acx_fsmip_licence_array);
1722
+ if(!is_serialized($acx_fsmi_purchased_li_array))
1723
+ {
1724
+ $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
1725
+ }
1726
+ update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
1727
+ $acx_fsmip_retry_array[$acx_license]['activation_licence_check'] = 0;
1728
+ if(!is_serialized($acx_fsmip_retry_array))
1729
+ {
1730
+ $acx_fsmip_retry_array = serialize($acx_fsmip_retry_array);
1731
+ }
1732
+ update_option('acx_fsmip_retry_array',$acx_fsmip_retry_array);
1733
+ $response_stat = $response['response_status'];
1734
+ }
1735
+ }
1736
+
1737
+ return $response_stat;
1738
+ }
1739
  function acx_fsmi_load_plugin_textdomain() {
1740
  load_plugin_textdomain( 'floating-social-media-icon', FALSE, basename( dirname( __FILE__ ) ) . '/lang/' );
1741
  }
includes/acx-fsmi-licence-activation.php CHANGED
@@ -8,8 +8,7 @@ if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array)
8
  {
9
  $acx_fsmi_purchased_li_array = array();
10
  }
11
- if(!empty($acx_fsmi_purchased_li_array))
12
- {
13
  if ( ! class_exists( 'ACX_FSMI_LICENCE_TGM_Plugin_Activation' ) ) {
14
 
15
  /**
@@ -1224,7 +1223,7 @@ if(!empty($acx_fsmi_purchased_li_array))
1224
  'activate' => '',
1225
  'dismiss' => $this->dismissable ? '<a href="' . esc_url( wp_nonce_url( add_query_arg( 'acx_fsmi_licence_tgmpa-dismiss', 'dismiss_admin_notices' ), 'acx_fsmi_licence_tgmpa-dismiss-' . get_current_user_id() ) ) . '" class="dismiss-notice" target="_parent">' . esc_html( $this->strings['dismiss'] ) . '</a>' : '',
1226
  );
1227
- $link_template = '<a href="%2$s">%1$s</a><a class="acx_fsmi_install_ignore">Never show this again</a>';
1228
 
1229
  if ( current_user_can( 'install_plugins' ) ) {
1230
  if ( $install_count > 0 ) {
@@ -3804,6 +3803,14 @@ if ( ! class_exists( 'ACX_FSMI_LICENCE_TGMPA_Utils' ) ) {
3804
 
3805
  function acx_fsmi_purachase_licence_form()
3806
  {
 
 
 
 
 
 
 
 
3807
  $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
3808
  if(is_serialized($acx_fsmip_licence_array))
3809
  {
@@ -3813,6 +3820,15 @@ function acx_fsmi_purachase_licence_form()
3813
  {
3814
  $acx_fsmip_licence_array = array();
3815
  }
 
 
 
 
 
 
 
 
 
3816
  ?>
3817
  <div class="acx_fsmi_purchased_li_cvr">
3818
  <div id="acx_fsmi_license_table_list" style="width:98%;float:left;">
@@ -3834,30 +3850,45 @@ function acx_fsmi_purachase_licence_form()
3834
  <tr><td colspan="5"><?php _e('No Licence found','floating-social-media-icon');?></td></tr>
3835
  <?php
3836
  }
3837
- $acx_fsmi_plugin_stat = "";
 
3838
  $acx_refresh_stat = 'acx_hide_refresh';
3839
  foreach($acx_fsmip_licence_array as $key => $value)
3840
  {
3841
- $acx_plugin_array = acx_fsmi_get_purchased_plugin_details($value['licence_code']);
3842
- $acx_active_plugin_stat = acx_fsmi_get_active_plugin_status($acx_plugin_array['slug']);
3843
- if($acx_active_plugin_stat == true)
3844
  {
3845
- $acx_fsmi_plugin_stat = __('Active','floating-social-media-icon');
3846
  }
3847
- else
 
 
 
 
 
3848
  {
3849
- $acx_fsmi_plugin_stat = __('Not Active <a href="'.wp_nonce_url(admin_url("admin.php?page=Acurax-Social-Icons-Settings-Install-Addons")).'">[Install Now]</a>','floating-social-media-icon');
 
 
 
 
 
 
 
 
 
 
 
 
3850
  }
3851
  if(function_exists('check_acx_pfsmi_license') && !function_exists('acx_check_fsmip_offline_license'))
3852
  {
3853
  $acx_refresh_stat = 'acx_show_refresh';
3854
  }
3855
-
3856
  ?>
3857
  <tr><td><?php echo $value['addon_name']; ?></td>
3858
  <td><?php echo $value['licence_code']; ?></td>
3859
- <td><?php echo $value['version']; ?></td>
3860
- <td><?php echo $acx_plugin_array['status']; ?></td>
3861
  <td><?php echo $acx_fsmi_plugin_stat; ?></td>
3862
  <td data-licence="<?php echo $value['licence_code']; ?>" data-key="<?php echo $key;?>"><span class="ax_fsmi_action_icon acx_fsmi_lic_refresh <?php echo $acx_refresh_stat; ?>" title="<?php _e("Refresh","floating-social-media-icon");?>"></span><span class="ax_fsmi_action_icon acx_fsmi_lic_del" title="<?php _e("Delete","floating-social-media-icon");?>"></span></td>
3863
  </tr>
@@ -3868,18 +3899,17 @@ function acx_fsmi_purachase_licence_form()
3868
  </div><!-- acx_fsmi_license_table_list -->
3869
  </div><!-- acx_fsmi_purchased_li_cvr -->
3870
  <?php
 
3871
  }
3872
- add_action("acx_fsmi_addon_hook_option_field_content","acx_fsmi_purachase_licence_form",20);
3873
- } // End of !empty($acx_fsmi_purchased_li_array)
3874
  if(!function_exists('acx_fsmi_get_purchased_plugin_details'))
3875
  {
3876
  function acx_fsmi_get_purchased_plugin_details($licence)
3877
  {
3878
  $licence = trim($licence);
3879
  $response_array = array(
3880
- "download_url" => "",
3881
- "slug" => plugin_basename( __FILE__ ),
3882
- "ignore_stat" => "no",
3883
  "status" => ""
3884
  );
3885
  if($licence != "")
@@ -3900,7 +3930,6 @@ if(!function_exists('acx_fsmi_get_purchased_plugin_details'))
3900
  $response_array = array(
3901
  "download_dynamic_url" => $value['download_dynamic_url'],
3902
  "slug" => $value['slug'],
3903
- "ignore_stat" => $value['ignore_stat'],
3904
  "status" => $value['status']
3905
  );
3906
  }
@@ -3908,7 +3937,6 @@ if(!function_exists('acx_fsmi_get_purchased_plugin_details'))
3908
  }
3909
  return $response_array;
3910
  }
3911
-
3912
  }
3913
  function acx_fsmi_license_notice_install_pending() {
3914
  ?>
@@ -3932,20 +3960,28 @@ function acx_fsmi_licnece_install_required_plugins() {
3932
  $acx_fsmip_licence_array = array();
3933
  }
3934
  $display_notice = false;
 
 
3935
  foreach($acx_fsmip_licence_array as $key => $value)
3936
  {
 
3937
  $acx_plugin_array = acx_fsmi_get_purchased_plugin_details($value['licence_code']);
3938
- $acx_active_plugin_stat = acx_fsmi_get_active_plugin_status($acx_plugin_array['slug']);
 
 
 
 
 
3939
  $plugins = array(
3940
  array(
3941
  'name' => $value['addon_name'], // The plugin name.
3942
- 'slug' => $acx_plugin_array['slug'], // The plugin slug (typically the folder name).
3943
- 'source' => $acx_plugin_array['download_dynamic_url'], // The plugin source.
3944
  'required' => true, // If false, the plugin is only 'recommended' instead of required.
3945
  ),
3946
  );
3947
  $config = array(
3948
- 'id' => $acx_plugin_array['slug'],
3949
  'default_path' => '',
3950
  'menu' => 'Acurax-Social-Icons-Settings-Install-Addons',
3951
  'parent_slug' => 'Acurax-Social-Icons-Settings',
@@ -3968,15 +4004,11 @@ function acx_fsmi_licnece_install_required_plugins() {
3968
  ),
3969
  ),
3970
  );
3971
- $acx_active_plugin_stat = acx_fsmi_get_active_plugin_status($acx_plugin_array['slug']);
3972
 
3973
- if($acx_active_plugin_stat == false)
3974
  {
3975
- if($acx_plugin_array['ignore_stat'] == 'no' )
3976
- {
3977
- acx_fsmi_licence_tgmpa( $plugins, $config );
3978
- $display_notice = true;
3979
- }
3980
  }
3981
  }
3982
  if($display_notice == true)
@@ -3989,18 +4021,50 @@ add_action( 'acx_fsmi_licence_tgmpa_register', 'acx_fsmi_licnece_install_require
3989
  function acx_fsmi_get_active_plugin_status($acx_slug)
3990
  {
3991
  $acx_return = false;
3992
- $acx_fsmi_active_plugin_arr = get_option('active_plugins');
3993
- foreach($acx_fsmi_active_plugin_arr as $key => $value)
3994
  {
3995
- if(strpos($value,$acx_slug) !== false)
 
3996
  {
3997
- $acx_return = true;
 
 
 
3998
  }
3999
  }
4000
  return $acx_return;
4001
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4002
 
4003
  function acx_fsmi_licence_btn_fn()
 
 
 
 
 
 
4004
  {
4005
  ?>
4006
  <div class="acx_fsmi_add_p_licen_cvr" style="width:100%;float:left;margin-top:50px;">
@@ -4068,40 +4132,6 @@ function acx_fsmi_licence_btn_fn()
4068
  });
4069
 
4070
 
4071
- });
4072
- </script>
4073
- <?php
4074
-
4075
- }
4076
- add_action("acx_fsmi_addon_hook_option_field_content","acx_fsmi_licence_btn_fn",30);
4077
- function acx_fsmi_li_add_script()
4078
- {?>
4079
- <script>
4080
- jQuery(".acx_fsmi_install_ignore").click(function()
4081
- {
4082
- var acx_to_ignore = jQuery(this).parent().parent().parent().find("em").html();
4083
- var acx_load = '<div id="acx_fsmip_loading_1"><div class="load_1"></div></div>';
4084
- jQuery('body').append(acx_load);
4085
- var ajaxurl = '<?php echo admin_url('admin-ajax.php'); ?>';
4086
- var acx_fsmip_order = '&acx_to_ignore='+acx_to_ignore+'&action=acx_fsmi_ignore_activation_message'+'&acx_fsmi_ignore_activation_message_w_c_n=<?php echo wp_create_nonce('acx_fsmi_ignore_activation_message_w_c_n'); ?>';
4087
- jQuery.post(ajaxurl, acx_fsmip_order, function(theResponse)
4088
- {
4089
- jQuery("#acx_fsmip_loading_1").remove();
4090
- if(theResponse == "success")
4091
- {
4092
- alert('<?php _e('Successfully Ignored the message box !!','floating-social-media-icon');?>');
4093
- var link = window.location.href;
4094
- if(link !== '')
4095
- {
4096
- window.location=link;
4097
- }
4098
- }
4099
- else
4100
- {
4101
- alert('<?php _e('Something went wrong.. Try again !!','floating-social-media-icon');?>');
4102
- }
4103
- });
4104
-
4105
  });
4106
  jQuery(".acx_fsmi_lic_del").click(function()
4107
  {
@@ -4146,7 +4176,7 @@ jQuery(".acx_fsmi_install_ignore").click(function()
4146
  jQuery("#acx_fsmip_loading_1").remove();
4147
  if(theResponse == "success")
4148
  {
4149
- alert('<?php _e('Successfully reissued the licence !!','floating-social-media-icon');?>');
4150
  var link = window.location.href;
4151
  if(link !== '')
4152
  {
@@ -4156,10 +4186,10 @@ jQuery(".acx_fsmi_install_ignore").click(function()
4156
  });
4157
  }
4158
  });
4159
- </script>
4160
- <?php
4161
  }
4162
- add_action("acx_fsmi_addon_hook_option_footer","acx_fsmi_li_add_script");
4163
  // delete installed licence
4164
  function acx_fsmi_install_licence_del_callback()
4165
  {
@@ -4241,139 +4271,46 @@ function acx_fsmi_delete_purchased_li($licence_code)
4241
 
4242
  }
4243
  }
4244
- // refresh
4245
- function acx_fsmi_install_licence_refresh_callback()
4246
  {
4247
- $key = $licence = $id = "";
4248
- $response_stat = "failed";
4249
- if(ISSET($_POST['key']))
4250
- {
4251
- $key = $_POST['key'];
4252
- }
4253
- if(ISSET($_POST['licence']))
4254
- {
4255
- $licence = $_POST['licence'];
4256
- }
4257
- $result = check_acx_pfsmi_license($licence,'',true,$id);
4258
- if(ISSET($result["localkey"]))
4259
  {
4260
- $local_key = $result["localkey"];
4261
- }
4262
- else{
4263
- $local_key = "";
4264
  }
4265
  $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
4266
  if(is_serialized($acx_fsmip_licence_array))
4267
  {
4268
  $acx_fsmip_licence_array = unserialize($acx_fsmip_licence_array);
4269
  }
4270
- if($acx_fsmip_licence_array == "" || !is_array($acx_fsmip_licence_array))
 
4271
  {
4272
- $acx_fsmip_licence_array = array();
4273
  }
4274
- $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
4275
- if(is_serialized($acx_fsmi_purchased_li_array))
4276
  {
4277
- $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
4278
  }
4279
- if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
4280
  {
4281
- $acx_fsmi_purchased_li_array = array();
4282
  }
4283
- if(ISSET($result["status"]))
4284
  {
4285
- if($result["status"] == 'Active')
4286
  {
4287
- if(ISSET($acx_fsmip_licence_array[$key]))
4288
- {
4289
- if(array_key_exists('local_key',$acx_fsmip_licence_array[$key]))
4290
- {
4291
- $acx_fsmip_licence_array[$key]['local_key'] = $local_key;
4292
-
4293
- if(!is_serialized($acx_fsmip_licence_array))
4294
- {
4295
- $acx_fsmip_licence_array = serialize($acx_fsmip_licence_array);
4296
- }
4297
- update_option('acx_fsmip_licence_array',$acx_fsmip_licence_array);
4298
-
4299
- }
4300
- }
4301
-
4302
- }
4303
- $acx_fsmi_purchased_li_array[$licence]['status'] = $result['status'];
4304
- if(!is_serialized($acx_fsmi_purchased_li_array))
4305
- {
4306
- $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
4307
  }
4308
- update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
4309
- $response_stat = "success";
4310
- }
4311
- echo $response_stat;
4312
- die();
4313
- }
4314
- add_action("wp_ajax_acx_fsmi_install_licence_refresh","acx_fsmi_install_licence_refresh_callback");
4315
- if(!function_exists('check_acx_pfsmi_license'))
4316
- {
4317
-
4318
-
4319
- }
4320
- // ignore plugin activation callback
4321
- function acx_fsmi_ignore_activation_message_callback()
4322
- {
4323
- if (!isset($_POST['acx_fsmi_ignore_activation_message_w_c_n'])) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4324
- if (!wp_verify_nonce($_POST['acx_fsmi_ignore_activation_message_w_c_n'],'acx_fsmi_ignore_activation_message_w_c_n')) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4325
- $acx_to_ignore = "";
4326
- $response_stat = "failed";
4327
- if(ISSET($_POST['acx_to_ignore']))
4328
- {
4329
- $acx_to_ignore = $_POST['acx_to_ignore'];
4330
- }
4331
- $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
4332
- if(is_serialized($acx_fsmi_purchased_li_array))
4333
- {
4334
- $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
4335
- }
4336
- if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
4337
- {
4338
- $acx_fsmi_purchased_li_array = array();
4339
- }
4340
- foreach($acx_fsmi_purchased_li_array as $key => $value)
4341
- {
4342
- if($value['name'] == $acx_to_ignore)
4343
- {
4344
- $acx_fsmi_purchased_li_array[$key]['ignore_stat'] = "yes";
4345
- $response_stat = "success";
4346
- }
4347
- }
4348
- if(!is_serialized($acx_fsmi_purchased_li_array))
4349
- {
4350
- $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
4351
- }
4352
- update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
4353
- echo $response_stat;
4354
-
4355
- die();
4356
- }
4357
- add_action("wp_ajax_acx_fsmi_ignore_activation_message","acx_fsmi_ignore_activation_message_callback");
4358
-
4359
- // add purchased licence callback
4360
- function acx_fsmi_purchased_licence_add_callback()
4361
- {
4362
- if (!isset($_POST['acx_fsmi_purchased_licence_w_c_n'])) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4363
- if (!wp_verify_nonce($_POST['acx_fsmi_purchased_licence_w_c_n'],'acx_fsmi_purchased_licence_w_c_n')) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4364
- $acx_fsmi_purchased_licence = "";
4365
- if(ISSET($_POST['acx_fsmi_purchased_licence']))
4366
- {
4367
- $acx_fsmi_purchased_licence = trim($_POST['acx_fsmi_purchased_licence']);
4368
- }
4369
- $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
4370
- if(is_serialized($acx_fsmip_licence_array))
4371
- {
4372
- $acx_fsmip_licence_array = unserialize($acx_fsmip_licence_array);
4373
  }
 
4374
  if($acx_fsmi_purchased_licence != "")
4375
  {
4376
- if (strpos($acx_fsmi_purchased_licence, 'ACX-FSMI') !== false || strpos($acx_fsmi_purchased_licence, 'FSMI-PA') !== false)
4377
  {
4378
  $licence_code_arr = explode('-',$acx_fsmi_purchased_licence);
4379
  if(is_array($licence_code_arr))
@@ -4391,62 +4328,87 @@ function acx_fsmi_purchased_licence_add_callback()
4391
  }
4392
 
4393
 
4394
- $acx_fsmi_ip = isset($_SERVER['SERVER_ADDR']) ? $_SERVER['SERVER_ADDR'] : $_SERVER['LOCAL_ADDR'];
4395
- $acx_fsmi_domain = $_SERVER['SERVER_NAME'];
4396
- $acx_fsmi_directory = dirname(__FILE__);
4397
- $acx_fsmi_args = array(
4398
- 'action' => 'acx-li-check-latest-version',
4399
- 'method' => 'addon_activation',
4400
- 'directory' => $acx_fsmi_directory,
4401
- 'unique_id' => $acx_fsmip_index,
4402
- 'domain' => $acx_fsmi_domain,
4403
- 'ip' => $acx_fsmi_ip,
4404
- 'licence' => $acx_fsmi_purchased_licence
4405
- );
4406
- $acx_fsmi_unique_id = "";
4407
- // Send request checking for an update
4408
- $response = acx_fsmi_licence_activation_api_request( $acx_fsmi_args );
4409
- $response = json_decode($response, true);
4410
- if($response['response_status'] == "success" && $response['status'] == "Active")
4411
- {
4412
- $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
4413
- if(is_serialized($acx_fsmi_purchased_li_array))
4414
- {
4415
- $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
4416
- }
4417
- if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
4418
  {
4419
- $acx_fsmi_purchased_li_array = array();
 
4420
  }
4421
- $acx_fsmi_unique_id = trim($response['unique_id']);
4422
- $acx_fsmi_purchased_li_array[$acx_fsmi_purchased_licence] = array(
4423
- 'slug' => $response['slug'],
4424
- 'status' => $response['status'],
4425
- 'download_dynamic_url' => $response['download_dynamic_url'],
4426
- 'ignore_stat' => $response['ignore_stat']
4427
- );
4428
- // update licence array
4429
 
4430
- $acx_fsmip_licence_array[$acx_fsmi_unique_id]['addon_name'] = $response['name'];
4431
- $acx_fsmip_licence_array[$acx_fsmi_unique_id]['version'] = $response['new_version'];
4432
- $acx_fsmip_licence_array[$acx_fsmi_unique_id]['licence_code'] = $acx_fsmi_purchased_licence;
4433
- $acx_fsmip_licence_array[$acx_fsmi_unique_id]['local_key'] = $response['localkey'];
4434
- if(!is_serialized($acx_fsmip_licence_array))
4435
  {
4436
- $acx_fsmip_licence_array = serialize($acx_fsmip_licence_array);
 
 
 
 
 
 
4437
  }
4438
- update_option('acx_fsmip_licence_array',$acx_fsmip_licence_array);
4439
- if(!is_serialized($acx_fsmi_purchased_li_array))
4440
  {
4441
- $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4442
  }
4443
- update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
4444
- echo "success";
4445
- }
4446
- else
4447
- {
4448
- echo __("Your Licence is ","floating-social-media-icon").$response['status'].__(" Please contact your admin","floating-social-media-icon");
4449
- }
4450
  }
4451
  else
4452
  {
8
  {
9
  $acx_fsmi_purchased_li_array = array();
10
  }
11
+
 
12
  if ( ! class_exists( 'ACX_FSMI_LICENCE_TGM_Plugin_Activation' ) ) {
13
 
14
  /**
1223
  'activate' => '',
1224
  'dismiss' => $this->dismissable ? '<a href="' . esc_url( wp_nonce_url( add_query_arg( 'acx_fsmi_licence_tgmpa-dismiss', 'dismiss_admin_notices' ), 'acx_fsmi_licence_tgmpa-dismiss-' . get_current_user_id() ) ) . '" class="dismiss-notice" target="_parent">' . esc_html( $this->strings['dismiss'] ) . '</a>' : '',
1225
  );
1226
+ $link_template = '<a href="%2$s">%1$s</a>';
1227
 
1228
  if ( current_user_can( 'install_plugins' ) ) {
1229
  if ( $install_count > 0 ) {
3803
 
3804
  function acx_fsmi_purachase_licence_form()
3805
  {
3806
+ do_action("acx_fsmi_show_purchased_li_table");
3807
+ }
3808
+ add_action("acx_fsmi_addon_hook_option_field_content","acx_fsmi_purachase_licence_form",20);
3809
+
3810
+ function acx_fsmi_show_purchased_license_html()
3811
+ {
3812
+ $response_stat = '';
3813
+ $acx_license_status = "";
3814
  $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
3815
  if(is_serialized($acx_fsmip_licence_array))
3816
  {
3820
  {
3821
  $acx_fsmip_licence_array = array();
3822
  }
3823
+ $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
3824
+ if(is_serialized($acx_fsmi_purchased_li_array))
3825
+ {
3826
+ $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
3827
+ }
3828
+ if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
3829
+ {
3830
+ $acx_fsmi_purchased_li_array = array();
3831
+ }
3832
  ?>
3833
  <div class="acx_fsmi_purchased_li_cvr">
3834
  <div id="acx_fsmi_license_table_list" style="width:98%;float:left;">
3850
  <tr><td colspan="5"><?php _e('No Licence found','floating-social-media-icon');?></td></tr>
3851
  <?php
3852
  }
3853
+ $acx_fsmi_plugin_stat = $acx_li_slug = "";
3854
+ $version_to_print = "-";
3855
  $acx_refresh_stat = 'acx_hide_refresh';
3856
  foreach($acx_fsmip_licence_array as $key => $value)
3857
  {
3858
+ if(!array_key_exists($value['licence_code'],$acx_fsmi_purchased_li_array))
 
 
3859
  {
3860
+ $response_stat = acx_fsmi_license_refresh_with_forcing($value['licence_code'],$key);
3861
  }
3862
+ }
3863
+ foreach($acx_fsmip_licence_array as $key => $value)
3864
+ {
3865
+
3866
+ $acx_plugin_array = acx_fsmi_get_purchased_plugin_details($value['licence_code']);
3867
+ if(ISSET($acx_plugin_array['slug']) && ISSET($acx_plugin_array['download_dynamic_url']))
3868
  {
3869
+
3870
+ $acx_license_status = $acx_plugin_array['status'];
3871
+ $acx_li_slug = $acx_plugin_array['slug'];
3872
+ $version_to_print = get_plugin_version_number($acx_li_slug);
3873
+ $acx_active_plugin_stat = acx_fsmi_get_active_plugin_status($acx_li_slug);
3874
+ if($acx_active_plugin_stat == true)
3875
+ {
3876
+ $acx_fsmi_plugin_stat = __('Active','floating-social-media-icon');
3877
+ }
3878
+ else
3879
+ {
3880
+ $acx_fsmi_plugin_stat = __('Not Active <a href="'.wp_nonce_url(admin_url("admin.php?page=Acurax-Social-Icons-Settings-Install-Addons")).'">[Install Now]</a>','floating-social-media-icon');
3881
+ }
3882
  }
3883
  if(function_exists('check_acx_pfsmi_license') && !function_exists('acx_check_fsmip_offline_license'))
3884
  {
3885
  $acx_refresh_stat = 'acx_show_refresh';
3886
  }
 
3887
  ?>
3888
  <tr><td><?php echo $value['addon_name']; ?></td>
3889
  <td><?php echo $value['licence_code']; ?></td>
3890
+ <td><?php echo $version_to_print; ?></td>
3891
+ <td><?php echo $acx_license_status; ?></td>
3892
  <td><?php echo $acx_fsmi_plugin_stat; ?></td>
3893
  <td data-licence="<?php echo $value['licence_code']; ?>" data-key="<?php echo $key;?>"><span class="ax_fsmi_action_icon acx_fsmi_lic_refresh <?php echo $acx_refresh_stat; ?>" title="<?php _e("Refresh","floating-social-media-icon");?>"></span><span class="ax_fsmi_action_icon acx_fsmi_lic_del" title="<?php _e("Delete","floating-social-media-icon");?>"></span></td>
3894
  </tr>
3899
  </div><!-- acx_fsmi_license_table_list -->
3900
  </div><!-- acx_fsmi_purchased_li_cvr -->
3901
  <?php
3902
+
3903
  }
3904
+ add_action("acx_fsmi_show_purchased_li_table", "acx_fsmi_show_purchased_license_html");
 
3905
  if(!function_exists('acx_fsmi_get_purchased_plugin_details'))
3906
  {
3907
  function acx_fsmi_get_purchased_plugin_details($licence)
3908
  {
3909
  $licence = trim($licence);
3910
  $response_array = array(
3911
+ "download_dynamic_url" => "",
3912
+ "slug" => "",
 
3913
  "status" => ""
3914
  );
3915
  if($licence != "")
3930
  $response_array = array(
3931
  "download_dynamic_url" => $value['download_dynamic_url'],
3932
  "slug" => $value['slug'],
 
3933
  "status" => $value['status']
3934
  );
3935
  }
3937
  }
3938
  return $response_array;
3939
  }
 
3940
  }
3941
  function acx_fsmi_license_notice_install_pending() {
3942
  ?>
3960
  $acx_fsmip_licence_array = array();
3961
  }
3962
  $display_notice = false;
3963
+ $acx_li_slug = $acx_li_download_url = '';
3964
+ $acx_active_plugin_stat = '';
3965
  foreach($acx_fsmip_licence_array as $key => $value)
3966
  {
3967
+
3968
  $acx_plugin_array = acx_fsmi_get_purchased_plugin_details($value['licence_code']);
3969
+ if(ISSET($acx_plugin_array['slug']) && ISSET($acx_plugin_array['download_dynamic_url']))
3970
+ {
3971
+ $acx_li_download_url = $acx_plugin_array['download_dynamic_url'];
3972
+ $acx_li_slug = $acx_plugin_array['slug'];
3973
+ $acx_active_plugin_stat = acx_fsmi_get_active_plugin_status($acx_li_slug);
3974
+ }
3975
  $plugins = array(
3976
  array(
3977
  'name' => $value['addon_name'], // The plugin name.
3978
+ 'slug' => $acx_li_slug, // The plugin slug (typically the folder name).
3979
+ 'source' => $acx_li_download_url, // The plugin source.
3980
  'required' => true, // If false, the plugin is only 'recommended' instead of required.
3981
  ),
3982
  );
3983
  $config = array(
3984
+ 'id' => $acx_li_slug,
3985
  'default_path' => '',
3986
  'menu' => 'Acurax-Social-Icons-Settings-Install-Addons',
3987
  'parent_slug' => 'Acurax-Social-Icons-Settings',
4004
  ),
4005
  ),
4006
  );
 
4007
 
4008
+ if($acx_active_plugin_stat === false)
4009
  {
4010
+ acx_fsmi_licence_tgmpa( $plugins, $config );
4011
+ $display_notice = true;
 
 
 
4012
  }
4013
  }
4014
  if($display_notice == true)
4021
  function acx_fsmi_get_active_plugin_status($acx_slug)
4022
  {
4023
  $acx_return = false;
4024
+ if($acx_slug != "")
 
4025
  {
4026
+ $acx_fsmi_active_plugin_arr = get_option('active_plugins');
4027
+ foreach($acx_fsmi_active_plugin_arr as $key => $value)
4028
  {
4029
+ if(strpos($value,$acx_slug) !== false)
4030
+ {
4031
+ $acx_return = true;
4032
+ }
4033
  }
4034
  }
4035
  return $acx_return;
4036
  }
4037
+ function get_plugin_version_number($acx_slug)
4038
+ {
4039
+ $acx_version_return = '-';
4040
+ $acx_plugin_data_array = array();
4041
+ if($acx_slug != "")
4042
+ {
4043
+ if ( ! function_exists( 'get_plugins' ) )
4044
+ require_once( ABSPATH . 'wp-admin/includes/plugin.php' );
4045
+ $plugin_folder = get_plugins( );
4046
+ $plugin_file ='';
4047
+ $acx_fsmi_active_plugin_arr = get_option('active_plugins');
4048
+ foreach($acx_fsmi_active_plugin_arr as $key => $value)
4049
+ {
4050
+ if(strpos($value,$acx_slug) !== false)
4051
+ {
4052
+ $plugin_file = $value ;
4053
+ $acx_version_return = $plugin_folder[$plugin_file]['Version'];
4054
+ }
4055
+ }
4056
+
4057
+ }
4058
+ return $acx_version_return;
4059
+ }
4060
 
4061
  function acx_fsmi_licence_btn_fn()
4062
+ {
4063
+ do_action("acx_fsmi_show_add_li_btn_hook");
4064
+ }
4065
+ add_action("acx_fsmi_addon_hook_option_field_content","acx_fsmi_licence_btn_fn",30);
4066
+ // show add licence fields
4067
+ function acx_fsmi_show_license_add_button_html()
4068
  {
4069
  ?>
4070
  <div class="acx_fsmi_add_p_licen_cvr" style="width:100%;float:left;margin-top:50px;">
4132
  });
4133
 
4134
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4135
  });
4136
  jQuery(".acx_fsmi_lic_del").click(function()
4137
  {
4176
  jQuery("#acx_fsmip_loading_1").remove();
4177
  if(theResponse == "success")
4178
  {
4179
+ alert('<?php _e('Successfully refreshed the license !!','floating-social-media-icon');?>');
4180
  var link = window.location.href;
4181
  if(link !== '')
4182
  {
4186
  });
4187
  }
4188
  });
4189
+ </script>
4190
+ <?php
4191
  }
4192
+ add_action("acx_fsmi_show_add_li_btn_hook","acx_fsmi_show_license_add_button_html");
4193
  // delete installed licence
4194
  function acx_fsmi_install_licence_del_callback()
4195
  {
4271
 
4272
  }
4273
  }
4274
+ // add purchased licence callback
4275
+ function acx_fsmi_purchased_licence_add_callback()
4276
  {
4277
+ if (!isset($_POST['acx_fsmi_purchased_licence_w_c_n'])) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4278
+ if (!wp_verify_nonce($_POST['acx_fsmi_purchased_licence_w_c_n'],'acx_fsmi_purchased_licence_w_c_n')) die("<br><br>".__('Unknown Error Occurred, Try Again... ','floating-social-media-icon')."<a href=''>".__('Click Here','floating-social-media-icon')."</a>");
4279
+ $acx_fsmi_purchased_licence = "";
4280
+ $retry = true;
4281
+ if(ISSET($_POST['acx_fsmi_purchased_licence']))
 
 
 
 
 
 
 
4282
  {
4283
+ $acx_fsmi_purchased_licence = trim($_POST['acx_fsmi_purchased_licence']);
 
 
 
4284
  }
4285
  $acx_fsmip_licence_array = get_option('acx_fsmip_licence_array');
4286
  if(is_serialized($acx_fsmip_licence_array))
4287
  {
4288
  $acx_fsmip_licence_array = unserialize($acx_fsmip_licence_array);
4289
  }
4290
+ $acx_fsmip_retry_array = get_option('acx_fsmip_retry_array');
4291
+ if(is_serialized($acx_fsmip_retry_array))
4292
  {
4293
+ $acx_fsmip_retry_array = unserialize($acx_fsmip_retry_array);
4294
  }
4295
+ if($acx_fsmip_retry_array == "")
 
4296
  {
4297
+ $acx_fsmip_retry_array = array();
4298
  }
4299
+ if(!is_array($acx_fsmip_retry_array))
4300
  {
4301
+ $acx_fsmip_retry_array = array();
4302
  }
4303
+ if(ISSET($acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check']))
4304
  {
4305
+ if($acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check'] >= 3)
4306
  {
4307
+ $retry = false;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4308
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4309
  }
4310
+
4311
  if($acx_fsmi_purchased_licence != "")
4312
  {
4313
+ if (strpos($acx_fsmi_purchased_licence, 'FSMI') !== false)
4314
  {
4315
  $licence_code_arr = explode('-',$acx_fsmi_purchased_licence);
4316
  if(is_array($licence_code_arr))
4328
  }
4329
 
4330
 
4331
+ $acx_fsmi_ip = isset($_SERVER['SERVER_ADDR']) ? $_SERVER['SERVER_ADDR'] : $_SERVER['LOCAL_ADDR'];
4332
+ $acx_fsmi_domain = $_SERVER['SERVER_NAME'];
4333
+ $acx_fsmi_directory = dirname(__FILE__);
4334
+ $acx_fsmi_args = array(
4335
+ 'action' => 'acx-li-check-latest-version',
4336
+ 'method' => 'addon_activation',
4337
+ 'directory' => $acx_fsmi_directory,
4338
+ 'unique_id' => $acx_fsmip_index,
4339
+ 'domain' => $acx_fsmi_domain,
4340
+ 'ip' => $acx_fsmi_ip,
4341
+ 'licence' => $acx_fsmi_purchased_licence
4342
+ );
4343
+ $acx_fsmi_unique_id = "";
4344
+ // Send request checking for an update
4345
+ if($retry == true)
 
 
 
 
 
 
 
 
 
4346
  {
4347
+ $response = acx_fsmi_licence_activation_api_request( $acx_fsmi_args );
4348
+ $response = json_decode($response, true);
4349
  }
 
 
 
 
 
 
 
 
4350
 
4351
+ if(!ISSET($response['response_status']) && !ISSET($response['status']))
 
 
 
 
4352
  {
4353
+ if(ISSET($acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check']))
4354
+ {
4355
+ $acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check'] = $acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check'] + 1;
4356
+ }
4357
+ else{
4358
+ $acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check'] = 1;
4359
+ }
4360
  }
4361
+ else
 
4362
  {
4363
+ if($response['response_status'] == "success" && $response['status'] == "Active")
4364
+ {
4365
+ $acx_fsmi_purchased_li_array = get_option('acx_fsmi_purchased_li_array');
4366
+ if(is_serialized($acx_fsmi_purchased_li_array))
4367
+ {
4368
+ $acx_fsmi_purchased_li_array = unserialize($acx_fsmi_purchased_li_array);
4369
+ }
4370
+ if($acx_fsmi_purchased_li_array == "" || !is_array($acx_fsmi_purchased_li_array))
4371
+ {
4372
+ $acx_fsmi_purchased_li_array = array();
4373
+ }
4374
+ $acx_fsmi_unique_id = trim($response['unique_id']);
4375
+ $acx_fsmi_purchased_li_array[$acx_fsmi_purchased_licence] = array(
4376
+ 'slug' => $response['slug'],
4377
+ 'status' => $response['status'],
4378
+ 'download_dynamic_url' => $response['download_dynamic_url']
4379
+ );
4380
+ // update licence array
4381
+
4382
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['addon_name'] = $response['name'];
4383
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['version'] = $response['new_version'];
4384
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['licence_code'] = $acx_fsmi_purchased_licence;
4385
+ if($response['localkey'] != "")
4386
+ {
4387
+ $acx_fsmip_licence_array[$acx_fsmi_unique_id]['local_key'] = $response['localkey'];
4388
+ }
4389
+ if(!is_serialized($acx_fsmip_licence_array))
4390
+ {
4391
+ $acx_fsmip_licence_array = serialize($acx_fsmip_licence_array);
4392
+ }
4393
+ update_option('acx_fsmip_licence_array',$acx_fsmip_licence_array);
4394
+ if(!is_serialized($acx_fsmi_purchased_li_array))
4395
+ {
4396
+ $acx_fsmi_purchased_li_array = serialize($acx_fsmi_purchased_li_array);
4397
+ }
4398
+ update_option('acx_fsmi_purchased_li_array',$acx_fsmi_purchased_li_array);
4399
+ $acx_fsmip_retry_array[$acx_fsmi_purchased_licence]['activation_licence_check'] = 0;
4400
+ if(!is_serialized($acx_fsmip_retry_array))
4401
+ {
4402
+ $acx_fsmip_retry_array = serialize($acx_fsmip_retry_array);
4403
+ }
4404
+ update_option('acx_fsmip_retry_array',$acx_fsmip_retry_array);
4405
+ echo "success";
4406
+ }
4407
+ else
4408
+ {
4409
+ echo __("Sorry, Your license code is invalid, Please contact support","floating-social-media-icon");
4410
+ }
4411
  }
 
 
 
 
 
 
 
4412
  }
4413
  else
4414
  {
readme.txt CHANGED
@@ -212,6 +212,10 @@ Have more questions ? [Drop a mail](http://www.acurax.com/contact.php/ "Drop an
212
 
213
  == Upgrade Notice ==
214
 
 
 
 
 
215
  = Social Media Floating Icons - 4.2.1 =
216
  * Fix - Perfomance Improvements
217
  * Fix - Update Bug Fixes
@@ -429,6 +433,10 @@ Have more questions ? [Drop a mail](http://www.acurax.com/contact.php/ "Drop an
429
 
430
  == Changelog ==
431
 
 
 
 
 
432
  = Social Media Floating Icons - 4.2.1 =
433
  * Fix - Perfomance Improvements
434
  * Fix - Update Bug Fixes
212
 
213
  == Upgrade Notice ==
214
 
215
+ = Social Media Floating Icons - 4.2.2 =
216
+ * Fix - Perfomance Improvements
217
+ * Fix - Optimized Loading Speed
218
+
219
  = Social Media Floating Icons - 4.2.1 =
220
  * Fix - Perfomance Improvements
221
  * Fix - Update Bug Fixes
433
 
434
  == Changelog ==
435
 
436
+ = Social Media Floating Icons - 4.2.2 =
437
+ * Fix - Perfomance Improvements
438
+ * Fix - Optimized Loading Speed
439
+
440
  = Social Media Floating Icons - 4.2.1 =
441
  * Fix - Perfomance Improvements
442
  * Fix - Update Bug Fixes