Skip to content
Browse files

BUGFIX: geo content for campaigns bug is fixed.

MINOR: added css classes to the left hand column
  • Loading branch information...
1 parent 274867e commit 49331bda67a626259a3ca252954f46a273fe5501 @fonsekaean committed Mar 5, 2011
Showing with 47 additions and 38 deletions.
  1. +5 −3 code/MailChimpInterface.php
  2. +39 −34 templates/MailChimpInterface_left.ss
  3. +3 −1 templates/MailChimpInterface_right.ss
View
8 code/MailChimpInterface.php
@@ -496,9 +496,11 @@ function campaignClicks() {
JS
;
- $geoJS = "[";
- foreach($geo as $geoCont){
- $geoJS .= "['" . $geoCont['name'] . "', " . $geoCont['opens'] . "],";
+ $geoJS = "[";
+ if(is_array($geo)){
+ foreach($geo as $geoCont){
+ $geoJS .= "['" . $geoCont['name'] . "', " . $geoCont['opens'] . "],";
+ }
}
$geoJS = substr($geoJS, 0, -1);
View
73 templates/MailChimpInterface_left.ss
@@ -1,45 +1,50 @@
-<% if hasCredentials %>
-<h2 class="headBtn" id="listsButton">Lists</h2>
-<div id="MailchimpLists" style="display: none; padding: 3px;">
- <ul id="MailchimpListsUL"></ul>
-</div>
-
-
-<h2 class="headBtn" id="campaignsButton">Campaigns</h2>
-<div id="MailchimpCampaigns" style="display: none;">
- <ul id="MailchimpCampaignsUL"></ul>
- <ul id="CampaignActions">
- <li id="addcampaign" class="action"><button>Create</button></li>
- </ul>
- <div class="clear">&nbsp;</div>
+<div class="leftbottom ss-tabset ui-layout-content">
+
+ <% if hasCredentials %>
+ <h2 class="headBtn" id="listsButton">Lists</h2>
+ <div id="MailchimpLists" style="display: none; padding: 3px;">
+ <ul id="MailchimpListsUL"></ul>
+ </div>
+ <h2 class="headBtn" id="campaignsButton">Campaigns</h2>
+ <div id="MailchimpCampaigns" style="display: none;">
+ <ul id="MailchimpCampaignsUL"></ul>
+ <ul id="CampaignActions">
+ <li id="addcampaign" class="action"><button>Create</button></li>
+ </ul>
+ <div class="clear">&nbsp;</div>
+ </div>
+ <h2 class="headBtn" id="credentialsButton">Mailchimp credentials</h2>
+ <div id="CredentialsForm" style="display: none;">
+ <p>Edit your mailchimp credentials.</p>
+ <div class="mailchimpForm">
+ $CredentialForm
+ </div>
+ </div>
+ <% end_if %>
+
+
+ <div class="mailchimpForm">
+ <% if hasCredentials %>
+
+ <% else %>
+ <h2>Mailchimp credentials</h2>
+ <div style="padding: 3px;">
+ <p>Your Mailchimp credentials are not saved. Please add them first.</p>
+ <div>
+ $CredentialForm
+ </div>
+ </div>
+ <% end_if %>
+ </div>
+
</div>
-<h2 class="headBtn" id="credentialsButton">Mailchimp credentials</h2>
-<div id="CredentialsForm" style="display: none;">
- <p>Edit your mailchimp credentials.</p>
- <div class="mailchimpForm">
- $CredentialForm
- </div>
-</div>
-<% end_if %>
-<div class="mailchimpForm">
- <% if hasCredentials %>
- <% else %>
- <h2>Mailchimp credentials</h2>
- <div style="padding: 3px;">
- <p>Your Mailchimp credentials are not saved. Please add them first.</p>
- <div>
- $CredentialForm
- </div>
- </div>
- <% end_if %>
-</div>
<style type="text/css">
.mailchimpForm form label.left { float: none; margin-left:0em; }
View
4 templates/MailChimpInterface_right.ss
@@ -1 +1,3 @@
-<h1>Mailchimp</h1>
+<div class="ui-layout-content">
+ <h1>Mailchimp</h1>
+</div>

0 comments on commit 49331bd

Please sign in to comment.
Something went wrong with that request. Please try again.