jfg wrote:Is there a way to make it so that when you are on 2007 stats that can be added to the clipboard as well? I'm guessing this would be harder to do since league formats are different.
The code tries to assume as little as possible about league-specific stuff, so it shouldn't be much trouble. I'll take a whack at it later tonight.
Y! Friends and Family League - fantasyguru - pianow stats for 2007 Season (as of Fri, Apr 27):
Batters Batting Pos Name H/AB R HR RBI SB AVG C John Buck (KC - C) 15/43 7 4 6 0 .349 1B David Ortiz (Bos - 1B) 23/80 15 6 19 0 .288 2B Brandon Phillips (Cin - 2B) 20/85 13 5 13 5 .235 3B Garrett Atkins (Col - 3B) 20/77 10 2 9 1 .260 SS Michael Young (Tex - SS) 17/89 10 2 14 1 .191 CI Jose Vidro (Sea - 1B,2B) 23/72 9 2 8 0 .319 MI J.J. Hardy (Mil - SS) 24/86 13 6 14 0 .279 OF Ty Wigginton (TB - 1B,2B,3B,OF) 24/88 11 4 13 0 .273 OF Grady Sizemore (Cle - OF) 18/70 21 4 8 6 .257 OF Magglio Ordonez (Det - OF) 26/78 18 3 20 0 .333 OF Willy Taveras (Col - OF) 15/58 10 0 2 4 .259 Util Mike Lowell (Bos - 3B) 24/76 11 4 18 0 .316 BN Kenny Lofton (Tex - OF) 20/70 10 1 6 9 .286
Pitchers Pitching Pos Name IP W SV K ERA WHIP SP Chris Young (SD - SP) 27.0 2 0 21 4.33 1.48 SP Ian Snell (Pit - SP) 27.0 1 0 24 2.00 1.00 SP John Maine (NYM - SP) 26.1 3 0 22 1.71 1.10 RP Todd Jones (Det - RP) 11.0 0 8 2 3.27 1.27 RP Ryan Dempster (ChC - RP) 11.0 0 3 12 2.45 0.64 P David Weathers (Cin - RP) 9.0 0 5 6 3.00 1.11 P Henry Owens (Fla - RP) 12.2 1 1 6 2.84 1.18 BN Ben Sheets (Mil - SP) 30.0 1 0 13 4.50 1.17 BN Randy Wolf (LAD - SP) 30.0 3 0 31 4.20 1.17 DL Felix Hernandez (Sea - SP) DL 17.1 2 0 18 1.56 0.69
If you notice, the first line indicates which stats were being displayed ('2007 Season'), the date was selected ('Fri, Apr 27'), and the league and team ('Y! Friends and Family League - fantasyguru - pianow').
Play around with it, you'll see how it works. Hope it helps you out. I'm sure that eventually Yahoo will provide a printable version of the stats, but until then, enjoy. Let me know if you have any problems.
Last edited by Bwanna on Fri Apr 27, 2007 5:49 pm, edited 5 times in total.
With a couple of tweaks, I made the third bookmarklet ('ClipYahooRoster Bookmarklet - with stats') work with the Player List and Watch List pages. E.g., from this list:
http://baseball.fantasysports.yahoo.com/b2/1172/players
2. Right-click on one of the three bookmarklets ('ClipYahooRoster Bookmarklet', 'ClipYahooRoster Bookmarklet - compact', or 'ClipYahooRoster Bookmarklet - with stats')
3. Select 'Add to Favorites...' from the menu that pops up. When it says 'Security Alert: You are adding a favorite that may not be safe. Do you want to continue?' select 'Yes'
4. An 'Add a Favorite' dialog box should popup with a default name 'Clip Yahoo Roster' (depending on which of the three you chose above), and 'Create in' set to 'Favorites'. Click 'Add'.
5. Go to your Yahoo roster page in the browser.
6. Go to the IE favorites menu, and select the bookmark you just added ('Clip Yahoo Roster'). A warning will pop up saying 'Do you want to allow this webpage to access your clipboard?'. Click 'Allow access'. At that point it should display a dialog saying 'The following roster has been copied to the clipboard: ...'. Click 'OK'.
7. Your roster should be on your Windows clipboard to paste wherever.
Repeat steps 2-4 for the remaining two bookmarklets, and you should have three bookmarks in your favorites.