Andrew's Songs
Across the Universe - Beatles
-All You Need Is Love - ohn Lennon/Paul McCartney
+All You Need Is Love - Beatles
Amie - Pure Prairie League
Breakdown - Tom Petty
Brown Eyed Girl - Van Morrison
Country Road - John Denver
+Daydream Believer - Monkees
Desperado - The Eagles
Drugstore Novels - Cast of Shadows
Fire and Rain - James Taylor
Hold On - Kansas
Hotel California - Eagles
I Can See Clearly Now - Johnny Nash or Jimmy Cliff
-I Still Can't Say Goodbye - Chet Atkins
-I'm Your Captain - Grand Funk Railroad
+I'm a Believer - Monkees
Imagine - John Lennon
+I'm Your Captain - Grand Funk Railroad
+I Still Can't Say Goodbye - Chet Atkins
Kashmir - Led Zeppelin
Last Man on Earth - Alice Cooper
Leather And Lace - Stevie Nicks
Sister Golden Hair - America
Sitting on the Dock of the Bay - Otis Redding
Space Oddity - David Bowie
-Strong Enough To Win - Mike Fraser
+Strong Enough to Win - Mike Fraser
Swingtown - Steve Miller
Take It Easy - Eagles
Turn the Page - Bob Seager
Who'll Stop The Rain - Creedence Clearwater Revival
You Ain't Seen Nothing Yet - Backman Turner Overdrive
Young as You - Mike Fraser
-I'm a Believer - Monkees
-Daydream Believer - Monkees
Herb Medley
-Panama Red - New Riders of the Purple Sage
-One Toke Over the Line - Brewer and Shipley
-Last Dance with Mary Jane - Tom Petty
Cherry Bomb - John Mellencamp
-Mellow Yellow - Donovan
Eight Miles High - The Bryds
+Last Dance with Mary Jane - Tom Petty
+Mellow Yellow - Donovan
+One Toke Over the Line - Brewer and Shipley
+Panama Red - New Riders of the Purple Sage
KARR
-Locomotive Breath - Jethro Tull
-Landslide - Fleetwood Mac
-Jenny Jenny - Tommy Tutone
-Norwegian Wood - Beatles
-Peaceful Easy Feeling - Eagles
+All Right Now - Free
Angel
-The Letter - Joe Cocker
-Sweet Melisa - Allman Brothers
+Badge
+Best of My Love - Eagles
+Blackbird - Beatles
+Bring It on Home
Can't find My Way Home - Steve Windwood
-Wish You Were Here - Pink Floyd
-From the Beginning - ELP
+Can't You See - Marshall Tucker
+Casey Jones - Grateful Dead
Drugstore Novels - Cast of Shadows
-Tequila Sunrise - Eagles
-Space Oddity - David Bowie
-Nowhere Man - Beatles
-Seven Bridges Road - Eagles
-Stuck in the Middle With You - Stealers Wheel
-Suite Judy Blue Eyes - Crosby, Stills and Nash
Dust in the Wind - Kansas
-Badge
For What It's Worth
-Ramblin' Man - Allman Brothers
-Sister Golden Hair - America
-Take It Easy - Eagles
-Ventura Highway - America
-Wild Nights - Van Morrison
-All Right Now - Free
-Blackbird - Beatles
-Lucky Man - ELP
-Casey Jones - Grateful Dead
-Turn the Page - Bob Segar
+From the Beginning - ELP
Gold Dust Woman
+Hold On/Your Move - Triumph/Yes
+Jenny Jenny - Tommy Tutone
+Landslide - Fleetwood Mac
+Let It Be - Beatles
+Locomotive Breath - Jethro Tull
+Lucky Man - ELP
Lying Eyes - Eagles
+Norwegian Wood - Beatles
+Nowhere Man - Beatles
Panama Red
+Peaceful Easy Feeling - Eagles
+Pink Houses - John Cougar
+Ramblin' Man - Allman Brothers
+Seven Bridges Road - Eagles
+Sister Golden Hair - America
Something - Beatles
-Best of My Love - Eagles
Southern Cross
+Space Oddity - David Bowie
+Stuck in the Middle With You - Stealers Wheel
+Suite Judy Blue Eyes - Crosby, Stills and Nash
+Sweet Melisa - Allman Brothers
+Take It Easy - Eagles
+Tequila Sunrise - Eagles
+The Letter - Joe Cocker
The Weight
-What I Like About You - Romantics
-Let It Be - Beatles
-Pink Houses - John Cougar
-Can't You See - Marshall Tucker
-Wagon Wheel - Darius Rucker
+Turn the Page - Bob Segar
Under the Boardwalk - Drifters
-Bring It on Home
-Hold On/Your Move - Triumph/Yes
+Ventura Highway - America
+Wagon Wheel - Darius Rucker
+What I Like About You - Romantics
+Wild Nights - Van Morrison
+Wish You Were Here - Pink Floyd
New Songs
-I Can See Clearly Now - Johnny Nash
-California Dreaming - Mama's and the Papa's
-Mrs. Robinson - Simon and Garfunkel
All You Need is Love - Beatles
-Dr. My Eyes - Jackson Browne
-Crossroads - Cream
-Our House - Crosby, Stills, Nash and Young
-My Back Pages
Behind Blue Eyes - The Who
-I Can't Tell You Why - Eagles
-Wild World - Cat Stevens
+California Dreaming - Mama's and the Papa's
+Cherry, Cherry - Neil Diamond
Crazy Love - Poco
+Crossroads - Cream
+Dreams - Molly Hatchet
+Dr. My Eyes - Jackson Browne
Evil Ways - Santana
+Funk 49 - Joe Walsh
Harvest Moon - Neil Young
+I Can See Clearly Now - Johnny Nash
+I Can't Tell You Why - Eagles
Keep On Rockin' Me Baby - Steve Miller
+Mrs. Robinson - Simon and Garfunkel
+My Back Pages
One of These Nights - Eagles
+One Way Out - Allman Brothers
+Our House - Crosby, Stills, Nash and Young
Refugee - Tom Petty
Sandman - America
Seagull
-You're So Vain - Carly Simon
-What I've Already Heard - Mike Fraser
-Under the Milky Way - The Church
Stray Cat Strut - Stray Cats
-One Way Out - Allman Brothers
-Dreams - Molly Hatchet
-Funk 49 - Joe Walsh
-Cherry, Cherry - Neil Diamond
Sweet Caroline - Neil Diamond
+Under the Milky Way - The Church
+What I've Already Heard - Mike Fraser
+Wild World - Cat Stevens
+You're So Vain - Carly Simon
Turn The Page
Venus
We Can Work it Out
-Wild Nights
+Wild Nights
\ No newline at end of file
<div id="content">
<?php
+global $songs;
+
$artistsSongs = array();
+debug ("Processing songs");
+
foreach ($songs as $song) {
+ debug ("Song: $song");
$songArtist = getArtist ($song);
if ($songArtist == $artist) {
<div id="content">
<?php
-global $songDir;
+global $songDir, $artists;
print "<ol>";
print basename ($song);
}
- if ($artist <> "") {
- print " - <a href=\"displayartist.php?artist=$artist\">$artist</a>";
+ print " - ";
+
+ if (in_array ($artist, $artists)) {
+ print "<a href=\"displayartist.php?artist=$artist\">$artist</a>";
+ } else {
+ print $artist;
} // if
print "</li>";
} // foreach
-print "</okkkl>";
+print "</ol>";
?>
</body>
$songDir = "/opt/songbook/Songs";
$debug = $_REQUEST["debug"];
+// Initialize music objects
+$songs = getSongs($songDir);
+$sets = getSets($songDir);
+$artists = getArtists($songs);
+
function debug ($msg) {
global $debug;
} // if
} // debug
-function getSongs () {
- global $songDir;
-
+function getSongs ($songDir) {
return glob("$songDir/*.pro");
} // getSongs
-function getSets () {
- global $songDir;
-
+function getSets ($songDir) {
return glob("$songDir/*.lst");
} // getSets
function songsDropdown () {
- $songs = getSongs();
+ global $songs;
print "<form method=\"get\" action=\"webchord.cgi\" name=\"song\">";
print "Songs: ";
} // songsDropdown
function artistsDropdown () {
- $songs = getSongs();
- $artists = getArtists ($songs);
+ global $artists;
print "<form method=\"get\" action=\"displayartist.php\" name=\"artist\">";
print "Artists: ";
} // artistsDropdown
function setsDropdown () {
- $sets = getSets();
+ global $sets;
print "<form method=\"get\" action=\"displayset.php\" name=\"set\">";
print "Sets: ";
} // getArtist
function getArtists ($songs) {
- $artists = array();
-
foreach ($songs as $song) {
$artist = getArtist ($song);
return array_keys ($artists);
} // getArtists
-function formatTable ($songs) {
- echo "<ol>";
-
- foreach ($songs as $song) {
- $artist = getArtist ($song);
-
- $title = basename ($song, ".pro");
-
- echo "<li><a href=\"webchord.cgi?chordpro=$song\">$title</a>";
-
- if ($artist != "") {
- echo " ($artist)";
- } // if
- } // foreach
-
- echo "</ol>";
-} // formatTable