gglnltcs_table_chart_tab

The BestWebSoft Google Analytics gglnltcs table chart tab function.

Description

gglnltcs_table_chart_tab( $analytics ); 

Parameters (1)

0. $analytics
The analytics.

Usage

  1. if ( !function_exists( 'gglnltcs_table_chart_tab' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'bestwebsoft-google-analytics/bws-google-analytics.php'; 
  3.  
  4. // The analytics. 
  5. $analytics = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = gglnltcs_table_chart_tab($analytics); 
  9.  

Defined (1)

The function is defined in the following location(s).

/bws-google-analytics.php  
  1. function gglnltcs_table_chart_tab( $analytics ) { 
  2. global $gglnltcs_metrics_data, $gglnltcs_dimensions_data; 
  3. /** Load metrics and dimensions data */ 
  4. /** Main Form */ ?> 
  5. <form id="gglnltcs-main-form" method="post" action="admin.php?page=bws-google-analytics.php&action=table-tab"> 
  6. <?php wp_nonce_field( plugin_basename( __FILE__ ), 'gglnltcs_nonce_name' ); ?> 
  7. <table class="gglnltcs"><?php 
  8. /** Print Accounts */  
  9. $func_return = gglnltcs_print_accounts( $analytics ); 
  10. $profile_accounts = $func_return[0]; 
  11. $settings = $func_return[1]; 
  12. $accounts_id = $func_return[2]; 
  13. /** Print Webproperties */ 
  14. gglnltcs_print_webproperties( $analytics, $profile_accounts, $accounts_id, $settings ); ?> 
  15. </table><?php 
  16. /** Print Table for Metrics */ 
  17. gglnltcs_build_table( 'metrics', __( 'Metrics', 'gglnltcs' ), $gglnltcs_metrics_data, $settings ); 
  18. /** Print Table for Dimensions */ 
  19. gglnltcs_build_table( 'dimensions', __( 'Dimensions', 'gglnltcs' ), $gglnltcs_dimensions_data, $settings ); 
  20. /** Print Table for Date Range */ ?> 
  21. <table id="gglnltcs-date" class="gglnltcs"> 
  22. <tr><!-- Start Date --> 
  23. <th> 
  24. <h3> 
  25. <label for="gglnltcs-start-date"><?php _e( 'Start Date', 'gglnltcs' ); ?></label> 
  26. </h3> 
  27. </th> 
  28. <td class='gglnltcs-date'> 
  29. <input id="gglnltcs-start-date" name="gglnltcs_start_date" type="text" value="<?php if ( isset( $settings['gglnltcs_start_date'] ) ) echo $settings['gglnltcs_start_date']; ?>"> 
  30. <span class="gglnltcs-note"><?php _e( 'Date values must match the pattern YYYY-MM-DD.', 'gglnltcs' ); ?></span> 
  31. </td> 
  32. </tr> 
  33. <tr><!-- End Date --> 
  34. <th> 
  35. <h3> 
  36. <label for="gglnltcs-end-date"><?php _e( 'End Date', 'gglnltcs' ); ?></label> 
  37. </h3> 
  38. </th> 
  39. <td class='gglnltcs-date'> 
  40. <input id="gglnltcs-end-date" name="gglnltcs_end_date" type="text" value="<?php if ( isset( $settings['gglnltcs_end_date'] ) ) echo $settings['gglnltcs_end_date']; ?>"> 
  41. <span class="gglnltcs-note"><?php _e( 'Date values must match the pattern YYYY-MM-DD.', 'gglnltcs' ); ?></span> 
  42. <!-- Get Data --> 
  43. <input id="gglnltcs-get-statistics-button" type="submit" class="button-secondary" value="<?php _e( 'Get Statistic', 'gglnltcs' ); ?>"> 
  44. <noscript> 
  45. <p class="gglnltcs-unsuccess-message"><?php _e( 'This plugin requires JavaScript to work properly.', 'gglnltcs' ); ?></p> 
  46. </noscript> 
  47. </td> 
  48. </tr> 
  49. </table><?php 
  50. /** Get statistics. */ 
  51. if ( isset( $_POST[ 'gglnltcs_accounts' ] ) ) { 
  52. $post_data = $_POST; 
  53. gglnltcs_get_statistic( $analytics, $post_data, $gglnltcs_metrics_data, $gglnltcs_dimensions_data ); 
  54. } /** close if isset post accounts.*/?> 
  55. </form> 
  56. <div class="bws-plugin-reviews"> 
  57. <div class="bws-plugin-reviews-rate"> 
  58. <?php _e( 'If you enjoy our plugin, please give it 5 stars on WordPress', 'gglnltcs' ); ?>:  
  59. <a href="http://wordpress.org/support/view/plugin-reviews/bws-google-analytics" target="_blank" title="BestWebSoft Google Analytics reviews"><?php _e( 'Rate the plugin', 'gglnltcs' ); ?></a> 
  60. </div> 
  61. <div class="bws-plugin-reviews-support"> 
  62. <?php _e( 'If there is something wrong about it, please contact us', 'gglnltcs' ); ?>:  
  63. <a href="http://support.bestwebsoft.com">http://support.bestwebsoft.com</a> 
  64. </div> 
  65. </div> 
  66. <?php