/[Grep]/share/web/templates/index.html
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /share/web/templates/index.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 10 - (hide annotations)
Sun Feb 18 00:21:01 2007 UTC (17 years, 3 months ago) by dpavlin
File MIME type: text/html
File size: 1132 byte(s)
added quick +grep bookmarklet to add feeds
1 dpavlin 9 <%init>
2    
3     my $region = Jifty::Web::PageRegion->new(
4     name => 'results',
5     );
6    
7     Jifty->subs->add(
8     class => 'Result',
9     mode => 'Bottom',
10     region => 'results',
11     render_with => '/fragments/result',
12     );
13    
14     my $fetch = Jifty->web->new_action(
15     class => 'Fetch',
16     moniker => 'fetch',
17     arguments => { %ARGS },
18     sticky_on_success => 1,
19     );
20    
21     use Data::Dump qw/dump/;
22    
23     </%init>
24    
25     <&| /_elements/wrapper, title => 'Grep - powerfull RSS searcher' &>
26    
27 dpavlin 10 <span class="bookmarklet">
28     <a href="javascript:location.href='<% Jifty->web->url( path => '/add' ) %>?uri='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)" title="bookmarklet which you can drag and drop to bookmark toolback to quickly add feed to grep">+grep</a>
29     </span>
30    
31    
32 dpavlin 9 <% Jifty->web->form->start %>
33    
34     <% $fetch->form_field('q') %>
35     <% $fetch->form_field('feed') %>
36    
37     <% $fetch->button( label => 'Grep' ) %>
38    
39     <% Jifty->web->form->end %>
40    
41     % if ( my $result = Jifty->web->response->result('fetch') ) {
42     % if ( my $items = $result->content('items') ) {
43     % foreach my $i ( @$items ) {
44    
45     <& /fragments/result, item => $i &>
46    
47     % }
48     % }
49     % }
50    
51     Results: <% $region->render %>
52    
53     </&>

  ViewVC Help
Powered by ViewVC 1.1.26