Welcome Guest.   Make a donation to an author on the site March 06, 2015, 05:05:01 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
The N.A.N.Y. Challenge 2015! Download dozens of custom programs!
   
  Forum Home Thread Marks Chat! Downloads Search Login Register  
  Show Posts
      View this member's profile 
      donate to someone Donate to this member 
Pages: Prev 1 ... 17 18 19 20 21 [22] 23 24 25 26 27 ... 31 Next
526  DonationCoder.com Software / FARR Plugins and Aliases / Re: google dollar exchange rate plugin -- sketch on: June 23, 2008, 06:38:03 AM
I added the more complex google syntax after all. Please testdrive it for bugs TucknDar and others  smiley

Currency Converter Mini now has two modes: default and advanced.
To use default, enter your default input/output currency to options once and after that just type "ex 100 "
To use advanced, type in a way that google currency converter understands: "ex 100$ in € " ("ex 100 $ in €" also works but does an extra search at "ex 100 ")
[attach=1]

[attach=2]

[attach=3]

I also noticed that the plugin uses google for every default search now so the cache is not working. I'll try to fix that too.
[copy or print]
// plugin script :
displayname="Currency Converter Mini";
versionstring="1.03.01";
releasedatestring="23.6.2008";
author="nod5";
updateurl="";
homepageurl="";
shortdescription="Convert from one currency to another via google.";
longdescription="Set default input/output currency in options (examples: $ £ GBP SEK canadian money or anything google accepts).\nDefault mode: \"ex 50 \".  Advanced mode: \"ex 50$ in € \" where $ and € are currency names. \"ex\" means exchange rate.";
advconfigstring="Currency Converter Mini";
readmestring="Currency Converter Mini";
iconfilename="favicon.ico";

aliasstr="ex";
regexstr="^ex ((?:\d|\.|\,|\w|€|£|\$| )*) $";
scriptregex=/^ex (\d(?:\d|\.|\,|\w|€|£|\$| )*) $/;
regexfilterstr="";
keywordstr="";
scorestr="300";

// type
UNKNOWN=0; FILE=1; FOLDER=2; ALIAS=3; URL=4; PLUGIN=5; CLIP=5;
// Postprocessing
IMMEDIATE_DISPLAY=0; ADDSCORE=1; MATCH_AGAINST_SEARCH=2;
// search state
STOPPED=0; SEARCHING=1;

var pre_string = "{\\rtf1\\ansi\\ansicpg1250\\deff0\\deftab709{\\fonttbl{\\f0\\fnil\\fcharset0 Arial;}}{\\colortbl ;\\red255\\green0\\blue0;}{\\*\\generator Msftedit 5.41.15.1507;}\\viewkind4\\uc1\\pard\\lang2057\\f0\\fs18 ";
var post_string = "\\par\n}";

var exrate = "";

function doQuery(querykey,querynokeyword){

querynokeyword = querynokeyword.replace(/,/g,'.');

// if non-digit, then assume custom currency input
// so google entire string if structured "111aaa in bbb "
//    else do nothing

var xtest = querynokeyword.search(/\D/g);
if (xtest != -1) {

var xtest = querynokeyword.search(/\d[^ ]*? (?:|[^ 0-9]*? )(?:|[^ 0-9]*? )in [^ 0-9]*?(?: [^ 0-9]*?|)/g);
// finds matches for:
// "ex 10$ in € "
// "ex 10 $ in € "
// "ex 10 swedish money in american money "

if (xtest == -1) {
  FARR.setStrValue("window.richeditmode",display);
 return;
}

  var url = "http://www.google.com/search?hl=en&q="+querynokeyword;
  var xmlhttp=new ActiveXObject("MSXML2.XMLHTTP");

  xmlhttp.onreadystatechange = function(){
    if (xmlhttp.readyState == 4) {
      var string = xmlhttp.responseText;
      string = string.match(/><b>\d.*?[^<(?:f|b)]*? = \d.*?<\/b>/g);
      string = string[0].replace(/<[^>]*?>/g,"");
      string = string.replace(/>/g,"");
      string = string.replace(/&#215;/g,"x");

      FARR.setStrValue("statusbar","Currency Converter Mini");
      FARR.setStrValue("window.richeditmode",pre_string+string+post_string);
      }
    }
  xmlhttp.open("GET",url,true);
  xmlhttp.send(null);

return;
}
//-----------------------------------


FARR.setStrValue("window.richeditmode","");

if(exrate == ""){
  var url = "http://www.google.com/search?hl=en&q=1"+myinputcurrency+"+in+"+myoutputcurrency;
  var xmlhttp=new ActiveXObject("MSXML2.XMLHTTP");

  xmlhttp.onreadystatechange = function(){
    if (xmlhttp.readyState == 4) {
      var string = xmlhttp.responseText;
      string = string.match(/<b>1 .*? = (?:\d|\.|\,)*? /g);
      var splitstring = string[0].split("=");
      var exrate = splitstring[1].slice(1,-1);
      string = exrate * querynokeyword;
      string = Math.round(string);
      string = querynokeyword+" "+myinputcurrency+" = "+string+" "+myoutputcurrency;
      FARR.setStrValue("statusbar","Currency Converter Mini");
      FARR.setStrValue("window.richeditmode",pre_string+string+post_string);
      }
    }
  xmlhttp.open("GET",url,true);
  xmlhttp.send(null);
}
else {
var string = exrate * querynokeyword;
string = Math.round(string);
string = querynokeyword+" "+myinputcurrency+" = "+string+" "+myoutputcurrency;
FARR.setStrValue("statusbar","Currency Convert Mini");
FARR.setStrValue("window.richeditmode",pre_string+string+post_string);
}

}

myinputcurrency="";
myoutputcurrency="";
function onOptionsChanged() {
    var options=new ActiveXObject("MSXML2.DOMDocument");
    options.load(currentDirectory+"\\options.xml")
    myinputcurrency=options.selectSingleNode("options/myinputcurrency").getAttribute("value");
    myoutputcurrency=options.selectSingleNode("options/myoutputcurrency").getAttribute("value");
}

function onInit(c) {
    currentDirectory=c;

    var options=new ActiveXObject("MSXML2.DOMDocument");
    if(!options.load(currentDirectory+"\\options.xml") ||
        options.selectSingleNode("options/myinputcurrency").getAttribute("value")=='' ||
        options.selectSingleNode("options/myoutputcurrency").getAttribute("value")=='') {
        options.loadXML("<options>\n"+
                        "<myinputcurrency label='exchange from :' value=''/>\n"+
                        "<myoutputcurrency label='exchange to :' value=''/>\n"+
                        "</options>");

        options.save(currentDirectory+"\\options.xml");
        options=null;
        FARR.showOptions();
    } else {
        onOptionsChanged();
    }
}



function onSearchBegin(querykey, explicit, queryraw, querynokeyword) {
  if(!explicit) {
    if(aliasstr.indexOf(querynokeyword)!=-1) {
      FARR.setState(querykey,1);
      FARR.emitResult(querykey,aliasstr, aliasstr, iconfilename,ALIAS,IMMEDIATE_DISPLAY,300);
      FARR.setState(querykey,0);
    }
    return;
  }
  FARR.setStrValue("statusbar","Currency Converter Mini");

    display = pre_string+"Type amount and hit \\b space\\b0"+post_string;

var xtest = queryraw.search(/(?:\d\D| \D)/g)
if (xtest != -1)
    display = pre_string+"use google syntax:  ex 100$ in € "+post_string;
  FARR.setStrValue("window.richeditmode",display);
}

function onRegexSearchMatch(querykey,querynokeyword) {
  var match_reg = querynokeyword.match(scriptregex);
  doQuery(querykey,match_reg[1]);
}

lanux128, I don't really have time to add the RatesFx at the moment. Hopefully someone else does.
527  DonationCoder.com Software / FARR Plugins and Aliases / Re: google dollar exchange rate plugin -- sketch on: June 22, 2008, 10:08:04 AM
I'm glad it works!

On custom currencies, see this and the post after.

I earlier considered adding modifiers for other currencies. But in the end I just aimed for the slimmest and quickest possible conversion from one specific currency to another. Adding modifiers could conflict with that somewhat. I could parse the string after "ex" for space separated substrings ("111 aaa bbb ") an if so treat the latter as modifiers. But then a users that wants "111 aaa bbb " would see results for "ex 111 " and "ex 111 aaa " on the way, which is ugly. (Using format "111aaa bbb" might work though). I'll think about it but at the moment I think complex conversions is well handled by the igo method ("igo 200 $ in €") or czechboys Google Calculator plugin (see link above).
528  DonationCoder.com Software / FARR Plugins and Aliases / Re: Post your FARR v2 Plugin Idea Requests Here - Plugin Writers Read In on: June 22, 2008, 07:21:12 AM
lanux, see this for ultrafast conversion from one specific currency to another. It now works again with a little help from czechboy.

Apart from that doing, for example, "igo 200$ in €" gives a google page with the conversion. The output is somewhat cluttered but can be read without scrolling.
[attach=1]
529  DonationCoder.com Software / FARR Plugins and Aliases / Re: google dollar exchange rate plugin -- sketch on: June 22, 2008, 06:56:01 AM
That indeed solves it. Thank you czechboy! smiley I was focusing so intensively on finding the problem with the second * that I didn't notice that it was the first * was the real culprit. Doh!    huh Grin embarassed

TucknDar, I can't reproduce that plugin configuration dialog crash. What currencies have you entered (if any)? What version of fscript.dll ? My config works fine with fscript.dll v1.0.0.7 (MD5 86b830da7611128f97b6b4b63b18f53e )

[copy or print]
// plugin script :
displayname="Currency Converter Mini";
versionstring="1.02.02";
releasedatestring="22.6.2008";
author="nod5";
updateurl="";
homepageurl="";
shortdescription="Convert from one currency to another via google.";
longdescription="To run the plugin, type \"ex 50 \" but replace 50 with the amount you want converted.\nSet input/output currency in advanced plugin options. (examples: $ £ GBP SEK canadian money )\nTest your input/output first by googling \"1 __ in __\", where _ is your input/output.\nAfter a FARR restart the first conversion uses google. Later conversions use the cached exchange rate.\nThe alias \"ex\" stands for exchange rate. The plugin converts one way, between two fixed currencies.\nFor other conversion needs just use google.";
advconfigstring="Currency Converter Mini";
readmestring="Currency Converter Mini";
iconfilename="favicon.ico";

aliasstr="ex";
regexstr="^ex ((?:\d|\.|\,)*?) $";
scriptregex=/^ex ((?:\d|\.|\,)*?) $/;
regexfilterstr="";
keywordstr="";
scorestr="300";

// type
UNKNOWN=0; FILE=1; FOLDER=2; ALIAS=3; URL=4; PLUGIN=5; CLIP=5;
// Postprocessing
IMMEDIATE_DISPLAY=0; ADDSCORE=1; MATCH_AGAINST_SEARCH=2;
// search state
STOPPED=0; SEARCHING=1;

var pre_string = "{\\rtf1\\ansi\\ansicpg1250\\deff0\\deftab709{\\fonttbl{\\f0\\fnil\\fcharset0 Arial;}}{\\colortbl ;\\red255\\green0\\blue0;}{\\*\\generator Msftedit 5.41.15.1507;}\\viewkind4\\uc1\\pard\\lang2057\\f0\\fs18 ";
var post_string = "\\par\n}";
var history = "";
var exrate = "";

function doQuery(querykey,querynokeyword){

querynokeyword = querynokeyword.replace(/,/g,'.');

if(exrate == ""){
  var url = "http://www.google.com/search?hl=en&q=1"+myinputcurrency+"+in+"+myoutputcurrency;
  var xmlhttp=new ActiveXObject("MSXML2.XMLHTTP");

  xmlhttp.onreadystatechange = function(){
    if (xmlhttp.readyState == 4) {
      var string = xmlhttp.responseText;
      string = string.match(/<b>1 .*? = (?:\d|\.|\,)*? /g);
      var splitstring = string[0].split("=");
      var exrate = splitstring[1].slice(1,-1);
      string = exrate * querynokeyword;
      string = Math.round(string);
      string = querynokeyword+" "+myinputcurrency+" = "+string+" "+myoutputcurrency;
      FARR.setStrValue("statusbar","Currency Converter Mini");
      FARR.setStrValue("window.richeditmode",pre_string+string+post_string);
      }
    }
  xmlhttp.open("GET",url,true);
  xmlhttp.send(null);
}
else {
var string = exrate * querynokeyword;
string = Math.round(string);
string = querynokeyword+" "+myinputcurrency+" = "+string+" "+myoutputcurrency;
FARR.setStrValue("statusbar","Currency Convert Mini");
FARR.setStrValue("window.richeditmode",pre_string+string+post_string);
}

}

myinputcurrency="";
myoutputcurrency="";
function onOptionsChanged() {
    var options=new ActiveXObject("MSXML2.DOMDocument");
    options.load(currentDirectory+"\\options.xml")
    myinputcurrency=options.selectSingleNode("options/myinputcurrency").getAttribute("value");
    myoutputcurrency=options.selectSingleNode("options/myoutputcurrency").getAttribute("value");
}

function onInit(c) {
    currentDirectory=c;

    var options=new ActiveXObject("MSXML2.DOMDocument");
    if(!options.load(currentDirectory+"\\options.xml") ||
        options.selectSingleNode("options/myinputcurrency").getAttribute("value")=='' ||
        options.selectSingleNode("options/myoutputcurrency").getAttribute("value")=='') {
        options.loadXML("<options>\n"+
                        "<myinputcurrency label='exchange from :' value=''/>\n"+
                        "<myoutputcurrency label='exchange to :' value=''/>\n"+
                        "</options>");

        options.save(currentDirectory+"\\options.xml");
        options=null;
        FARR.showOptions();
    } else {
        onOptionsChanged();
    }
}



function onSearchBegin(querykey, explicit, queryraw, querynokeyword) {
  if(!explicit) {
    if(aliasstr.indexOf(querynokeyword)!=-1) {
      FARR.setState(querykey,1);
      FARR.emitResult(querykey,aliasstr, aliasstr, iconfilename,ALIAS,IMMEDIATE_DISPLAY,300);
      FARR.setState(querykey,0);
    }
    return;
  }
  FARR.setStrValue("statusbar","Currency Converter Mini");
    display = pre_string+"Type amount and hit \\b space\\b0"+post_string;
  FARR.setStrValue("window.richeditmode",display);
}

function onRegexSearchMatch(querykey,querynokeyword) {
  var match_reg = querynokeyword.match(scriptregex);
  doQuery(querykey,match_reg[1]);
}

I will put this in a proper plugin package later.
530  DonationCoder.com Software / FARR Plugins and Aliases / Re: google dollar exchange rate plugin -- sketch on: June 22, 2008, 06:04:40 AM
Thanks! Will try it now.
531  DonationCoder.com Software / FARR Plugins and Aliases / Re: google dollar exchange rate plugin -- sketch on: June 22, 2008, 05:58:02 AM
Yes, this doesn't work at the moment. It did work previously so something must have changed (at google or in the FARR update).

Here is the problem:

The plugin uses javascript to extract a part of the google search results page. Here is an example snippet from google:
Quote
<tr><td><img src=/images/calc_img.gif width=40 height=30 alt=""></td><td>&nbsp;</td><td nowrap><h2 class=r><font size=+1>1 US$ = 0.506303478 British pounds</td></tr><tr><td>
The plugin tries to extract "<b>1 US$ = 0.506303478 " from the snippet through this code:
[copy or print]
string = string.match(/<b>1 .* = (?:\d|\.|\,)*? /g);
But somehow that does not stop at "0.506303478 " anymore but grabs a longer string. I can't see the error here. The last ? is supposed to make the search ungreedy (and I think it ought to work even without it). I just now also tried to use /gU but that doesn't work either. I'm sure there is some other way to do it but I'm bad at regexp in javascript and will have to look it up some more. If anyone spots a solution right away, please post it here.
532  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 20, 2008, 07:13:57 PM
s.newave, as for the arrow keys, something like that could probably be implemented through javascript in each .html file ( for example http://code.google.com/p/js-hotkeys/ and then set up/down to send tab/ctrl-tab), but if a general solution is possible to build into FARR then all the better.
533  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 20, 2008, 04:30:56 AM
Thanks, that was it.
Once we have some way to force focus back to the inputbox and get farr:// links working then I can implement the mp3 album cover displayer idea. Yay!
edit: removed code, it was buggy
534  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 20, 2008, 03:01:20 AM
great! But if I want this in the meantime it should be doable through a plugin right? I've just now tried getting it to run via the javascript plugin system. I think I need something like this:
Formatted for Javascript with the GeSHI Syntax Highlighter [copy or print]
  1. FARR.setStrValue("launch","htmlviewurl filename.html");
But I haven't gotten it to run just yet.
535  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 20, 2008, 02:33:33 AM
quick question: Can FARR display the html on the fly when a searchphrase is entered (without pressing enter)? Or do I need to handle that through a plugin?
536  Main Area and Open Discussion / Living Room / Re: Dino Run - cool online retro style multiplayer game on: June 19, 2008, 04:37:54 PM
Yes, really fun! I haven't grown tired of it yet. It looks boringly simple at first glance but is actually really challenging in multiplayer mode. I first played as a guest but now finally registered a nick and realized that there are more maps available when you level up!
537  DonationCoder.com Software / Find And Run Robot / Re: [bug] tooltip with file name blocks click on: June 17, 2008, 08:02:09 PM
Since all the tooltip contains is the full file name its position seems fine. It only needs to let clicks through.
Explorer and some other programs have tooltip windows that display other info than the filename. In such cases it makes sense to not place the tooltip directly over the file name. But what is the point of moving the tooltip like that in FARR? (assuming that click through tooltips are doable)
538  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 17, 2008, 07:50:05 PM
great!  Thmbsup I look forward to testing this cool feature some more.
539  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 17, 2008, 05:30:13 PM
Mouser, farr:// links presently only seem to work with showhtml, not showfile or igo. Correct?

I saved this test html code to the local file "x.html":
[copy or print]
<a href='farr://htmlviewurl exacttimenow.com'><img src='%FARRDIR%\AliasGroups\Installed\Core_Aliases\icons\farr\core-internet_www.ico'></a><br>click the image to Internal Surf to exacttimenow.com<br><br><a href='farr://restartsearch gowebpage'>use internal command to launch FARR webpage in external browser</a>
When running it via igo, it displays (except for the image) but the links give this error popup:
"current contents are not safe for local launching."

When running it via an alias that does showfile x.html, then then source of the .html is displayed in FARR as plaintext.

edit: fixed typo
540  DonationCoder.com Software / Find And Run Robot / [bug] tooltip with file name blocks click on: June 17, 2008, 05:05:53 PM
Here is a small bug: when browsing files and the filename is wider than the filename column, holding the mouse pointer over the filename opens a tooltip with the complete filename right above the original filename and extending outside the column and even outside the FARR window (see screencap). Great, but one problem: it is then not possible to click on the filename.
Suggested fix: allow clicks to pass through the tooltip if possible.
[attach=1]
edit: changed "file path" in title to "file name"
541  DonationCoder.com Software / FARR Plugins and Aliases / Re: GTDTiddlyWikiPlus for FARR (alias pack) on: June 15, 2008, 10:18:45 AM
Some thoughts:

There's a very real risk that some users will also want more and more advanced browser related tools, plugins, aliases and add-ons (ad-blockers and so on). It could go downhill to bloat city from there...

I say stick to the core functionality of doing small tasks as quickly and as easily as possible. Primarily to ultraquickly find and operate on files, folders, programs, bookmarks, processes and system settings. Html View Mode adds the functionality of quickly displaying small webpages or local html documents. But that is in line with the core when used for small, clean pages displayed briefly (to check email, rss, tv-schedule, todo and so on). Not so for other heavy-duty, full screen and long time browsing tasks.

To get more specific, here are some possible features for Html View Mode:
1. adress field
2. toolbar buttons: back, forward, home...
3. various browser add-ons
4. full blown adblocker
5. greasemonkey/proxomitron style page manipulation tools
6. alias specific window position, size and focus options
7. tabbed browsing

I'm for 5 & 6 since they can enhance the core by simplifying pages before display and make interaction between Html View Mode and FARR easier through farr:// links.

I'm unsure if 1-4 and 7 would be needed for anything that a regular browser isn't already better suited for. Can you guys give some good examples for why they would be good in FARR? (I can see the point of a %lasturl% variable though)

Another thought: the Html View Mode risks shifting FARR from a very keyboard centric program (which is a great thing when it comes to speed) to something that may require both mouse and keyboard. Adding toolbars could increase that shift even more. The Html View Mode would "fit in" more with the rest of FARR if keyboard navigation for it could be enhanced somehow. For example, when navigating webpage elements with Tab/shift-tab can the selected element be more strongly marked visually through a larger and distinctly colored border? Can FARR take control of the up and down keys for the webpage so that page elements can be navigated that way too? Can FARR similarly control the number keys to click the 1st, 2nd and so on element the displayed html page?


So in summary, I hope that future Html View Mode enhancements are keyboard centric and stick to what I've called the core functionality. But of course in the end it is up to Mouser to set the course for FARR.
542  Main Area and Open Discussion / General Software Discussion / Re: Where to suggest / request Firefox Addons? on: June 15, 2008, 09:20:35 AM
Hi Kaon, this may not do exactly what you ask for but it's maybe close enough? (if it works - I haven't tried it)
https://addons.mozilla.or.../en-US/firefox/addon/1765
http://kb.mozillazine.org/Muting_browser

543  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 14, 2008, 09:16:57 AM
Here's an updated version of my test file "album.html" that now also can handle two search phrases (both must match) separated by a space:
Formatted for Javascript with the GeSHI Syntax Highlighter [copy or print]
  1. <HTML>
  2. <HEAD>
  3. </HEAD>
  4. <BODY>
  5.  
  6. <FORM NAME="a">
  7. <INPUT TYPE="hidden" NAME="b">
  8. </FORM>
  9.  
  10. <SCRIPT LANGUAGE="javascript">
  11.  
  12. var loc = window.location
  13. document.a.b.value = loc
  14.  
  15. var text = document.a.b.value
  16.  
  17. function delineate(str)
  18. {
  19. left = str.indexOf("?") + 1;
  20. return(str.substring(left));
  21. }
  22. xx = delineate(text);
  23. xx = xx.toLowerCase()
  24.  
  25. var ww = [];
  26. var pos=xx.indexOf(" ")
  27. if (pos>=0)
  28. var ww = xx.split(" ")
  29. else
  30. {
  31. pos=xx.indexOf("%20") //firefox compatibility mode, since javascript debugging is handy in FF
  32. if (pos>=0)
  33.  var ww = xx.split("%20")
  34. }
  35.  
  36. // document.write(xx+ "  " + ww[0] + "  " + ww[1] + "<br><br>");
  37.  
  38. function albummatch(zz)
  39. {
  40. var zz1 = zz.toLowerCase()
  41. var pos=zz1.indexOf(xx)
  42. if (pos>=0)
  43. document.write("<a href='" +zz+ "/test.m3u'><img BORDER=0 src='" +zz+ "/folder.jpg' width=200 height=200></a>")
  44. }
  45.  
  46. function albummatch2(zz)
  47. {
  48. var zz1 = zz.toLowerCase()
  49. var pos=zz1.indexOf(ww[0])
  50. var pos2=zz1.indexOf(ww[1])
  51. if (pos>=0 && pos2>=0)
  52. document.write("<a href='" +zz+ "/test.m3u'><img BORDER=0 src='" +zz+ "/folder.jpg' width=200 height=200></a>")
  53. }
  54.  
  55. xarr = new Array("beatles - yellow submarine", "rolling stones - exile on main street", "beatles - abbey road")
  56.  
  57. if (ww[1])
  58. for (var i = 0; i < xarr.length; i++) {
  59. albummatch2(xarr[i])
  60. }
  61. else
  62. for (var i = 0; i < xarr.length; i++) {
  63. albummatch(xarr[i])
  64. }
  65.  
  66.  
  67. </script>

I tried it with a much larger number of folders and it works fine. Promising!

Mouser, is it possible to use a special farr:// link to silently do a command line action? When clicking a specific image I want to send it's related folder to an external audio player through such a link. If possible then that sidesteps the use of .m3u playlist files.
544  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 14, 2008, 04:33:06 AM
I just tested and it indeed works!
[attachthumb=1]
I made an alias "alb" that passes the search string to a the file "album.html" as a parameter. So doing "alb beatl" passes "beatl". Album.html loops over a list of foldernames and displays an image if the foldername matches the passed string. Each displayed image links to a .m3u file that when run plays the tracks on the album.

So the plugin I requested here seems more and more doable: http://www.donationcoder....=8071.msg116150#msg116150
A drawback with the current test is that you in advance must index the folders and make the .html. A script can do that if the folders are well structured but it is still not ideal. It's also not as easy select and run a displayed match as in FARR's default mode. It would definitely be better if FARR's default mode could show a list of linked images like that. I think such a feature could be useful for other stuff too, like displaying thumbnails when searching for images. Or searching anything else for which a thumbnail can be useful really.

Here's "album.html" (to be placed in helpers folder):
Formatted for Javascript with the GeSHI Syntax Highlighter [copy or print]
  1. <HTML>
  2. <HEAD>
  3. </HEAD>
  4. <BODY>
  5.  
  6. <FORM NAME="a">
  7. <INPUT TYPE="hidden" NAME="b">
  8. </FORM>
  9.  
  10. <SCRIPT LANGUAGE="javascript">
  11.  
  12. var loc = window.location
  13. document.a.b.value = loc
  14.  
  15. var text = document.a.b.value
  16.  
  17. function delineate(str)
  18. {
  19. left = str.indexOf("?") + 1;
  20. return(str.substring(left));
  21. }
  22. xx = delineate(text);
  23.  
  24. document.write(xx+"<br><br>");
  25.  
  26. function albummatch(zz)
  27. {
  28. var pos=zz.indexOf(xx)
  29. if (pos>=0)
  30. document.write("<a href='" +zz+ "/test.m3u'><img BORDER=0 src='" +zz+ "/folder.jpg' width=200 height=200></a><br>")
  31. }
  32.  
  33. xarr = new Array("beatles - yellow submarine", "rolling stones - exile on main street", "beatles - abbey road")
  34.  
  35. for (var i = 0; i < xarr.length; i++) {
  36. albummatch(xarr[i])
  37. }
  38. </script>
And the alias:
[copy or print]
1000>>>album>->test param pass to album search .html | htmlviewurl %FARRDIR%\Helpers\album.html?$$1>+>^alb (.*)$
It also needs some folders and files of course. edit: See the array "xarr" above for details.


545  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 13, 2008, 06:56:33 PM
this gave me another thought..
perhaps one way we could give people to write a different kind of farr "plugin"
is to let an alias load an html/javascript page, and automatically set some javascript variables corresponding to the search string.

this is very similar to the dqsd idea but even simpler. FARR would simply load an html page and preset some variables so the javascript on the page could know what was typed into search string, and proceed to handle it the way it wants.
Isn't it possible to just make an alias that passes the search string as a parameter to the .html file? Without any plugin needed? (but maybe that was just what what you meant when you added quotes around the term plugin?)
546  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 13, 2008, 06:41:45 PM
The basic tiddlywiki.com runs in FARR but I can't save:
[attachthumb=1]
Edit: but I get the same error in my regular browser so FARR isn't the problem. It's pretty obvious that I don't know much about tiddlywiki Grin
547  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 13, 2008, 06:18:00 PM
I just played some more with the new Html View Mode. smiley I made a local .html file containing an ultracompact version of the Compact Calendar (  http://davidseah.com/page/compact-calendar ) and added some javascript to make it highlight the current date (= cell with light blue background in screencap) and scroll to the current week on launch. Needs some more work but so far it offers very quick date and week number lookup. Screencap (the red stuff in swedish are names of national holidays):
[attach=1]

With the farr:// functionality I think dynamically adding tasks to such a html calendar (or any other local html for that matter...) could be possible roughly like this: For each table cell, add a farr:// link that runs some command with the cell id as a parameter. That command (tied to an autohotkey script or some plugin) edits the basic html file by changing the contents of the cell with the matching id and then refreshes the the displayed html. Not a real replacement for google calendar or other full features calendars of course, but it could still be useful for some things.
548  DonationCoder.com Software / Find And Run Robot / Re: old IE of HTML view - solved on: June 13, 2008, 04:40:59 AM
czechboy, my FARR doesn't lose focus like that.
549  DonationCoder.com Software / Find And Run Robot / Re: Feature request: Quick stay on top button on: June 13, 2008, 04:35:39 AM
Good idea this!

A related suggestion: some way to temporarily make it harder to close the FARR window. (like the "protect tab" feature in Firefox).

Background:
I have enabled "Close Window after launch by default" and very often close FARR with esc. With the Html View Mode I at least have started to use FARR in slightly new ways (and I suspect that I won't be the only one doing so). Previously, I never had it visible more than a few seconds - open, find, run, close. Now I've also started to use it to display html files, websites or things like that that I want visible slightly longer while doing things in another window. But then it is very easy to accidentally close FARR. So a protection option makes sense.

more brainstorming on this idea:

Some visual indicator when FARR is in a protected state would be good also.

ctrl + escape could enable protection
double-tapping escape (or clicking the upper right corner X) could break the protection and close FARR
550  DonationCoder.com Software / Find And Run Robot / Re: Tip: Htmlviewurl works for local files too! :) on: June 12, 2008, 05:51:36 AM
kartal and others, here is an example alias that uses farr:// links:
[copy or print]
1000>>>test>->test | showhtml <a href='farr://htmlviewurl exacttimenow.com'><img src='%FARRDIR%\AliasGroups\Installed\Core_Aliases\icons\farr\core-internet_www.ico'></a><br>click the image to Internal Surf to exacttimenow.com<br><br><a href='farr://restartsearch gowebpage'>use internal command to launch FARR webpage in external browser</a>>+>^test$

[attach=1]
Pages: Prev 1 ... 17 18 19 20 21 [22] 23 24 25 26 27 ... 31 Next
DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.084s | Server load: 0.07 ]