"osascript -e 'tell application \"iTunes\" to play track ",
ToString[track], " of user playlist \"", playlist, "\"'"
]];
~/.hgrc
file:
[extensions] hgext.extdiff = [extdiff] cmd.bbdiff = bbdiff opts.bbdiff = --resume --wait --reverseThen diff with the bbdiff command:
$ hg bbdiff [...]
The text widgets (UITextField, UITextView, etc) in the iPhone OS SDK appear to have been intentionally designed to allow as little control for 3rd party developers as possible. I found myself needing a user interface in an iPhone application which has buttons (in addition to the standard keyboard) that insert text into the currently selected UITextField. Neither UITextField nor any of it's parent classes or protocols have such a method.
One possible solution would be to get the contents of the UITextField, append the desired text to it, then set the contents of the UITextField to the new string. This gives the expected behavior if the text cursor is at the end of the text (which it usually is), but it does not give the correct behavior when the text cursor is anywhere else within the text.
There is a solution in iPhone OS 3.0. The method -(void)paste:(id)sender inserts the text from the system pasteboard at the current text cursor location. So all we need to do is temporarily hijack the system pasteboard. The basic steps are as follows:
Here is a simple category on UIResponder which adds a -(void)insertText:(NSString*)text method to this base class that should work on any text editing view.
@interface UIResponder(UIResponderInsertTextAdditions) - (void) insertText: (NSString*) text; @end @implementation UIResponder(UIResponderInsertTextAdditions) - (void) insertText: (NSString*) text { // Get a refererence to the system pasteboard because that's // the only one @selector(paste:) will use. UIPasteboard* generalPasteboard = [UIPasteboard generalPasteboard]; // Save a copy of the system pasteboard's items // so we can restore them later. NSArray* items = [generalPasteboard.items copy]; // Set the contents of the system pasteboard // to the text we wish to insert. generalPasteboard.string = text; // Tell this responder to paste the contents of the // system pasteboard at the current cursor location. [self paste: self]; // Restore the system pasteboard to its original items. generalPasteboard.items = items; // Free the items array we copied earlier. [items release]; } @end
Not so. While I was setting up my Airport Extreme 802.11N (gigabit ethernet) router I could have sworn I read that the fastest wireless performance would be achieved with 802.11N-Only 5GHz mode, so this is what I have been using for the past year+. All our computers and the AppleTV use 802.11N, but our iPhones only have 802.11G. So I set up my old Airport Extreme 802.11G (hershey kiss) router to handle the iPhones.
Anyway, this causes some annoying problems where apparently iPhone & desktop apps which are supposed to sync with each other don't work very well (Apple's Remote and Filemaker's Bento come to mind). Even though they're on the same subnet the syncing was just incredibly unreliable. It would work every once in a while, but usually it would just wait forever for a connection that never came.
A little frustrated with the situation I decided to try out some of the other modes for the Airport Extreme 802.11N router to see how much worse the network performance was. Perhaps I'd be willing to live with a slight performance hit if it meant more reliable iPhone app syncing.
I was shocked to find that, of all the available modes, the supposed fastest mode I had been using all this time was actually the slowest. I saw roughly twice the file transfer speed using 2.4 GHz, even when G/B compatible mode was enabled, even when the 802.11G iPhone was connected to the router loading web pages.
For each of the modes I copied a 246 MB file using scp from my MacBook Pro 15" downstairs to my Mac Pro desktop upstairs. Twice.
schofieldmaclap.local (802.11N/5.0GHz) Airport Extreme (gigabit) macpro.local [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 3.7MB/s 01:07 [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 3.7MB/s 01:06 schofieldmaclap.local (802.11N/G/B/2.4GHz) Airport Extreme (gigabit) macpro.local [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 7.9MB/s 00:31 [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 8.2MB/s 00:30 schofieldmaclap.local (802.11N/G/B/2.4GHz/iPhone) Airport Extreme (gigabit) macpro.local [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 7.9MB/s 00:31 [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 8.2MB/s 00:30 schofieldmaclap.local (802.11N/2.4GHz) Airport Extreme (gigabit) macpro.local [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 7.5MB/s 00:33 [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 8.5MB/s 00:29 schofieldmaclap.local (802.11N/5.0GHz) Airport Extreme (gigabit) macpro.local [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 3.5MB/s 01:11 [schofieldmaclap:tmp]$ scp ApertureTrial.dmg macpro.local:/tmp/ ApertureTrial.dmg 100% 246MB 3.5MB/s 01:11
I guess I'll be switching to 802.11N/G/B compatible mode.
Creating and Post-Processing Mathematica Graphics on Mac OS X
This user does a good (and thorough) job at enumerating a number of potential problems one could run into when creating and exporting graphics in Mathematica. In most cases the user also includes workarounds. In some cases the user's assumptions/explanations aren't technically correct, but the workarounds are still well thought out.
I | 431 |
a | 419 |
in | 259 |
at | 126 |
have | 77 |
bike | 62 |
work | 54 |
time | 52 |
out | 51 |
are | 48 |
ride | 45 |
think | 43 |
so | 43 |
run | 43 |
now | 42 |
like | 42 |
one | 38 |
d | 38 |
morning | 36 |
last | 36 |
can | 36 |
race | 35 |
miles | 35 |
mile | 35 |
home | 35 |
first | 35 |
way | 34 |
still | 34 |
year | 31 |
good | 31 |
is | 164 |
was | 108 |
be | 80 |
have | 77 |
bike | 62 |
up | 59 |
work | 54 |
time | 52 |
out | 51 |
ride | 45 |
been | 44 |
think | 43 |
run | 43 |
has | 43 |
like | 42 |
last | 36 |
can | 36 |
race | 35 |
home | 35 |
still | 34 |
had | 32 |
got | 32 |
get | 30 |
do | 30 |
back | 28 |
long | 27 |
will | 26 |
see | 26 |
did | 25 |
know | 24 |
melissa_raguet | 84 |
spoonshake | 69 |
esmithrunner | 32 |
erik_d | 28 |
dbfulton | 18 |
gutzville | 14 |
ultrashea | 11 |
erik__d | 9 |
adamengst | 9 |
chockenberry | 6 |
TwitterStatus[<netzturbine: ‚ô∫ @imabug cool, mathematica + the twitter API http://bit.ly/1Wv0iV - should work w/ !laconica 2>] |
TwitterStatus[<imabug: cool, mathematica and the twitter API http://bit.ly/1Wv0iV>] |
TwitterStatus[<kdrewien: RT @PragueBob Wolframs mainstream Mathematica software is plugging into Twitter: http://cli.gs/257htM Geeky!>] |
TwitterStatus[<lunajade: How to Twitter with Mathematica and analyze the data... http://bit.ly/14WA8F (via @WolframResearch) [VERY interesting...]>] |
TwitterStatus[<pythonism: http://twitter.com/MikeCr/statuses/1835493378 "@ruby_gem Mathematica, firefox, python">] |
Overall Place | Swim Seed | Swim Place | Swim Δ |
1 | 8 | 3 | - 5 |
2 | 27 | 15 | - 12 |
3 | 17 | 24 | 7 |
4 | 16 | 2 | - 14 |
5 | 78 | 50 | - 28 |
6 | 32 | 11 | - 21 |
7 | 28 | 35 | 7 |
8 | 15 | 27 | 12 |
9 | 63 | 71 | 8 |
10 | 42 | 44 | 2 |
11 | 9 | 9 | 0 |
12 | 62 | 31 | - 31 |
13 | 54 | 105 | 51 |
14 | 30 | 14 | - 16 |
15 | 200 | 155 | - 45 |
16 | 14 | 8 | - 6 |
17 | 83 | 83 | 0 |
18 | 6 | 33 | 27 |
19 | 47 | 53 | 6 |
20 | 66 | 34 | - 32 |
21 | 40 | 102 | 62 |
22 | 86 | 106 | 20 |
23 | 100 | 75 | - 25 |
24 | 45 | 59 | 14 |
25 | 120 | 58 | - 62 |
26 | 4 | 12 | 8 |
27 | 3 | 36 | 33 |
28 | 33 | 13 | - 20 |
29 | 51 | 25 | - 26 |
30 | 72 | 115 | 43 |
31 | 12 | 16 | 4 |
32 | 39 | 7 | - 32 |
33 | 65 | 66 | 1 |
34 | 330 | 240 | - 90 |
35 | 48 | 64 | 16 |
36 | 21 | 6 | - 15 |
37 | 13 | 5 | - 8 |
38 | 68 | 56 | - 12 |
39 | 212 | 89 | - 123 |
40 | 214 | 79 | - 135 |
41 | 67 | 45 | - 22 |
42 | 76 | 21 | - 55 |
43 | 75 | 211 | 136 |
44 | 81 | 63 | - 18 |
45 | 251 | 172 | - 79 |
46 | 44 | 114 | 70 |
47 | 162 | 95 | - 67 |
48 | 7 | 4 | - 3 |
49 | 74 | 92 | 18 |
50 | 55 | 48 | - 7 |
51 | 52 | 29 | - 23 |
52 | 237 | 124 | - 113 |
53 | 11 | 18 | 7 |
54 | 77 | 98 | 21 |
55 | 56 | 30 | - 26 |
56 | 117 | 104 | - 13 |
57 | 1 | 1 | 0 |
58 | 300 | 74 | - 226 |
59 | 151 | 125 | - 26 |
60 | 139 | 82 | - 57 |
61 | 274 | 151 | - 123 |
62 | 64 | 22 | - 42 |
63 | 122 | 87 | - 35 |
64 | 36 | 37 | 1 |
65 | 250 | 243 | - 7 |
66 | 154 | 148 | - 6 |
67 | 121 | 90 | - 31 |
68 | 136 | 258 | 122 |
69 | 282 | 146 | - 136 |
70 | 87 | 69 | - 18 |
71 | 112 | 110 | - 2 |
72 | 315 | 278 | - 37 |
73 | 24 | 19 | - 5 |
74 | 80 | 77 | - 3 |
75 | 135 | 184 | 49 |
76 | 69 | 97 | 28 |
77 | 185 | 163 | - 22 |
78 | 59 | 49 | - 10 |
79 | 128 | 94 | - 34 |
80 | 60 | 51 | - 9 |
81 | 187 | 28 | - 159 |
82 | 35 | 20 | - 15 |
83 | 113 | 134 | 21 |
84 | 90 | 40 | - 50 |
85 | 163 | 17 | - 146 |
86 | 22 | 38 | 16 |
87 | 133 | 200 | 67 |
88 | 267 | 73 | - 194 |
89 | 256 | 145 | - 111 |
90 | 92 | 122 | 30 |
91 | 159 | 206 | 47 |
92 | 165 | 130 | - 35 |
93 | 137 | 153 | 16 |
94 | 149 | 128 | - 21 |
95 | 104 | 80 | - 24 |
96 | 182 | 136 | - 46 |
97 | 26 | 46 | 20 |
98 | 172 | 93 | - 79 |
99 | 241 | 55 | - 186 |
100 | 277 | 109 | - 168 |
101 | 114 | 165 | 51 |
102 | 97 | 103 | 6 |
103 | 131 | 159 | 28 |
104 | 228 | 194 | - 34 |
105 | 46 | 117 | 71 |
106 | 141 | 199 | 58 |
107 | 132 | 162 | 30 |
108 | 246 | 132 | - 114 |
109 | 115 | 205 | 90 |
110 | 213 | 183 | - 30 |
111 | 127 | 181 | 54 |
112 | 157 | 147 | - 10 |
113 | 254 | 131 | - 123 |
114 | 266 | 256 | - 10 |
115 | 41 | 61 | 20 |
116 | 61 | 39 | - 22 |
117 | 43 | 41 | - 2 |
118 | 191 | 196 | 5 |
119 | 106 | 257 | 151 |
120 | 96 | 81 | - 15 |
121 | 234 | 60 | - 174 |
122 | 201 | 85 | - 116 |
123 | 108 | 142 | 34 |
124 | 161 | 218 | 57 |
125 | 123 | 149 | 26 |
126 | 98 | 150 | 52 |
127 | 138 | 271 | 133 |
128 | 265 | 179 | - 86 |
129 | 195 | 54 | - 141 |
130 | 50 | 86 | 36 |
131 | 53 | 161 | 108 |
132 | 170 | 137 | - 33 |
133 | 58 | 26 | - 32 |
134 | 169 | 120 | - 49 |
135 | 204 | 249 | 45 |
136 | 342 | 65 | - 277 |
137 | 91 | 100 | 9 |
138 | 103 | 47 | - 56 |
139 | 125 | 182 | 57 |
140 | 82 | 68 | - 14 |
141 | 88 | 76 | - 12 |
142 | 147 | 241 | 94 |
143 | 238 | 107 | - 131 |
144 | 303 | 202 | - 101 |
145 | 70 | 191 | 121 |
146 | 297 | 247 | - 50 |
147 | 188 | 178 | - 10 |
148 | 2 | 10 | 8 |
149 | 130 | 164 | 34 |
150 | 311 | 288 | - 23 |
151 | 168 | 187 | 19 |
152 | 283 | 158 | - 125 |
153 | 144 | 216 | 72 |
154 | 295 | 287 | - 8 |
155 | 208 | 244 | 36 |
156 | 287 | 157 | - 130 |
157 | 111 | 176 | 65 |
158 | 199 | 111 | - 88 |
159 | 272 | 223 | - 49 |
160 | 179 | 242 | 63 |
161 | 84 | 190 | 106 |
162 | 310 | 152 | - 158 |
163 | 109 | 118 | 9 |
164 | 37 | 67 | 30 |
165 | 180 | 227 | 47 |
166 | 340 | 135 | - 205 |
167 | 328 | 193 | - 135 |
168 | 263 | 197 | - 66 |
169 | 312 | 250 | - 62 |
170 | 148 | 143 | - 5 |
171 | 242 | 224 | - 18 |
172 | 278 | 230 | - 48 |
173 | 253 | 139 | - 114 |
174 | 292 | 279 | - 13 |
175 | 10 | 32 | 22 |
176 | 276 | 254 | - 22 |
177 | 18 | 101 | 83 |
178 | 155 | 167 | 12 |
179 | 271 | 276 | 5 |
180 | 102 | 169 | 67 |
181 | 192 | 248 | 56 |
182 | 257 | 78 | - 179 |
183 | 93 | 210 | 117 |
184 | 346 | 294 | - 52 |
185 | 255 | 269 | 14 |
186 | 158 | 192 | 34 |
187 | 49 | 171 | 122 |
188 | 126 | 201 | 75 |
189 | 143 | 140 | - 3 |
190 | 231 | 88 | - 143 |
191 | 220 | 186 | - 34 |
192 | 298 | 177 | - 121 |
193 | 107 | 144 | 37 |
194 | 94 | 129 | 35 |
195 | 129 | 188 | 59 |
196 | 184 | 274 | 90 |
197 | 116 | 273 | 157 |
198 | 224 | 259 | 35 |
199 | 186 | 214 | 28 |
200 | 174 | 198 | 24 |
201 | 290 | 221 | - 69 |
202 | 95 | 175 | 80 |
203 | 152 | 215 | 63 |
204 | 189 | 246 | 57 |
205 | 156 | 239 | 83 |
206 | 336 | 141 | - 195 |
207 | 118 | 174 | 56 |
208 | 197 | 91 | - 106 |
209 | 194 | 280 | 86 |
210 | 196 | 212 | 16 |
211 | 291 | 121 | - 170 |
212 | 190 | 189 | - 1 |
213 | 247 | 119 | - 128 |
214 | 286 | 126 | - 160 |
215 | 219 | 52 | - 167 |
216 | 229 | 170 | - 59 |
217 | 23 | 23 | 0 |
218 | 236 | 277 | 41 |
219 | 235 | 265 | 30 |
220 | 252 | 204 | - 48 |
221 | 258 | 281 | 23 |
222 | 99 | 84 | - 15 |
223 | 211 | 226 | 15 |
224 | 279 | 272 | - 7 |
225 | 216 | 267 | 51 |
226 | 167 | 116 | - 51 |
227 | 243 | 275 | 32 |
228 | 262 | 220 | - 42 |
229 | 230 | 154 | - 76 |
230 | 288 | 166 | - 122 |
231 | 337 | 251 | - 86 |
232 | 269 | 228 | - 41 |
233 | 233 | 252 | 19 |
234 | 20 | 208 | 188 |
235 | 110 | 185 | 75 |
236 | 308 | 284 | - 24 |
237 | 261 | 231 | - 30 |
238 | 245 | 127 | - 118 |
239 | 343 | 283 | - 60 |
240 | 160 | 70 | - 90 |
241 | 150 | 264 | 114 |
242 | 85 | 156 | 71 |
243 | 5 | 173 | 168 |
244 | 347 | 213 | - 134 |
245 | 153 | 203 | 50 |
246 | 175 | 219 | 44 |
247 | 339 | 298 | - 41 |
248 | 134 | 290 | 156 |
249 | 203 | 42 | - 161 |
250 | 348 | 282 | - 66 |
251 | 289 | 112 | - 177 |
252 | 124 | 168 | 44 |
253 | 218 | 238 | 20 |
254 | 145 | 207 | 62 |
255 | 119 | 113 | - 6 |
256 | 183 | 123 | - 60 |
257 | 299 | 236 | - 63 |
258 | 73 | 62 | - 11 |
259 | 302 | 261 | - 41 |
260 | 29 | 96 | 67 |
261 | 57 | 57 | 0 |
262 | 173 | 225 | 52 |
263 | 281 | 255 | - 26 |
264 | 31 | 99 | 68 |
265 | 275 | 270 | - 5 |
266 | 319 | 296 | - 23 |
267 | 181 | 245 | 64 |
268 | 178 | 301 | 123 |
269 | 89 | 108 | 19 |
270 | 307 | 291 | - 16 |
271 | 294 | 229 | - 65 |
272 | 215 | 43 | - 172 |
273 | 176 | 160 | - 16 |
274 | 270 | 180 | - 90 |
275 | 240 | 195 | - 45 |
276 | 217 | 263 | 46 |
277 | 318 | 302 | - 16 |
278 | 316 | 303 | - 13 |
279 | 285 | 237 | - 48 |
280 | 280 | 297 | 17 |
281 | 177 | 72 | - 105 |
282 | 207 | 234 | 27 |
283 | 314 | 217 | - 97 |
284 | 309 | 232 | - 77 |
285 | 306 | 253 | - 53 |
286 | 248 | 292 | 44 |
287 | 193 | 289 | 96 |
288 | 296 | 286 | - 10 |
289 | 227 | 285 | 58 |
290 | 171 | 222 | 51 |
291 | 345 | 304 | - 41 |
292 | 305 | 262 | - 43 |
293 | 71 | 268 | 197 |
294 | 264 | 266 | 2 |
295 | 226 | 235 | 9 |
296 | 225 | 209 | - 16 |
297 | 273 | 295 | 22 |
298 | 244 | 260 | 16 |
299 | 142 | 305 | 163 |
300 | 209 | 306 | 97 |
301 | 313 | 307 | - 6 |
Several years ago I spent a few hours implementing a feature in Mozilla, and then probably 10 times that amount of time dealing with the hassle of getting my code (which I was trying to give them for free) approved and into their sources. The incident left a bitter aftertaste.
Fast forward to present day. I was just reading through some WebKit sources and noticed a typo in one of the comments. So I decided to fix the typo and submit a patch to see how painful the process is for the competing project.
Index: JavaScriptCore/ChangeLog =================================================================== --- JavaScriptCore/ChangeLog (revision 42833) +++ JavaScriptCore/ChangeLog (working copy) @@ -1,3 +1,9 @@ +2009-04-24 Rob Raguet-Schofield + + Reviewed by NOBODY (OOPS!). + + * wtf/CurrentTime.h: + 2009-04-23 Mark Rowe With great sadness and a heavy heart I switch us back from YARR to WREC in Index: JavaScriptCore/wtf/CurrentTime.h =================================================================== --- JavaScriptCore/wtf/CurrentTime.h (revision 42833) +++ JavaScriptCore/wtf/CurrentTime.h (working copy) @@ -36,7 +36,7 @@ namespace WTF { // Returns the current system (UTC) time in seconds, starting January 1, 1970. // Precision varies depending on a platform but usually is as good or better - // then a millisecond. + // than a millisecond. double currentTime(); } // namespace WTF
Picky? Sure. But why not?
Update: patch approved after 5 hours.
The documentation for the Aiptek PocketCinema pico-projector claims to support the following video formats:
- MJPEG AVI (recommended)
- MPEG-4 ASF
So how do I convert video into one of these formats on a Mac with QuickTime Pro?
Test: Use QuickTime Player to Export Movie to MPEG-4.
Result: FAIL. PocketCinema hangs when attempting to preview video and needs to be reset by removing battery.
Test: Use QuickTime Player to Export Movie to AVI. MJPEG is not support. Try uncompressed, BMP, and Cinepak.
Result: FAIL. PocketCinema recognizes AVI file, does not hang, but also does not play any of the files (uncompressed, BMP, or Cinepak).
Test: Use QuickTime Player to Export Movie to QuickTime Movie with Motion JPEG codec.
Result: FAIL. PocketCinema does not recognize .mov file.
Test: Use QuickTime Player to Export to MPEG-4, then use Flv Crunch to convert to MPEG-4 again.
Result: Success! Apparently the projector has a problem with the MPEG4 generated by QuickTime, but does not have a problem with the MPEG4 generated by ffmpeg.
Behind the scenes Flv Crunch is just using the ffmpeg command line tool. The following command did the trick for me:
ffmpeg -i source.mp4 dest.mp4
I have written a blog entry titled Mapping GPS Data that has just been posted to the Wolfram Research blog.
In case you don't know, bookmarklets are bookmarks which run JavaScript code rather than open a specific web page. Here are a collection of bookmarklets I use on a semi-regular basis to speed up searching of frequently used web sites. Bookmarklets can do other things, since they run arbitrary JavaScript code.
To install them click on the hyperlink and drag it to your bookmarks bar (or maybe right/control-click on the link and choose a menu item to add to bookmarks). They may not work in all browsers, but these all work in Safari.
You can use them in one of two ways. First, if you just choose the bookmark it will pop up a dialog asking for the query text, then search the corresponding site for the text you enter. Second, you can select a piece of text on the current web page, then when you choose the bookmarklet it will automatically search the corresponding site for the selected text.
javascript:x=''+getSelection();if(!x.length){x=prompt('Wikipedia:','')}if(x&&x.length){location.href='http://en.wikipedia.org/w/wiki.phtml?search='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Dictionary:','')}if(x&&x.length){location.href='http:/dictionary.reference.com/search?q='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Thesaurus:','')}if(x&&x.length){location.href='http:/thesaurus.reference.com/search?q='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Google%20Images:','')}if(x&&x.length){location.href='http://images.google.com/images?hl=en&q='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Google%20News:','')}if(x&&x.length){location.href='http:/news.google.com/news?q='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Google%20Maps:','')}if(x&&x.length){location.href='http://maps.google.com/?q='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('IMDB:','')}if(x&&x.length){location.href='http:/imdb.com/Find?for='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('Amazon:','')}if(x&&x.length){location.href='http://www.amazon.com/exec/obidos/external-search/?keyword='+escape(x)}
javascript:x=''+getSelection();if(!x.length){x=prompt('eBay:','')}if(x&&x.length){location.href='http://search.ebay.com/search/search.dll?query='+escape(x)}