function search_all() { global $cfg, $db, $size, $search_string, $group_found, $match_found; authenticate('access_media'); // formattedNavigator $nav = array(); $nav['name'][] = 'Library'; $nav['url'][] = 'index.php'; $nav['name'][] = 'search for: ' . $search_string; require_once 'include/header.inc.php'; echo '<script type="text/javascript">'; echo 'showSpinner();'; echo '</script>'; @ob_flush(); flush(); album_artist(); album_title(); track_artist(); filesystem_match(); track_title(); echo '<script type="text/javascript">'; //echo 'hideSpinner();'; if ($group_found != 'none') { echo 'toggleSearchResults("' . $group_found . '")'; } echo '</script>'; ?> <script type="text/javascript"> function setFavorite(data) { if (data.action == "add") { $("#favorite_star_" + data.group_type + "-" + data.track_id).removeClass("fa fa-star-o").addClass("fa fa-star"); } else if (data.action == "remove") { $("#favorite_star_" + data.group_type + "-" + data.track_id).removeClass("fa fa-star").addClass("fa fa-star-o"); } }; </script> <?php if (!$match_found) { echo "No match found."; } require_once 'include/footer.inc.php'; }
<trackList> <?php while (have_tracks()) { the_track(); ?> <track> <creator><?php artist_name(); ?> </creator> <location><?php track_stream(); ?> </location> <title><?php track_title(); ?> </title> <image><?php release_cover_tiny(); ?> </image> <identifier><?php track_id(); ?> </identifier> </track> <?php } ?> </trackList>
/** * Displays form for with tracks, allowing adding or editing. * * @return void */ function ribcage_tracks_form() { global $release, $tracks, $track; ?> <form action="<?php echo str_replace('%7E', '~', $_SERVER['REQUEST_URI']); ?> &ribcage_step=3" method="post" id="ribcage_add_release" name="add_release"> <table width="200px"> <thead> <tr> <td>No</td> <td>Track Name</td> <td>Length</td> </tr> </thead> <?php $track_count = 1; ?> <?php while (have_tracks()) { the_track(); ?> <tr> <th scope="row"> <input type="text" style="width:30px;" class="regular-text" value="<?php track_no(); ?> " name="track_number_<?php echo $track_count; ?> " id="track_number_<?php echo $track_count; ?> " maxlength="200" /> </th> <td> <input type="text" style="width:320px;" class="regular-text" value="<?php track_title(); ?> " name="track_title_<?php echo $track_count; ?> " id="track_title_<?php echo $track_count; ?> " maxlength="200" /> </td> <td> <input type="text" style="width:70px;" class="regular-text" value="<?php echo $track['track_time']; ?> " name="track_time_<?php echo $track_count; ?> " id="track_time_<?php echo $track_count; ?> " maxlength="200" /> <input type="hidden" name="track_mbid_<?php echo $track_count; ?> " value='<?php echo $track['track_mbid']; ?> ' /> </td> </tr> <?php $track_count++; ?> <?php } ?> </table> <p class="submit"> <input type="submit" name="Submit" class="button-primary" value="Save Changes" /> </p> </form> <?php }