View the DQSD CVS repository here:
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/dqsd/
Update of /cvsroot/dqsd/dqsd/searches
In directory usw-pr-cvs1:/tmp/cvs-serv8991/searches
Modified Files:
gg.xml
Log Message:
gg - /since values now re-accepts t,y,w,m and traps non-numlber errors
Index: gg.xml
===================================================================
RCS file: /cvsroot/dqsd/dqsd/searches/gg.xml,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -d -r1.18 -r1.19
*** gg.xml 24 Jul 2002 08:04:46 -0000 1.18
--- gg.xml 24 Jul 2002 16:26:17 -0000 1.19
***************
*** 11,15 ****
<tr><td>/images</td><td> - </td><td>Search for images.</td></tr>
<tr><td>/news</td><td> - </td><td>Search for news (<i>warning : google news
still in beta, .com only, english only mode</i>).</td></tr>
! <tr><td>/since:days</td><td> - </td><td>Search pages based on when they were
indexed. Use days to specify when.</td></tr>
<tr><td>/cache</td><td> - </td><td>Given a URL, loads Google's cached copy of
the web page.</td></tr>
<tr><td>/related</td><td> - </td><td>Given a URL, finds other sites closely
related.</td></tr>
--- 11,22 ----
<tr><td>/images</td><td> - </td><td>Search for images.</td></tr>
<tr><td>/news</td><td> - </td><td>Search for news (<i>warning : google news
still in beta, .com only, english only mode</i>).</td></tr>
! <tr><td>/since:days</td><td> - </td><td>Search pages based on when they were
indexed. Use either a number to specify when, or
! <div style="padding: 0 0 0 20px">
! /since:t - indexed today<br/>
! /since:y - indexed yesterday<br/>
! /since:w - indexed in the last 7 days<br/>
! /since:m - indexed in the last 30 days
! </div>
! </td></tr>
<tr><td>/cache</td><td> - </td><td>Given a URL, loads Google's cached copy of
the web page.</td></tr>
<tr><td>/related</td><td> - </td><td>Given a URL, finds other sites closely
related.</td></tr>
***************
*** 191,195 ****
var today = new Date();
var todayj = julian(today.getYear(),today.getMonth()+1,today.getDate());
! var sincej = todayj - args.switch_val["since"];
args.q = args.q + " daterange:" + sincej + "-" + todayj;
}
--- 198,216 ----
var today = new Date();
var todayj = julian(today.getYear(),today.getMonth()+1,today.getDate());
! var deltadays;
! switch ( args.switch_val["since"] )
! {
! case "t": deltadays = 0; break;
! case "y": deltadays = 1; break;
! case "w": deltadays = 7; break;
! case "m": deltadays = 30; break;
! default: deltadays = args.switch_val["since"]; break;
! }
! if( isNaN(deltadays) )
! {
! nullArgs("gg","?");
! return false;
! }
! var sincej = todayj - deltadays;
args.q = args.q + " daterange:" + sincej + "-" + todayj;
}
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
DQSD-CVS mailing list
https://lists.sourceforge.net/lists/listinfo/dqsd-cvs
DQSD CVS repository:
http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/dqsd/