On Sun, Mar 1, 2009 at 5:00 PM, Alberto Santini <[email protected]>wrote:
> > > On Mar 1, 2:28 pm, Alberto Santini <[email protected]> wrote: > > On Feb 18, 2:40 pm, Christian Sonne <[email protected]> wrote: > > > > > > > > > It has much room for improvements, but I encourage you to play around > with > > > it, and suggestions for improvements are much welcome. > > > > I was wondering if it is possible passing MAX_RESULTS (at the moment > > 4) as option. > > I add the following notes: > > - it would be nice adding a title preview customization (actually > "Results for..."). For instance, getting the results of the search > ("Found 123 results for...") with the same mechanism of title or > preview parser fields. Maybe adding in the parser object an heading > field. > I suppose this could be done, but I must admit I cannot really see any especially practical use for this - perhaps to describe the search better? - maybe we should just display the description somewhere then? - number of results could be practical, and a maximum number of hits displayed too - and we should take more care to limit the length of previews by default I think.. > > - adding a debug field: when true it is displayed (with CmdUtils.Log) > the url called and the parameters passed. > I've actually thought about ways of doing this myself, while developing the parser - perhaps have it just show the actual page in the preview, and highlight the fields matched by the params? > > - maybe it would be interesting initializing title or preview parser > fields with a function: we would be able to process very complex page > that it would be impossible with one selector line, but this > suggestion would be far away the makeSearchCommand spirit. :) > This has always been my intent - the parser would 'simply' check if an argument was string or function, and if function it would pass the relevant jQuery object to it, and expect a list or string returned - I knew there had to be pages that were somehow too complex to scrape as simply as this, but I figured I'd do my absolute best to try and make it possible using selectors first... I've also realised that my whole postData thing should be changed, having just data which could be used for both GET and POST, and a method which would default to GET - these params should/could then be mirrored inside the parser, in case it uses JSON or something else than scrape... I hasten to say that everyone are more than welcome to contribute to this process by writing code, though I fear I haven't documented my code all that much yet - most of it should be understandable though, I hope... -- cers / Christian Sonne > Thanks in advance, > Alberto > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "ubiquity-firefox" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/ubiquity-firefox?hl=en -~----------~----~----~----~------~----~------~--~---
