Plugin Directory

Changeset 1446896

Timestamp:
06/30/2016 11:37:34 PM (8 years ago)
Author:
gcorne
Message:

Remove more trailing whitespace and executable bit for real

Location:
hubspot-tracking-code/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • hubspot-tracking-code/trunk/admin/hubspot-tracking-code-admin.php

    • Property svn:executable deleted
    r1208526 r1446896  
    11<?php
    22
    3 if ( !defined('HUBSPOT_TRACKING_CODE_PLUGIN_VERSION') ) 
     3if ( !defined('HUBSPOT_TRACKING_CODE_PLUGIN_VERSION') )
    44{
    55    header('HTTP/1.0 403 Forbidden');
     
    2323// HubSpotTrackingCodeAdmin Class
    2424//=============================================
    25 class HubSpotTrackingCodeAdmin 
     25class HubSpotTrackingCodeAdmin
    2626{
    2727    /**
     
    3939        if ( $options['hs_version'] != HUBSPOT_TRACKING_CODE_PLUGIN_VERSION )
    4040            self::hubspot_tracking_code_update_check();
    41        
     41
    4242        add_action('admin_menu', array(&$this, 'hubspot_add_menu_items'));
    4343        add_action('admin_init', array(&$this, 'hubspot_build_settings_page'));
     
    5252        hubspot_tracking_code_update_option('hs_settings', 'hs_version', HUBSPOT_TRACKING_CODE_PLUGIN_VERSION);
    5353    }
    54    
     54
    5555    //=============================================
    5656    // Menus
    5757    //=============================================
    5858
    59     function hubspot_add_menu_items () 
     59    function hubspot_add_menu_items ()
    6060    {
    6161        add_submenu_page('options-general.php', 'HubSpot Settings', 'HubSpot Settings', 'edit_posts', basename(__FILE__), array($this, 'hubspot_plugin_options'));
     
    6868
    6969    /**
    70      * Adds setting link for HubSpot to plugins management page 
     70     * Adds setting link for HubSpot to plugins management page
    7171     *
    7272     * @param   array $links
     
    8585     */
    8686    function hubspot_build_settings_page ()
    87     {   
     87    {
    8888        global $pagenow;
    8989        $options = get_option('hs_settings');
     
    9494            array($this, 'sanitize')
    9595        );
    96        
     96
    9797        add_settings_section(
    9898            'hubspot_settings_section',
     
    101101            HUBSPOT_TRACKING_CODE_ADMIN_PATH
    102102        );
    103        
     103
    104104        add_settings_field(
    105105            'hs_portal',
     
    146146                <form method="POST" action="options.php">
    147147                    <div id="dashboard-widgets" class="metabox-holder">
    148                         <div class="postbox-container" style="width:60%;"> 
     148                        <div class="postbox-container" style="width:60%;">
    149149                            <div class="meta-box-sortables ui-sortable">
    150150                                <div class="postbox">
     
    152152                                    <div class="inside">
    153153                                        Enter your Hub ID below to track your WordPress site in HubSpot's analytics system.
    154                                         <?php 
     154                                        <?php
    155155                                            settings_fields('hubspot_settings_options');
    156156                                            do_settings_sections(HUBSPOT_TRACKING_CODE_ADMIN_PATH);
    157157                                        ?>
    158158                                    </div>
    159                                    
     159
    160160                                </div>
    161161                            </div>
     
    164164
    165165                        <div class="postbox-container" style="width:40%;">
    166                             <div class="meta-box-sortables ui-sortable">   
     166                            <div class="meta-box-sortables ui-sortable">
    167167                                <div class="postbox">
    168168                                <h3 class="hndle"><span>Where is my HubSpot Hub ID?</span></h3>
     
    213213        $options = get_option('hs_settings');
    214214        $hs_portal  = ( isset($options['hs_portal']) && $options['hs_portal'] ? $options['hs_portal'] : '' );
    215      
     215
    216216        printf(
    217217            '<input id="hs_portal" type="text" id="title" name="hs_settings[hs_portal]" style="width: 400px;" value="%s"/>',
  • hubspot-tracking-code/trunk/hubspot-tracking-code.php

    r1208526 r1446896  
    1010*/
    1111
    12 if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly 
     12if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
    1313
    1414//=============================================
     
    4747{
    4848    // Check activation on entire network or one blog
    49     if ( is_multisite() && $network_wide ) 
    50     { 
     49    if ( is_multisite() && $network_wide )
     50    {
    5151        global $wpdb;
    52  
     52
    5353        // Get this so we can switch back to it later
    5454        $current_blog = $wpdb->blogid;
    55  
     55
    5656        // Get all blogs in the network and activate plugin on each one
    5757        $q = "SELECT blog_id FROM $wpdb->blogs";
    5858        $blog_ids = $wpdb->get_col($q);
    59         foreach ( $blog_ids as $blog_id ) 
     59        foreach ( $blog_ids as $blog_id )
    6060        {
    6161            switch_to_blog($blog_id);
    6262            hubspot_tracking_code_setup_plugin();
    6363        }
    64  
     64
    6565        // Switch back to the current blog
    6666        switch_to_blog($current_blog);
     
    9393            $multisite_prefix = ( is_multisite() ? $wpdb->prefix : '' );
    9494            $q = $wpdb->prepare("
    95                 INSERT INTO " . $multisite_prefix . "options 
    96                     ( option_name, option_value ) 
     95                INSERT INTO " . $multisite_prefix . "options
     96                    ( option_name, option_value )
    9797                VALUES ('hs_settings', %s)", serialize($opt));
    9898            $wpdb->query($q);
     
    121121function hubspot_tracking_code_init ()
    122122{
    123     if ( is_plugin_active('hubspot/hubspot.php') ) 
     123    if ( is_plugin_active('hubspot/hubspot.php') )
    124124    {
    125125        remove_action( 'plugins_loaded', 'hubspot_tracking_code_init' );
     
    135135add_action( 'plugins_loaded', 'hubspot_tracking_code_init', 14 );
    136136
    137 if ( is_admin() ) 
     137if ( is_admin() )
    138138{
    139139    // Activate + install Super Simple Landing Pages
     
    144144}
    145145
    146 function deactivate_hubspot_tracking_code_notice () 
     146function deactivate_hubspot_tracking_code_notice ()
    147147{
    148148    ?>
    149149    <div id="message" class="error">
    150         <?php _e( 
    151             '<p><h3>HubSpot Tracking Code plugin wasn\'t activated because your HubSpot for WordPress plugin is still activated...</h3></p>' . 
     150        <?php _e(
     151            '<p><h3>HubSpot Tracking Code plugin wasn\'t activated because your HubSpot for WordPress plugin is still activated...</h3></p>' .
    152152                '<p>HubSpot Tracking Code and HubSpot for WordPress are like two rival siblings - they don\'t play nice together, but don\'t panic - it\'s an easy fix. Deactivate <b><i>HubSpot for WordPress</i></b> and then try activating <b><i>HubSpot Tracking Code for WordPress</i></b> again, and everything should work fine.</p>' .
    153153            '<p>By the way - make sure you replace all your form and CTA shortcodes with <a href="http://help.hubspot.com/articles/KCS_Article/Integrations/How-to-switch-from-the-HubSpot-for-Wordpress-plugin-to-the-HubSpot-Tracking-code-for-Wordpress-plugin" target="_blank">HubSpot embed codes</a></p>',
  • hubspot-tracking-code/trunk/readme.txt

    • Property svn:executable deleted
Note: See TracChangeset for help on using the changeset viewer.