/** Populate the new Soundcloud is Gold Tab **/ function get_soundcloud_is_gold_user_tracks() { //Default Settings $options = get_option('soundcloud_is_gold_options'); //printl($options); $soundcloudIsGoldActiveUser = isset($options['soundcloud_is_gold_active_user']) ? $options['soundcloud_is_gold_active_user'] : ''; $soundcloudIsGoldUsers = isset($options['soundcloud_is_gold_users']) ? $options['soundcloud_is_gold_users'] : ''; $soundcloudIsGoldSettings = isset($options['soundcloud_is_gold_settings']) ? $options['soundcloud_is_gold_settings'] : ''; $soundcloudIsGoldPlayerType = isset($options['soundcloud_is_gold_playerType']) ? $options['soundcloud_is_gold_playerType'] : ''; $soundcloudIsGoldPlayerTypeDefault = empty($soundcloudIsGoldPlayerType) ? TRUE : FALSE; $soundcloudIsGoldWidthSettings = isset($options['soundcloud_is_gold_width_settings']) ? $options['soundcloud_is_gold_width_settings'] : ''; $soundcloudIsGoldWidth = get_soundcloud_is_gold_default_width($soundcloudIsGoldWidthSettings); $soundcloudIsGoldClasses = isset($options['soundcloud_is_gold_classes']) ? $options['soundcloud_is_gold_classes'] : ''; $soundcloudIsGoldColor = isset($options['soundcloud_is_gold_color']) ? $options['soundcloud_is_gold_color'] : ''; //Default Pagination Settings $soundcloudIsGoldTracksPerPage = 25; $soundcloudIsGoldPage = isset($_REQUEST['paged']) ? $_REQUEST['paged'] : '1'; $post_id = $_REQUEST['post_id']; $soundcloudIsGoldApiOffset = $soundcloudIsGoldTracksPerPage * ($soundcloudIsGoldPage - 1); //API Call $soundcloudIsGoldSelectedFormat = isset($_REQUEST['selectFormat']) ? $_REQUEST['selectFormat'] : 'tracks'; if ($soundcloudIsGoldSelectedFormat == 'tracks') { $soundcloudIsGoldApiCall = 'http://api.soundcloud.com/users/' . $soundcloudIsGoldActiveUser . '/tracks.xml?limit=' . $soundcloudIsGoldTracksPerPage . '&offset=' . $soundcloudIsGoldApiOffset . '&client_id=9rD2GrGrajkmkw5eYFDp2g'; } if ($soundcloudIsGoldSelectedFormat == 'sets') { $soundcloudIsGoldApiCall = 'http://api.soundcloud.com/users/' . $soundcloudIsGoldActiveUser . '/playlists.xml?limit=' . $soundcloudIsGoldTracksPerPage . '&offset=' . $soundcloudIsGoldApiOffset . '&client_id=9rD2GrGrajkmkw5eYFDp2g'; } if ($soundcloudIsGoldSelectedFormat == 'favorites') { $soundcloudIsGoldApiCall = 'http://api.soundcloud.com/users/' . $soundcloudIsGoldActiveUser . '/favorites.xml?limit=' . $soundcloudIsGoldTracksPerPage . '&offset=' . $soundcloudIsGoldApiOffset . '&client_id=9rD2GrGrajkmkw5eYFDp2g'; } $soundcloudIsGoldApiResponse = get_soundcloud_is_gold_api_response($soundcloudIsGoldApiCall); //Pagination and Actions $soundcloudIsGoldNumbers = get_soundcloudIsGoldUserNumber($soundcloudIsGoldSelectedFormat); $soundcloudIsGoldPagination = soundcloud_is_gold_pagination($soundcloudIsGoldSelectedFormat, $soundcloudIsGoldNumbers[$soundcloudIsGoldSelectedFormat], $soundcloudIsGoldPage, $soundcloudIsGoldTracksPerPage, $post_id); $soundcloudIsGoldSelectTracksFavsSets = soundcloud_is_gold_select_tracks_favs_sets($soundcloudIsGoldSelectedFormat, $soundcloudIsGoldNumbers, $post_id); //Usernames echo '<div class="soundcloudMMWrapper">'; echo '<div id="soundcloudMMUsernameHeader"><img src="' . $soundcloudIsGoldUsers[$soundcloudIsGoldActiveUser][1] . '" width="50" height="50"/><span>' . $soundcloudIsGoldUsers[$soundcloudIsGoldActiveUser][0] . '</span> <a href="#" id="soundcloudMMShowUsernames">show users options</a><a href="#" id="soundcloudMMHideUsernames" class="hidden">hide users options</a></div>'; echo '<div id="soundcloudMMUsermameTab">'; get_soundcloud_is_gold_username_interface($options, $soundcloudIsGoldUsers); echo '</div></div>'; echo '<div id="soundcloudMMTabActions" class="tablenav">'; //Select Tracks / Sets / Favs echo isset($soundcloudIsGoldSelectTracksFavsSets) ? $soundcloudIsGoldSelectTracksFavsSets : ''; //Pagination echo isset($soundcloudIsGoldPagination) ? $soundcloudIsGoldPagination : ''; echo '</div>'; //Sorting Menu echo '<form id="library-form" class="media-upload-form validate" action="" method="post" enctype="multipart/form-data"><div id="media-items" class="media-items-' . $post_id . '">'; ?> <script type="text/javascript"> <!-- jQuery(function($){ var preloaded = $(".media-item.preloaded"); if ( preloaded.length > 0 ) { preloaded.each(function(){prepareMediaItem({id:this.id.replace(/[^0-9]/g, '')},'');}); //updateMediaForm(); } }); --> //Set default Soundcloud Is Gold Settings <?php get_soundcloud_is_gold_default_settings_for_js(); ?> </script> <?php if (isset($soundcloudIsGoldApiResponse['response']) && $soundcloudIsGoldApiResponse['response']) { foreach ($soundcloudIsGoldApiResponse['response'] as $soundcloudIsGoldtrack) { ?> <div class="media-item preloaded" id="media-item-<?php echo $soundcloudIsGoldtrack->id; ?> "> <a href="#" class="toggle describe-toggle-on soundcloud" id="show-<?php echo $soundcloudIsGoldtrack->id; ?> ">Show</a> <a href="#" class="toggle describe-toggle-off soundcloudMM">Hide</a> <div class="filename new"><span class="title soundcloudMMTitle" id="soundcloudMMTitle-<?php echo $soundcloudIsGoldtrack->id; ?> "><?php echo $soundcloudIsGoldtrack->title; ?> </span></div> <table class="slidetoggle describe startclosed soundcloudMMWrapper soundcloudMMMainWrapper <?php echo $soundcloudIsGoldSelectedFormat; ?> "> <thead id="media-head-<?php echo $soundcloudIsGoldtrack->id; ?> " class="media-item-info"> <tr valign="top"> <td id="thumbnail-head-<?php echo $soundcloudIsGoldtrack->id; ?> " class="A1B1"> <p><a href="<?php echo $soundcloudIsGoldtrack->{'permalink-url'}; ?> " title="Go to the Soundcloud page" target="_blank"><img id="soundcloudMMThumb-<?php echo $soundcloudIsGoldtrack->id; ?> " style="margin-top: 3px;" alt="" src="<?php echo $soundcloudIsGoldtrack->{'artwork-url'} != '' ? $soundcloudIsGoldtrack->{'artwork-url'} : SIG_PLUGIN_DIR . "images/noThumbnail.gif"; ?> " class="thumbnail"></a></p> </td> <td> <p><strong>Title:</strong> <?php echo $soundcloudIsGoldtrack->title; ?> </p> <p id="soundcloudMMId-<?php echo $soundcloudIsGoldtrack->id; ?> " class="soundcloudMMId"><strong>id:</strong> <?php echo $soundcloudIsGoldtrack->id; ?> </p> <p><strong>Upload date:</strong> <?php echo $soundcloudIsGoldtrack->{'created-at'}; ?> </p> <p><strong>Duration:</strong> <span id="media-dims-<?php echo $soundcloudIsGoldtrack->id; ?> "><?php echo $soundcloudIsGoldtrack->duration; ?> </span></p> <p><strong>Url:</strong> <a id="videoUrl-<?php echo $soundcloudIsGoldtrack->id; ?> " href="<?php echo $soundcloudIsGoldtrack->{'permalink-url'}; ?> " title="Go to the video page" target="_blank"><?php echo $soundcloudIsGoldtrack->{'permalink-url'}; ?> </a></p> </td> <td> <tbody> <tr class="soundcloudMM_description"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Description</span><br class="clear"></label></th> <td class="field"> <p class="text soundcloudMMDescription" id="soundcloudMMDescription-<?php echo $soundcloudIsGoldtrack->id; ?> "><?php echo $soundcloudIsGoldtrack->description; ?> </p> </td> </tr> <tr class="soundcloudMM_settings"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Settings</span><br class="clear"></label></th> <td class="field"> <input type="checkbox" <?php echo $soundcloudIsGoldSettings[0] ? 'checked="checked"' : ''; ?> id="soundcloudMMAutoPlay-<?php echo $soundcloudIsGoldtrack->id; ?> " class="text soundcloudMMAutoPlay"> <label >Play Automaticly</label> <input type="checkbox" <?php echo $soundcloudIsGoldSettings[1] ? 'checked="checked"' : ''; ?> id="soundcloudMMShowComments-<?php echo $soundcloudIsGoldtrack->id; ?> " class="text soundcloudMMShowComments"> <label >Show comments <small>(standard and artwork player)</small></label> <input type="checkbox" <?php echo $soundcloudIsGoldSettings[2] ? 'checked="checked"' : ''; ?> id="soundcloudMMShowArtwork-<?php echo $soundcloudIsGoldtrack->id; ?> " class="text soundcloudMMShowArtwork"> <label >Show artwork <small>(html5 player)</small></label> <!-- <input type="text" class="soundcloudPlayercolor" value""/> --> </td> </tr> <tr class="soundcloudMM_playerType"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Player Type</span><br class="clear"></label></th> <td class="field"> <?php foreach (get_soundcloud_is_gold_player_types() as $type) { ?> <input type="radio" id="soundcloudMMMiniPlayer-<?php echo $soundcloudIsGoldtrack->id; ?> " value="<?php echo $type; ?> " name="soundcloudMMPlayerType-<?php echo $soundcloudIsGoldtrack->id; ?> " class="text soundcloudMMPlayerType" <?php echo $soundcloudIsGoldPlayerType === $type ? 'checked="checked"' : ''; ?> > <label><?php echo $type; if ($type == 'Artwork') { echo ' <small>(not available on free soundcloud account)</small>'; } ?> </label> <?php } ?> </td> </tr> <tr class="soundcloudMM_size"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Width</span><br class="clear"></label></th> <td class="field"> <ul id="soundcloudMMWidthSetting" class="subSettings texts soundcloudMMTabWidthSettings"> <li> <input name="soundcloudMMWidthType-<?php echo $soundcloudIsGoldtrack->id; ?> " <?php echo $soundcloudIsGoldWidthSettings['type'] == "wp" ? 'checked="checked"' : ''; ?> id="soundcloudMMWpWidth-<?php echo $soundcloudIsGoldtrack->id; ?> " value="wp" type="radio" class="soundcloudMMWpWidth soundcloudMMWidthType"/><label for="soundcloudMMWpWidth-<?php echo $soundcloudIsGoldtrack->id; ?> ">Media Width</label> <select class="soundcloudMMInput soundcloudMMWidth" name="soundcloud_is_gold_width_settings[wp]"> <?php foreach (get_soundcloud_is_gold_wordpress_sizes() as $key => $soundcloudIsGoldMediaSize) { ?> <?php $soundcloudIsGoldMediaSelected = $soundcloudIsGoldMediaSize[0] == $soundcloudIsGoldWidthSettings['wp'] ? 'selected="selected"' : ''; ?> <option <?php echo $soundcloudIsGoldMediaSelected; ?> value="<?php echo $soundcloudIsGoldMediaSize[0]; ?> " class="soundcloudMMWPSelectedWidth soundcloudMMWidth"><?php echo $key . ': ' . $soundcloudIsGoldMediaSize[0]; ?> </option> <?php } ?> </select> </li> <li> <input name="soundcloudMMWidthType-<?php echo $soundcloudIsGoldtrack->id; ?> " <?php echo $soundcloudIsGoldWidthSettings['type'] == "custom" ? 'checked="checked"' : ''; ?> id="soundcloudMMCustomWidth-<?php echo $soundcloudIsGoldtrack->id; ?> " value="custom" type="radio" class="soundcloudMMCustomWidth soundcloudMMWidthType"/><label for="soundcloudMMCustomWidth-<?php echo $soundcloudIsGoldtrack->id; ?> ">Custom Width</label> <input name="soundcloudMMCustomSelectedWidth-<?php echo $soundcloudIsGoldtrack->id; ?> " id="soundcloudMMCustomSelectedWidth-<?php echo $soundcloudIsGoldtrack->id; ?> " class="soundcloudMMInput soundcloudMMWidth soundcloudMMCustomSelectedWidth" type="text" value="<?php echo $soundcloudIsGoldWidthSettings['custom']; ?> " /> </li> </ul> </td> </tr> <tr class="soundcloudMM_color"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Colour</span><br class="clear"></label></th> <td class="field"> <div class="soundcloudMMColorPickerContainer" id="soundcloudMMColorPickerContainer-<?php echo $soundcloudIsGoldtrack->id; ?> "> <input type="text" id="soundcloudMMColor-<?php echo $soundcloudIsGoldtrack->id; ?> " class="soundcloudMMColor" name="soundcloudMMColor-<?php echo $soundcloudIsGoldtrack->id; ?> " value="<?php echo $soundcloudIsGoldColor; ?> " style="background-color:<?php echo $soundcloudIsGoldColor; ?> "/><a href="#" class="soundcloudMMBt soundcloudMMBtSmall inline blue soundcloudMMRounder soundcloudMMResetColor">reset to default</a> <div id="soundcloudMMColorPicker-<?php echo $soundcloudIsGoldtrack->id; ?> " class="shadow soundcloudMMColorPicker" ><div id="soundcloudMMColorPickerSelect-<?php echo $soundcloudIsGoldtrack->id; ?> " class="soundcloudMMColorPickerSelect"></div><a id="soundcloudMMColorPickerClose-<?php echo $soundcloudIsGoldtrack->id; ?> " class="blue soundcloudMMBt soundcloudMMColorPickerClose">done</a></div> </div> </td> </tr> <tr class="soundcloudMM_classes"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Extra classes</span><br class="clear"></label></th> <td class="field"> <input type="text" class="text soundcloudMMClasses" id="soundcloudMMClasses-<?php echo $soundcloudIsGoldtrack->id; ?> " value="<?php echo $soundcloudIsGoldClasses; ?> "> <p class="help">In case you need extra css classes (seperate with a space, no commas!)</p> </td> </tr> <tr class="soundcloudMM_player"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Preview</span><br class="clear"></label></th> <td> <p id="soundcloudMMEmbed-<?php echo $soundcloudIsGoldtrack->id; ?> " class="field soundcloudMMEmbed" style="text-align:center"> <!-- Soundcloud Preview here --> </p> <p class="soundcloudMMLoading soundcloudMMPreviewLoading" style="display:none"></p> </td> </tr> <tr class="soundcloudMM_shortcode"> <th valign="top" class="label" scope="row"><label><span class="alignleft">Shortcode</span><br class="clear"></label></th> <td class="field"> <input id="soundcloudMMShortcode-<?php echo $soundcloudIsGoldtrack->id; ?> " type="text" class="text soundcloudMMShortcode" value="[soundcloud <?php echo 'id=' . $soundcloudIsGoldtrack->id; ?> ']"> </td> </tr> <tr class="soundcloudMM_submit"> <td></td> <td class="savesend"> <a href="#" id="soundcloudMMInsert-<?php echo $soundcloudIsGoldtrack->id; ?> " class="button soundcloudMMInsert">Insert Soundcloud Player</a> <!-- <input type="submit" value="Insert into Post" name="" class="button"> --> <!-- <input type="button" id="soundcloudMMAddToGallery-<?php echo $soundcloudIsGoldtrack->id; ?> " value="Add to post's gallery" name="" class="button soundcloudMMAddToGallery"> <a href="#" id="soundcloudMMFeat-<?php echo $soundcloudIsGoldtrack->id; ?> " class="soundcloudMMFeat">Use as featured Soundcloud</a> --> </td> </tr> </tbody> </td> </tr> </thead> </table> </div> <?php } } else { if ($soundcloudIsGoldApiResponse['error'] === false) { $soundcloudIsGoldApiResponse['error'] = 'XML error'; } echo '<div class="soundcloudMMXmlError"><p>Oups! There\'s been a error while getting the tracks from soundcloud. Please reload the page.</p><p class="error">' . $soundcloudIsGoldApiResponse['error'] . '</p></div>'; } echo '<div id="colorpicker"></div>'; echo '</div></form>'; }
function soundcloud_is_gold_options() { $options = get_option('soundcloud_is_gold_options'); //printl($options); $soundcloudIsGoldActiveUser = isset($options['soundcloud_is_gold_active_user']) ? $options['soundcloud_is_gold_active_user'] : ''; $soundcloudIsGoldUsers = isset($options['soundcloud_is_gold_users']) ? $options['soundcloud_is_gold_users'] : ''; $soundcloudIsGoldSettings = isset($options['soundcloud_is_gold_settings']) ? $options['soundcloud_is_gold_settings'] : ''; $soundcloudIsGoldPlayerType = isset($options['soundcloud_is_gold_playerType']) ? $options['soundcloud_is_gold_playerType'] : ''; $soundcloudIsGoldPlayerTypeDefault = empty($soundcloudIsGoldPlayerType) ? TRUE : FALSE; $soundcloudIsGoldWidthSettings = isset($options['soundcloud_is_gold_width_settings']) ? $options['soundcloud_is_gold_width_settings'] : ''; $soundcloudIsGoldClasses = isset($options['soundcloud_is_gold_classes']) ? $options['soundcloud_is_gold_classes'] : ''; $soundcloudIsGoldColor = isset($options['soundcloud_is_gold_color']) ? $options['soundcloud_is_gold_color'] : ''; $soundcloudIsGoldApiCall = 'http://api.soundcloud.com/users/' . $soundcloudIsGoldActiveUser . '/tracks.xml?limit=1&client_id=9rD2GrGrajkmkw5eYFDp2g'; $soundcloudIsGoldApiResponse = get_soundcloud_is_gold_api_response($soundcloudIsGoldApiCall); if (isset($soundcloudIsGoldApiResponse['response']) && $soundcloudIsGoldApiResponse['response']) { foreach ($soundcloudIsGoldApiResponse['response'] as $soundcloudMMLatestTrack) { $soundcouldMMId = (string) $soundcloudMMLatestTrack->id; } } $soundcouldMMShortcode = '[soundcloud id=' . $soundcouldMMId . ']'; ?> <script type="text/javascript"> //Set default Soundcloud Is Gold Settings <?php get_soundcloud_is_gold_default_settings_for_js(); ?> </script> <div class="soundcloudMMWrapper soundcloudMMOptions soundcloudMMMainWrapper"> <div id="soundcloudMMTop" class="darkGreyGradient"> <a id="soundcloudMMLogo" class="orangeGradient" href="http://www.soundcloud.com" title="visit SoundCloud website"><img src="<?php echo SIG_PLUGIN_DIR; ?> /images/soundcloud-logo-sc.png" width="107" height="71" alt="Soundcloud Logo"/></a> <a id="soundcloudMMHeader" class="mediumGreyGradient textShadow" href="http://www.mightymess.com/soundcloud-is-gold-wordpress-plugin" alt="Visit Mighty Mess for more cool stuff"> <span class="soundcloudMMTitle">SoundCloud is gold <small>by Thomas Michalak</small></span> <span class="soundcloudMMUrl">www.mightymess.com/soundcloud-is-gold-wordpress-plugin</span> </a> <p id="soundcloudMMVersion">version <?php echo get_soundcloud_is_gold_version($options); ?> </p> </div> <div id="soundcloudMMMain" class="lightBlueGradient"> <form method="post" action="options.php" id="soundcloudMMMainForm" name="soundcloudMMMainForm" class=""> <p class="hidden soundcloudMMId" id="soundcloudMMId-<?php echo $soundcouldMMId; ?> "><?php echo $soundcouldMMId; ?> </p> <?php settings_fields('soundcloud_is_gold_options'); ?> <ul id="soundcloudMMSettings"> <!-- Username --> <li class="soundcloudMMBox"><label class="optionLabel">User Name</label> <?php get_soundcloud_is_gold_username_interface($options, $soundcloudIsGoldUsers); ?> </li> <!-- Default Settings --> <li class="soundcloudMMBox"><label class="optionLabel">Default Settings</label> <ul class="subSettings checkboxes"> <li><input type="checkbox" <?php echo isset($soundcloudIsGoldSettings[0]) && $soundcloudIsGoldSettings[0] ? 'checked="checked"' : ''; ?> name="soundcloud_is_gold_options[soundcloud_is_gold_settings][0]" value="true" class="soundcloudMMAutoPlay" id="soundcloudMMAutoPlay"/><label for="soundcloudMMAutoPlay">Play Automatically</label></li> <li><input type="checkbox" <?php echo isset($soundcloudIsGoldSettings[1]) && $soundcloudIsGoldSettings[1] ? 'checked="checked"' : ''; ?> name="soundcloud_is_gold_options[soundcloud_is_gold_settings][1]" value="true" class="soundcloudMMShowComments" id="soundcloudMMShowComments"/><label for="soundcloudMMShowComments">Show comments <small>(Standard and Artwork player)</small></label></li> <li><input type="checkbox" <?php echo isset($soundcloudIsGoldSettings[2]) && $soundcloudIsGoldSettings[2] ? 'checked="checked"' : ''; ?> name="soundcloud_is_gold_options[soundcloud_is_gold_settings][2]" value="true" class="soundcloudMMShowArtwork" id="soundcloudMMShowArtwork"/><label for="soundcloudMMShowArtwork">Show Artwork <small>(html5 player)</small></label></li> </ul> </li> <!-- Player Type --> <li class="soundcloudMMBox"><label class="optionLabel">Default Player Type</label> <ul class="subSettings radios"> <?php foreach (get_soundcloud_is_gold_player_types() as $type) { ?> <li><input name="soundcloud_is_gold_options[soundcloud_is_gold_playerType]" id="<?php echo $type; ?> " class="soundcloudMMPlayerType" type="radio" value="<?php echo $type; ?> " <?php if ($soundcloudIsGoldPlayerTypeDefault && $type == 'Standard') { echo 'checked="checked"'; } else { echo $soundcloudIsGoldPlayerType === $type ? 'checked="checked"' : ''; } ?> /><label for="<?php echo $type; ?> "><?php echo $type; if ($type == 'Artwork') { echo ' <small>(not available on free soundcloud account)</small>'; } if ($type == 'html5') { echo ' <small>new! (beta)</small>'; } ?> </label></li> <?php } ?> </ul> </li> <!-- Width --> <li class="soundcloudMMBox"><label class="optionLabel">Default Width</label> <ul id="soundcloudMMWidthSetting" class="subSettings texts"> <li> <input name="soundcloud_is_gold_options[soundcloud_is_gold_width_settings][type]" <?php echo $soundcloudIsGoldWidthSettings['type'] == "wp" ? 'checked="checked"' : ''; ?> id="soundcloudMMWpWidth" value="wp" type="radio" class="soundcloudMMWpWidth soundcloudMMWidthType radio"/><label for="soundcloudMMWpWidth">Media Width</label> <select class="soundcloudMMInput soundcloudMMWidth" name="soundcloud_is_gold_options[soundcloud_is_gold_width_settings][wp]"> <?php foreach (get_soundcloud_is_gold_wordpress_sizes() as $key => $soundcloudIsGoldMediaSize) { ?> <?php //First Time, then Other Times if ($soundcloudIsGoldWidthSettings['wp'] == 'medium') { $soundcloudIsGoldMediaSelected = $key == $soundcloudIsGoldWidthSettings['wp'] ? 'selected="selected"' : ''; } else { $soundcloudIsGoldMediaSelected = $soundcloudIsGoldMediaSize[0] == $soundcloudIsGoldWidthSettings['wp'] ? 'selected="selected"' : ''; } ?> <option <?php echo $soundcloudIsGoldMediaSelected; ?> value="<?php echo $soundcloudIsGoldMediaSize[0]; ?> " class="soundcloudMMWpSelectedWidth"><?php echo $key . ': ' . $soundcloudIsGoldMediaSize[0]; ?> </option> <?php } ?> </select> </li> <li> <input name="soundcloud_is_gold_options[soundcloud_is_gold_width_settings][type]" <?php echo $soundcloudIsGoldWidthSettings['type'] == "custom" ? 'checked="checked"' : ''; ?> id="soundcloudMMCustomWidth" value="custom" type="radio" class="soundcloudMMCustomWidth soundcloudMMWidthType radio"/><label for="soundcloudMMCustomWidth">Custom Width</label> <input name="soundcloud_is_gold_options[soundcloud_is_gold_width_settings][custom]" id="soundcloudMMCustomSelectedWidth" class="soundcloudMMInput soundcloudMMWidth soundcloudMMCustomSelectedWidth" type="text" name="soundcloud_is_gold_options[soundcloudMMCustomSelectedWidth]" value="<?php echo $soundcloudIsGoldWidthSettings['custom']; ?> " /> </li> </ul> </li> <!-- Color and Classes --> <li class="soundcloudMMBox"><label class="optionLabel">Extras</label> <ul class="subSettings texts"> <li> <label>Color</label> <div class="soundcloudMMColorPickerContainer" id="soundcloudMMColorPickerContainer"> <input type="text" class="soundcloudMMInput soundcloudMMColor" id="soundcloudMMColor" name="soundcloud_is_gold_options[soundcloud_is_gold_color]" value="<?php echo $soundcloudIsGoldColor; ?> " style="background-color:<?php echo $soundcloudIsGoldColor; ?> "/><a href="#" class="soundcloudMMBt soundcloudMMBtSmall inline blue soundcloudMMRounder soundcloudMMResetColor">reset to default</a> <div id="soundcloudMMColorPicker" class="shadow soundcloudMMColorPicker"><div id="soundcloudMMColorPickerSelect" class="soundcloudMMColorPickerSelect"></div><a id="soundcloudMMColorPickerClose" class="blue soundcloudMMBt soundcloudMMColorPickerClose">done</a></div> </div> </li> <li class="clear"> <label>Classes <small>(no commas)</small></label><input class="soundcloudMMInput soundcloudMMClasses" type="text" name="soundcloud_is_gold_options[soundcloud_is_gold_classes]" value="<?php echo $soundcloudIsGoldClasses; ?> " /> </li> </ul> </li> <!-- Advance Options --> <!-- <li class="hidden soundcloudMMBox"><label class="optionLabel">Advanced Options</label> <?php //soundcloud_is_gold_advanced_options() ?> </li> --> <!-- Preview --> <li class="soundcloudMMBox"><label class="optionLabel previewLabel">Live Preview <small>(your latest track)</small></label> <?php if ($soundcloudIsGoldApiResponse['response']) { ?> <p class="soundcloudMMEmbed soundcloudMMEmbedOptions" style="text-align:center;"> <!-- Soundcloud Preview here --> </p> <p class="soundcloudMMLoading soundcloudMMPreviewLoading" style="display:none"></p> <?php } else { ?> <!-- Error getting XML --> <div class="soundcloudMMXmlError"><p><?php echo $soundcloudIsGoldApiResponse['error'] ? $soundcloudIsGoldApiResponse['error'] : "Oups! There's been a error while getting the tracks from soundcloud. Please reload the page."; ?> </p></div> <?php } ?> </li> </ul> <!-- Submit --> <p id="soundcloudMMSubmit"><input type="submit" name="Submit" value="<?php _e('Save Your SoundCloud Settings'); ?> " class="soundcloudMMBt blue"/></p> </form> </div> <ul id="soundcloudMMExtras" class="lightGreyGradient"> <li><a href="http://soundcloud.com/t-m" title="TM's music on SoundCloud" class="soundcloudMMBt orangeGradient soundcloudMMRounder">TM on SoundCloud</a></li> <li><a href="http://www.mightymess.com" title="Thomas Michalak's Website" class="soundcloudMMBt orangeGradient soundcloudMMRounder">More Mighty Mess</a></li> <li><a href="http://wordpress.org/tags/soundcloud-is-gold?forum_id=10" title="Soundcloud is Gold Forum" class="soundcloudMMBt orangeGradient soundcloudMMRounder">Forum</a></li> <li> <form class="soundcloudMMBtForm" action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="cmd" value="_s-xclick"> <input type="hidden" name="hosted_button_id" value="9VGA6PYQWETGY"> <input type="submit" name="submit" value="Donate via PayPal" class="soundcloudMMBt darkGrey soundcloudMMRounder" alt="PayPal - The safer, easier way to pay online."> <img alt="" border="0" src="https://www.paypalobjects.com/en_GB/i/scr/pixel.gif" width="1" height="1"> </form> </li> </ul> <p id="disclaimer">SoundCloud and SoundCloud Logo are trademarks of SoundCloud Ltd.</p> </div> <?php }