From vaesel at poczta.onet.pl Sat Feb 4 18:52:53 2006 From: vaesel at poczta.onet.pl (cyberrus) Date: Sat Feb 4 12:54:43 2006 Subject: [Slogger] non ascii characters in Slogger logs Message-ID: <43E4E9F5.4050703@poczta.onet.pl> Hi all. i'm really happy to have slogger back after little upgrade delay but... 1. i have problems with non ascii characters in XML logs - previous version converted all the text to UTF on-the-fly 2. i'd suggest having default description and keywords the empty string - it means to clean them up between logging (now i have both the datas from previous log and if i don't change them between logging all the logs has same descrition and keywords) 3. where has the context menu option gone? it was very very usefull From bweiss at sbceo.org Sat Feb 4 19:14:29 2006 From: bweiss at sbceo.org (B Weiss) Date: Sat Feb 4 22:15:03 2006 Subject: [Slogger] Trouble with title variable Message-ID: <43E56D95.7080903@sbceo.org> I love Slogger so much, I refuse to update Firefox unless Slogger works with it! I use it to save web pages so that I can later read them offline. After reading them, I end up deleting most of them. I have the log file turned off. Up until recently (0.5.11), I was able to save the pages using the $title variable in the name of the file: $title-$year-$month-$day_$hour-$minute-$second.$typeext Now, if $title is used in the filename, sometimes it works, and sometimes it doesn't. When it doesn't, it doesn't save anything - Web page only, complete web page, or text. I think it is choking on the length of the web page title. I could save pages with very long titles in 0.5.11 and truncate them later, if I was going to save them after reading them. As an example, try some of the tips at http://www.jsifaq.com). Even the longest titles saved OK. Now, they won't save. I'm using $filebase for now, but $title tends to gives a much more descriptive name, so I would prefer it. Any help would be appreciated! Thanks Betsy From tomthumb at tom.com Sat Feb 11 16:15:49 2006 From: tomthumb at tom.com (tomthumb@tom.com) Date: Sat Feb 11 03:16:43 2006 Subject: [Slogger] Slogger 0.6.20060201 totally broken in Firefox 1.5.0.1 - Really need help. Message-ID: <20060211161543.F98A.TOMTHUMB@tom.com> Hi, I've been a Slogger user for the longest time, ever since the very first version. This has remained my one essential extension for Firefox. I've been using 0.5.x until recently. When I upgraded Firefox to the latest 1.5.0.1, I decided to upgrade Slogger to the latest 0.6.20060201 as well. Alas, after 14 installs-uninstalls-reinstalls, I'm ready to admit defeat. I've tried manually tweaking prefs.js and installing Slogger to a new Firefox profile but nothing works. Slogger just won't function properly. Listed below are some of the major problems I'm facing right now (they affect several default profiles included in the original package): 1. With a fresh Slogger installation (all default settings) to a brand-new Firefox profile, everytime I choose "View RDF-XUL log" from the Slogger menu, I would get a "File not found". 2. As above, when I choose "View today's XML log file", I would get a 'unformatted' bunch of entries on a white page, not a properly formatted table of previous versions. 3. If I check the "Show confirmation/edit window before page is logged" option, Slogger would pop up a completely blank window each time a page is logged (auto or otherwise). 4. Clicking on the 'Test' button in those profiles with custom scripts does not do anything at all. Besides the above, I've found it totally confusing and almost impossible to change the data directory for Slogger without delving into prefs.js where the $sloggerDir variable seems to be hard-coded. I recall this was much more straightforward and easily done in the 0.5.x versions. I tried to fall back to the last 0.5.x version which is 0.5.1.2, but have found that it too exhibits some of the same bugs under Firefox 1.5.0.1. At the moment, I'm relying on the Firefox built in history but it's proving to be very inadequate. Can the developer please help? Thanks. Tom From kschutte at mit.edu Sat Feb 11 13:33:24 2006 From: kschutte at mit.edu (Ken Schutte) Date: Sat Feb 11 13:33:38 2006 Subject: [Slogger] Slogger 0.6.20060201 totally broken in Firefox 1.5.0.1 - Really need help. In-Reply-To: <20060211161543.F98A.TOMTHUMB@tom.com> References: <20060211161543.F98A.TOMTHUMB@tom.com> Message-ID: <43EE2DF4.7040606@mit.edu> Hi Tom, I tried to answer some of your questions below... In general, for things not to work on a completely fresh install with the default settings, I'm not sure what to tell you... except maybe how to make sure everything is really uninstalled: Search for a prefs.js file in your Firefox profile directory. With Firefox not running, and Slogger uninstalled, delete lines in prefs.js with "slogger.", then re-install slogger. You should get a message that Slogger was just installed, and it should hopefully work okay... tomthumb@tom.com wrote: > 1. With a fresh Slogger installation (all default settings) to a > brand-new Firefox profile, everytime I choose "View RDF-XUL log" from > the Slogger menu, I would get a "File not found". The default settings shouldn't have the RDF-XUL profile active for anything... This was just an idea I was playing with, and doesn't really work right. That "View RDF-XUL log" message shouldn't show up in the menu without having run it - I'm not sure how that would happen, I'll have to check that out... Did you select "Run -> (that profile)" from the menu? Maybe I should delete it all together... You can modify the menu by going to the URL "about:config" and modifying "slogger.customMenu". It's format is "label1|uri1|label2|uri2|..." > 2. As above, when I choose "View today's XML log file", I would get a > 'unformatted' bunch of entries on a white page, not a properly formatted > table of previous versions. hmm... Does it open the correct xml file? If you kept default settings - is there a "slogger.xsl" file in the same directory. > 3. If I check the "Show confirmation/edit window before page is logged" > option, Slogger would pop up a completely blank window each time a page > is logged (auto or otherwise). Did you select variables to edit on confirm? That's what should appear in this window - the idea is that you select what info you want to customize in the edit popup... With none selected, the window is blank, and you can just hit OK or Cancel to log or cancel log. I guess it should have some text message, like "Confirm: OK to log, Cancel to skip"... > > 4. Clicking on the 'Test' button in those profiles with custom scripts > does not do anything at all. I have not seen this problem... If something very simple like "alert('x');" doesn't do anything, maybe check Firefox "Tools->Javascript console" for error messages... ? > Besides the above, I've found it totally confusing and almost impossible > to change the data directory for Slogger without delving into prefs.js > where the $sloggerDir variable seems to be hard-coded. I recall this was > much more straightforward and easily done in the 0.5.x versions. The $sloggerDir is really just meant to be a shortcut to Slogger's extension directory (ie where the code is installed, etc), which is set by Firefox, and does not change. I use this as a default place to store things, because I figure is a fairly safe place to create dirs/write data, etc.. You don't have to use $sloggerDir if you want to store stuff elsewhere, but if you want to and want to change it, the way to do so is entering "about:config" as URL in Firefox, and editing "slogger.sloggerDir". (this is how you can modify prefs.js stuff safely) The main difference in direcories from previous versions is that the saved pages and log file can have different directories, so depending on your setup, you may have to make a change in two places. Ken From hvjunk at gmail.com Tue Feb 14 00:01:29 2006 From: hvjunk at gmail.com (Hendrik Visage) Date: Mon Feb 13 17:02:03 2006 Subject: [Slogger] Slogger buttons missing ??? Message-ID: Hi there, Gentoo, FFox 1.5.0.1 I don't seem to get the buttons in the customize toolbar settings :( -- Hendrik Visage From kschutte at mit.edu Mon Feb 13 17:07:58 2006 From: kschutte at mit.edu (Ken Schutte) Date: Mon Feb 13 17:08:30 2006 Subject: [Slogger] Slogger buttons missing ??? In-Reply-To: References: Message-ID: <43F1033E.5020903@mit.edu> That's weird... Are you sure Slogger installed without error? Check to see it's there and no problems in Tools->Extensions. Maybe you need a newer version to install on FF 1.5.0.1 Ken Hendrik Visage wrote: > Hi there, > > Gentoo, > FFox 1.5.0.1 > I don't seem to get the buttons in the customize toolbar settings :( > > > -- > Hendrik Visage > _______________________________________________ > Slogger mailing list > Slogger@mozdev.org > http://mozdev.org/mailman/listinfo/slogger From hvjunk at gmail.com Tue Feb 14 07:30:50 2006 From: hvjunk at gmail.com (Hendrik Visage) Date: Tue Feb 14 00:31:44 2006 Subject: [Slogger] Slogger buttons missing ??? In-Reply-To: <43F1033E.5020903@mit.edu> References: <43F1033E.5020903@mit.edu> Message-ID: On 2/14/06, Ken Schutte wrote: > That's weird... Are you sure Slogger installed without error? Check to > see it's there and no problems in Tools->Extensions. Maybe you need a > newer version to install on FF 1.5.0.1 I saw the saw type of problem with a FFox 1.5 :( So I tried in in the def (Old default) instance and it works like a charm... not my special instance thatwrites its data etc. in anotehr directory ie. $HOME/.surfstuff/ffox/... -- Hendrik Visage From mook at themook.net Thu Feb 16 14:39:01 2006 From: mook at themook.net (mook@themook.net) Date: Thu Feb 16 14:40:02 2006 Subject: [Slogger] Trouble With Variable "$url" Message-ID: <43F48E85.5583.D783B1@localhost> Hello! I am using Firefox 1.5.0.1 with Slogger version: "slogger-0.6.20060201.xpi" I can not seem to get the "$url" variable to function correctly for any pages I am attempting to download. Under "Slogger Settings", I choose the profile "XML Log & complete pages" and press "Edit Profile". On the "Save Pages" tab I have the "Folder" set to "G:\Slogger" and the "Filename for saved page" set to "$year-$day.$typeext". When I click the Slogger Button 1 (which is set to run the "XML Log & complete pages"), it correctly archives the page I'm viewing in the "G:\Slogger" directory as filename "2006-16.html" and directory "2006-16 files". However, if I change ONLY the "Filename for saved page" from "$year-$day.$typeext" to "$url.$typeext" ... nothing happens at all when I click the Slogger Button 1. Nothing saves at all. I'm hoping this is just some option I need to tick off or something equally quick : ) I have hundreds of pages saved from a much older version of Slogger (which no longer works with the current Firefox) in the "$url" format, I'm really hoping I can continue to keep all my archives in a similar format. Thanks! Mook http://www.themook.net From kschutte at mit.edu Thu Feb 16 15:08:34 2006 From: kschutte at mit.edu (Ken Schutte) Date: Thu Feb 16 15:08:52 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F48E85.5583.D783B1@localhost> References: <43F48E85.5583.D783B1@localhost> Message-ID: <43F4DBC2.4070006@mit.edu> Hi, I believe the problem is that it's generating invalid filenames. The $url variable holds the full url, which could be "http://www.asdf.com/adsf?a=1;b=2" or something. From saved pages in the past, what would the final filename be for something like this? Did it escape some characters or just remove them? Some of the old Slogger code used to have a copy of some of Mozilla's code for saving pages. In newer Slogger, some of these functions were implemented differently, but I can try to find this part that cleaned up the filename and put it back in there. In the meantime, it might be possible in the current version if you change $url variable in a custom javascript, although it's a bit complicated... somthing like: var a = sloggerGetVar("url"); // modify a, replacing bad chars sloggerSetVar("url",a); Ken mook@themook.net wrote: > Hello! > > I am using Firefox 1.5.0.1 with Slogger version: > > "slogger-0.6.20060201.xpi" > > I can not seem to get the "$url" variable to function correctly for > any pages I am attempting to download. > > Under "Slogger Settings", I choose the profile "XML Log & > complete pages" and press "Edit Profile". On the "Save Pages" > tab I have the "Folder" set to "G:\Slogger" and the "Filename for > saved page" set to "$year-$day.$typeext". When I click the > Slogger Button 1 (which is set to run the "XML Log & complete > pages"), it correctly archives the page I'm viewing in the > "G:\Slogger" directory as filename "2006-16.html" and directory > "2006-16 files". > > However, if I change ONLY the "Filename for saved page" from > "$year-$day.$typeext" to "$url.$typeext" ... nothing happens at > all when I click the Slogger Button 1. Nothing saves at all. > > I'm hoping this is just some option I need to tick off or something > equally quick : ) I have hundreds of pages saved from a much > older version of Slogger (which no longer works with the current > Firefox) in the "$url" format, I'm really hoping I can continue to > keep all my archives in a similar format. > > Thanks! > > Mook > http://www.themook.net > > _______________________________________________ > Slogger mailing list > Slogger@mozdev.org > http://mozdev.org/mailman/listinfo/slogger From mook at themook.net Thu Feb 16 15:22:16 2006 From: mook at themook.net (mook@themook.net) Date: Thu Feb 16 15:23:16 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F4DBC2.4070006@mit.edu> References: <43F48E85.5583.D783B1@localhost> Message-ID: <43F498A8.1816.FF1E0F@localhost> Hi Ken, Thanks for the quick turnaround : ) The pages I have archived in the past were saved along the lines of: Original Remote Site http://www.site.com/article.html?id=001 http://www.site.com/article.html?id=002 http://www.site.com/article.html?id=003 Local Files http _www.site.com_article.html id=001.html http _www.site.com_article.html id=002.html http _www.site.com_article.html id=003.html Local Directories http _www.site.com__article.html id=001_files http _www.site.com__article.html id=002_files http _www.site.com__article.html id=003_files It looks like "/" became "_", and "?" became " ", etc. I'm afraid I have no idea how to recreate that with a custom javascript though - I have just enough knowledge to break things, but not enough to actually be competent : D The part of the URL I'm really trying to retain is the "id=00X" part - without that I have no idea what the article actually is (I have a spreadsheet that lists the names of the articles and their corresponding numbers). If I archive only based on a time-date stamp, it leaves me no way of knowing which article a particular file refers to. Is there another variable I might be able to use for that? (I've tried "$filename" and "$path" with no luck). Thanks! Mook http://www.themook.net On 16 Feb 2006 at 15:08, Ken Schutte wrote: > Hi, > > I believe the problem is that it's generating invalid filenames. The > $url variable holds the full url, which could be > "http://www.asdf.com/adsf?a=1;b=2" or something. From saved pages in > the past, what would the final filename be for something like this? Did > it escape some characters or just remove them? > > Some of the old Slogger code used to have a copy of some of Mozilla's > code for saving pages. In newer Slogger, some of these functions were > implemented differently, but I can try to find this part that cleaned up > the filename and put it back in there. > > In the meantime, it might be possible in the current version if you > change $url variable in a custom javascript, although it's a bit > complicated... somthing like: > > var a = sloggerGetVar("url"); > // modify a, replacing bad chars > sloggerSetVar("url",a); > > Ken From kschutte at mit.edu Thu Feb 16 16:29:35 2006 From: kschutte at mit.edu (Ken Schutte) Date: Thu Feb 16 16:29:48 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F498A8.1816.FF1E0F@localhost> References: <43F48E85.5583.D783B1@localhost> <43F498A8.1816.FF1E0F@localhost> Message-ID: <43F4EEBF.3050401@mit.edu> For now, to at least get that information stored, you could make a log file that maps filename to the url. for example, set the saved page to be (like the default): $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext and create log file with the content of: $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext $url Or you can try entering something like this in the "Custom script" tab (I haven't tried this...), var a = sloggerGetVar("url"); alert(a); a.replace(/\:/g, "_"); a.replace(/\?/g, "_"); a.replace(/\//g, "_"); alert(a); sloggerSetVar("url",a); the alert() lines will let you know if it's running and if the character replacement works. Remove them if it does. Ken mook@themook.net wrote: > Hi Ken, > > Thanks for the quick turnaround : ) > > The pages I have archived in the past were saved along the > lines of: > > Original Remote Site > http://www.site.com/article.html?id=001 > http://www.site.com/article.html?id=002 > http://www.site.com/article.html?id=003 > > Local Files > http _www.site.com_article.html id=001.html > http _www.site.com_article.html id=002.html > http _www.site.com_article.html id=003.html > > Local Directories > http _www.site.com__article.html id=001_files > http _www.site.com__article.html id=002_files > http _www.site.com__article.html id=003_files > > It looks like "/" became "_", and "?" became " ", etc. I'm afraid I > have no idea how to recreate that with a custom javascript > though - I have just enough knowledge to break things, but not > enough to actually be competent : D > > The part of the URL I'm really trying to retain is the "id=00X" > part - without that I have no idea what the article actually is (I > have a spreadsheet that lists the names of the articles and their > corresponding numbers). If I archive only based on a time-date > stamp, it leaves me no way of knowing which article a particular > file refers to. Is there another variable I might be able to use for > that? (I've tried "$filename" and "$path" with no luck). > > Thanks! > > Mook > http://www.themook.net > > On 16 Feb 2006 at 15:08, Ken Schutte wrote: > >>Hi, >> >>I believe the problem is that it's generating invalid filenames. The >>$url variable holds the full url, which could be >>"http://www.asdf.com/adsf?a=1;b=2" or something. From saved pages in >>the past, what would the final filename be for something like this? Did >>it escape some characters or just remove them? >> >>Some of the old Slogger code used to have a copy of some of Mozilla's >>code for saving pages. In newer Slogger, some of these functions were >>implemented differently, but I can try to find this part that cleaned up >>the filename and put it back in there. >> >>In the meantime, it might be possible in the current version if you >>change $url variable in a custom javascript, although it's a bit >>complicated... somthing like: >> >>var a = sloggerGetVar("url"); >>// modify a, replacing bad chars >>sloggerSetVar("url",a); >> >>Ken > > > > _______________________________________________ > Slogger mailing list > Slogger@mozdev.org > http://mozdev.org/mailman/listinfo/slogger From mook at themook.net Thu Feb 16 19:44:56 2006 From: mook at themook.net (mook@themook.net) Date: Thu Feb 16 19:45:55 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F4EEBF.3050401@mit.edu> References: <43F498A8.1816.FF1E0F@localhost> Message-ID: <43F4D638.6306.1EF967B@localhost> Hi again! That javascript produced two identical alert boxes, both with the unmodified URL of the page I was on - I tinkered a little bit (I don't actually know javascript, but found some example scripts here and there) and came up with: var a = sloggerGetVar("url"); alert(a); a = a.replace(new RegExp(/:/), "_"); alert(a); sloggerSetVar("url",a); When I "test" this code (within Slogger's pane) it opens an alert box with the unmodified URL, then opens a second alert box with the ":" changed to a "_" ... the problem is, if I change the ":" in that code to a "?", no alert boxes show at all, it's as if the code doesn't fire. Maybe the question mark "?" is protected in javascript. Anyway, thanks a bunch for trying to help me with this, I'm going to keep tinkering and see if I can figure this out. Feel free to throw any bones my way if you think of anything else : D By the way, I never actually mentioned in any of my posts, it was somewhat implied - but I think Slogger is a fantastic extension. It saved me literally hours and hours of laborious fiddling by automating site captures so easily. Nice job! Mook http://www.themook.net On 16 Feb 2006 at 16:29, Ken Schutte wrote: > For now, to at least get that information stored, you could make a log > file that maps filename to the url. for example, set the saved page to > be (like the default): > $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext > and create log file with the content of: > $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext $url > > > Or you can try entering something like this in the "Custom script" tab > (I haven't tried this...), > > var a = sloggerGetVar("url"); > alert(a); > a.replace(/\:/g, "_"); > a.replace(/\?/g, "_"); > a.replace(/\//g, "_"); > alert(a); > sloggerSetVar("url",a); > > the alert() lines will let you know if it's running and if the character > replacement works. Remove them if it does. > > Ken > > > > mook@themook.net wrote: > > Hi Ken, > > > > Thanks for the quick turnaround : ) > > > > The pages I have archived in the past were saved along the > > lines of: > > > > Original Remote Site > > http://www.site.com/article.html?id=001 > > http://www.site.com/article.html?id=002 > > http://www.site.com/article.html?id=003 > > > > Local Files > > http _www.site.com_article.html id=001.html > > http _www.site.com_article.html id=002.html > > http _www.site.com_article.html id=003.html > > > > Local Directories > > http _www.site.com__article.html id=001_files > > http _www.site.com__article.html id=002_files > > http _www.site.com__article.html id=003_files > > > > It looks like "/" became "_", and "?" became " ", etc. I'm afraid I > > have no idea how to recreate that with a custom javascript > > though - I have just enough knowledge to break things, but not > > enough to actually be competent : D > > > > The part of the URL I'm really trying to retain is the "id=00X" > > part - without that I have no idea what the article actually is (I > > have a spreadsheet that lists the names of the articles and their > > corresponding numbers). If I archive only based on a time-date > > stamp, it leaves me no way of knowing which article a particular > > file refers to. Is there another variable I might be able to use for > > that? (I've tried "$filename" and "$path" with no luck). > > > > Thanks! > > > > Mook > > http://www.themook.net > > > > On 16 Feb 2006 at 15:08, Ken Schutte wrote: > > > >>Hi, > >> > >>I believe the problem is that it's generating invalid filenames. The > >>$url variable holds the full url, which could be > >>"http://www.asdf.com/adsf?a=1;b=2" or something. From saved pages in > >>the past, what would the final filename be for something like this? Did > >>it escape some characters or just remove them? > >> > >>Some of the old Slogger code used to have a copy of some of Mozilla's > >>code for saving pages. In newer Slogger, some of these functions were > >>implemented differently, but I can try to find this part that cleaned up > >>the filename and put it back in there. > >> > >>In the meantime, it might be possible in the current version if you > >>change $url variable in a custom javascript, although it's a bit > >>complicated... somthing like: > >> > >>var a = sloggerGetVar("url"); > >>// modify a, replacing bad chars > >>sloggerSetVar("url",a); > >> > >>Ken > > > > > > > > _______________________________________________ > > Slogger mailing list > > Slogger@mozdev.org > > http://mozdev.org/mailman/listinfo/slogger From mook at themook.net Thu Feb 16 20:26:51 2006 From: mook at themook.net (mook@themook.net) Date: Thu Feb 16 20:27:52 2006 Subject: [Slogger] Trouble With Variable "$url" Message-ID: <43F4E00B.3590.215F750@localhost> Hmm, okay - I feel like I'm so close, but now I'm having a new problem. I did get some javascript that did exactly what I was trying to do, from your original suggestion: var a = sloggerGetVar("url"); alert(a); a = a.replace(new RegExp(/\//gi), "_"); a = a.replace(new RegExp(/:/gi), "_"); a = a.replace(new RegExp(/\?/gi), "_"); alert(a); sloggerSetVar("url",a); When I test this script with the Slogger "test" button (on the "Custom Script" tab), it works perfectly - the first alert box shows: http://www.site.com/article.html?id=001 In the second alert box, this becomes: http___www.site.com_article.html_id=001 Perfect! I was excited at this point : ) However, when I actually run the profile after clicking "OK" on the "Custom Script" tab, it doesn't archive the page - it generates an error box saying: "Error running your custom script. Check the javascrip console" The error message in the javascript console is: Error: uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsILocalFile.initWithPath]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: chrome://slogger/content/slogger.js :: sloggerExecProfile :: line 627" data: no] Also, when I go back to the "Custom Script" tab, my code has been changed! It no longer contains the escaping slashes, for example: a = a.replace(new RegExp(/\//gi), "_"); ... is now ... a = a.replace(new RegExp(///gi), "_"); So close, yes? Maybe just a little tweak? : ) Mook http://www.themook.net On 16 Feb 2006 at 19:44, slogger@mozdev.org wrote: > Hi again! > > That javascript produced two identical alert boxes, both with the > unmodified URL of the page I was on - I tinkered a little bit (I > don't actually know javascript, but found some example scripts > here and there) and came up with: > > var a = sloggerGetVar("url"); > alert(a); > a = a.replace(new RegExp(/:/), "_"); > alert(a); > sloggerSetVar("url",a); > > When I "test" this code (within Slogger's pane) it opens an alert > box with the unmodified URL, then opens a second alert box > with the ":" changed to a "_" ... the problem is, if I change the ":" > in that code to a "?", no alert boxes show at all, it's as if the code > doesn't fire. Maybe the question mark "?" is protected in > javascript. > > Anyway, thanks a bunch for trying to help me with this, I'm going > to keep tinkering and see if I can figure this out. Feel free to > throw any bones my way if you think of anything else : D > > By the way, I never actually mentioned in any of my posts, it > was somewhat implied - but I think Slogger is a fantastic > extension. It saved me literally hours and hours of laborious > fiddling by automating site captures so easily. Nice job! > > Mook > http://www.themook.net > > > > On 16 Feb 2006 at 16:29, Ken Schutte wrote: > > For now, to at least get that information stored, you could make a log > > file that maps filename to the url. for example, set the saved page to > > be (like the default): > > $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext > > and create log file with the content of: > > $year-$month-$day_$hour-$minute-$second-$millisecond.$typeext $url > > > > > > Or you can try entering something like this in the "Custom script" tab > > (I haven't tried this...), > > > > var a = sloggerGetVar("url"); > > alert(a); > > a.replace(/\:/g, "_"); > > a.replace(/\?/g, "_"); > > a.replace(/\//g, "_"); > > alert(a); > > sloggerSetVar("url",a); > > > > the alert() lines will let you know if it's running and if the character > > replacement works. Remove them if it does. > > > > Ken > > > > > > > > mook@themook.net wrote: > > > Hi Ken, > > > > > > Thanks for the quick turnaround : ) > > > > > > The pages I have archived in the past were saved along the > > > lines of: > > > > > > Original Remote Site > > > http://www.site.com/article.html?id=001 > > > http://www.site.com/article.html?id=002 > > > http://www.site.com/article.html?id=003 > > > > > > Local Files > > > http _www.site.com_article.html id=001.html > > > http _www.site.com_article.html id=002.html > > > http _www.site.com_article.html id=003.html > > > > > > Local Directories > > > http _www.site.com__article.html id=001_files > > > http _www.site.com__article.html id=002_files > > > http _www.site.com__article.html id=003_files > > > > > > It looks like "/" became "_", and "?" became " ", etc. I'm afraid I > > > have no idea how to recreate that with a custom javascript > > > though - I have just enough knowledge to break things, but not > > > enough to actually be competent : D > > > > > > The part of the URL I'm really trying to retain is the "id=00X" > > > part - without that I have no idea what the article actually is (I > > > have a spreadsheet that lists the names of the articles and their > > > corresponding numbers). If I archive only based on a time-date > > > stamp, it leaves me no way of knowing which article a particular > > > file refers to. Is there another variable I might be able to use for > > > that? (I've tried "$filename" and "$path" with no luck). > > > > > > Thanks! > > > > > > Mook > > > http://www.themook.net > > > > > > On 16 Feb 2006 at 15:08, Ken Schutte wrote: > > > > > >>Hi, > > >> > > >>I believe the problem is that it's generating invalid filenames. The > > >>$url variable holds the full url, which could be > > >>"http://www.asdf.com/adsf?a=1;b=2" or something. From saved pages in > > >>the past, what would the final filename be for something like this? Did > > >>it escape some characters or just remove them? > > >> > > >>Some of the old Slogger code used to have a copy of some of Mozilla's > > >>code for saving pages. In newer Slogger, some of these functions were > > >>implemented differently, but I can try to find this part that cleaned up > > >>the filename and put it back in there. > > >> > > >>In the meantime, it might be possible in the current version if you > > >>change $url variable in a custom javascript, although it's a bit > > >>complicated... somthing like: > > >> > > >>var a = sloggerGetVar("url"); > > >>// modify a, replacing bad chars > > >>sloggerSetVar("url",a); > > >> > > >>Ken > > > > > > > > > > > > _______________________________________________ > > > Slogger mailing list > > > Slogger@mozdev.org > > > http://mozdev.org/mailman/listinfo/slogger > > From kschutte at mit.edu Thu Feb 16 21:36:59 2006 From: kschutte at mit.edu (Ken Schutte) Date: Thu Feb 16 21:37:34 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F4E00B.3590.215F750@localhost> References: <43F4E00B.3590.215F750@localhost> Message-ID: <43F536CB.8030304@mit.edu> mook@themook.net wrote: > > Also, when I go back to the "Custom Script" tab, my code has > been changed! It no longer contains the escaping slashes, for > example: > > a = a.replace(new RegExp(/\//gi), "_"); > > ... is now ... > > a = a.replace(new RegExp(///gi), "_"); > Ahh, yeah you picked up on a couple mistakes, the "a.replace()" returns the new string, instead of modifying "a". The other problem is with escaping special characters, and is pretty confusing. Put this as the script: var a = sloggerGetVar("url"); a = a.replace(/\\\:/g, "_"); a = a.replace(/\\\?/g, "_"); a = a.replace(/\\\//g, "_"); sloggerSetVar("url",a); This should work, ... BUT if you ever modify that profile again (i.e. Edit Profile and hit OK), it you'll notice the extra pair "\\" missing in each line, and you'd have to add them back again. Yeah, this is a delicate hack, but should work for now... Ken From mook at themook.net Thu Feb 16 21:56:49 2006 From: mook at themook.net (mook@themook.net) Date: Thu Feb 16 21:57:54 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F536CB.8030304@mit.edu> References: <43F4E00B.3590.215F750@localhost> Message-ID: <43F4F521.30794.2685520@localhost> Unfortunately I'm not sure this is workaround-able...I put in the code you posted, hit "OK", hit the Slogger Button 1 (which is set to run this profile) ... and nothing saved. I went back to the profile, checked the 'Custom Script' tab, and as you said the code had removed the doubleslashes - so I recopied and repasted your code, and added an 'alert(a);' line so I could test the code. When I clicked 'Test' the alert box appeared, AND the URL looked perfect - no "?", no ":", and no "/". So, it seems to work when testing from the Custom Scripts tab - but when actually archiving a page, it still doesn't fire, no joy. Mook http://www.themook.net On 16 Feb 2006 at 21:36, Ken Schutte wrote: > Ahh, yeah you picked up on a couple mistakes, the "a.replace()" returns > the new string, instead of modifying "a". The other problem is with > escaping special characters, and is pretty confusing. Put this as the > script: > > var a = sloggerGetVar("url"); > a = a.replace(/\\\:/g, "_"); > a = a.replace(/\\\?/g, "_"); > a = a.replace(/\\\//g, "_"); > sloggerSetVar("url",a); > > This should work, ... BUT if you ever modify that profile again (i.e. > Edit Profile and hit OK), it you'll notice the extra pair "\\" missing > in each line, and you'd have to add them back again. Yeah, this is a > delicate hack, but should work for now... > > Ken From tomthumb at tom.com Sat Feb 18 01:02:38 2006 From: tomthumb at tom.com (tomthumb@tom.com) Date: Fri Feb 17 12:03:19 2006 Subject: [Slogger] Slogger 0.6.20060201 totally broken in Firefox 1.5.0.1 - Really need help. In-Reply-To: <43EE2DF4.7040606@mit.edu> References: <20060211161543.F98A.TOMTHUMB@tom.com> <43EE2DF4.7040606@mit.edu> Message-ID: <20060218010221.BFA1.TOMTHUMB@tom.com> Dear Ken, > Hi Tom, > > I tried to answer some of your questions below... Thanks for the speedy reply. I was going to send off a followup when a tip on Mozillazine caught my eye and gave me reason to investigate further on my end. To summarise, I must apologise for assuming that the 'bugs' I encountered were caused by Slogger whereas in fact they were caused by the Firefox build I had upgraded to. It now appears (after many rounds of exhaustive testing with more than a handful of different builds) that the particular build I was using did not render .xml files properly. Nothing wrong with Slogger in this aspect at all. However, I'm seeing another 'bug' which is that Firefox tells me that the .xml log file is "corrupt" and would not display it if there are 'foreign language' characters in it. For example, if I visit some Japanese or Chinese sites and Slogger logs them in the .xml file, Firefox refuses to read the file. Can you please advise? Thanks. Tom -- tomthumb@tom.com From kschutte at mit.edu Fri Feb 17 15:14:24 2006 From: kschutte at mit.edu (Ken Schutte) Date: Fri Feb 17 15:14:38 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F4F521.30794.2685520@localhost> References: <43F4E00B.3590.215F750@localhost> <43F4F521.30794.2685520@localhost> Message-ID: <43F62EA0.8090607@mit.edu> Hmm... I just tried it and it works for me. I'm using a little bit newer version, which had some slight changes in when the javascript is executed. The last thing I could suggest is to try this one http://www.kenschutte.com/download/slogger/xpi/slogger-0.6.20060216.xpi (and have "start of log process" checked in custom script tab - it's a new option) (keep in mind the warning on my website about upgrades...) Ken mook@themook.net wrote: > Unfortunately I'm not sure this is workaround-able...I put in the > code you posted, hit "OK", hit the Slogger Button 1 (which is set > to run this profile) ... and nothing saved. > > I went back to the profile, checked the 'Custom Script' tab, and > as you said the code had removed the doubleslashes - so I > recopied and repasted your code, and added an 'alert(a);' line so > I could test the code. When I clicked 'Test' the alert box > appeared, AND the URL looked perfect - no "?", no ":", and no > "/". > > So, it seems to work when testing from the Custom Scripts tab - > but when actually archiving a page, it still doesn't fire, no joy. > > Mook > http://www.themook.net > > On 16 Feb 2006 at 21:36, Ken Schutte wrote: > >>Ahh, yeah you picked up on a couple mistakes, the "a.replace()" returns >>the new string, instead of modifying "a". The other problem is with >>escaping special characters, and is pretty confusing. Put this as the >>script: >> >>var a = sloggerGetVar("url"); >>a = a.replace(/\\\:/g, "_"); >>a = a.replace(/\\\?/g, "_"); >>a = a.replace(/\\\//g, "_"); >>sloggerSetVar("url",a); >> >>This should work, ... BUT if you ever modify that profile again (i.e. >>Edit Profile and hit OK), it you'll notice the extra pair "\\" missing >>in each line, and you'd have to add them back again. Yeah, this is a >>delicate hack, but should work for now... >> >>Ken > > > > > _______________________________________________ > Slogger mailing list > Slogger@mozdev.org > http://mozdev.org/mailman/listinfo/slogger From mook at themook.net Fri Feb 17 19:53:37 2006 From: mook at themook.net (mook@themook.net) Date: Fri Feb 17 19:54:37 2006 Subject: [Slogger] Trouble With Variable "$url" In-Reply-To: <43F62EA0.8090607@mit.edu> References: <43F4F521.30794.2685520@localhost> Message-ID: <43F629C1.26848.71DE640@localhost> Awesome awesome awesome! I upgraded to the newest build, cut and paste your javascript, and bingo - happyhappy joyjoy! Thanks a million for working this out, saved me a LOT of time. Mook http://www.themook.net On 17 Feb 2006 at 15:14, Ken Schutte wrote: > Hmm... I just tried it and it works for me. > > I'm using a little bit newer version, which had some slight changes in > when the javascript is executed. The last thing I could suggest is to > try this one > http://www.kenschutte.com/download/slogger/xpi/slogger-0.6.20060216.xpi > (and have "start of log process" checked in custom script tab - it's a > new option) > > (keep in mind the warning on my website about upgrades...) > > Ken > > > mook@themook.net wrote: > > Unfortunately I'm not sure this is workaround-able...I put in the > > code you posted, hit "OK", hit the Slogger Button 1 (which is set > > to run this profile) ... and nothing saved. > > > > I went back to the profile, checked the 'Custom Script' tab, and > > as you said the code had removed the doubleslashes - so I > > recopied and repasted your code, and added an 'alert(a);' line so > > I could test the code. When I clicked 'Test' the alert box > > appeared, AND the URL looked perfect - no "?", no ":", and no > > "/". > > > > So, it seems to work when testing from the Custom Scripts tab - > > but when actually archiving a page, it still doesn't fire, no joy. > > > > Mook > > http://www.themook.net From heshammarei at yahoo.com Mon Feb 20 06:49:44 2006 From: heshammarei at yahoo.com (hesham marei) Date: Mon Feb 20 09:50:44 2006 Subject: [Slogger] How can I delete my logfile entries from the menu Message-ID: <20060220144944.44479.qmail@web54313.mail.yahoo.com> Hi I have created a lot of profiles in the last few days. Then I have noticed that everytime I add a new profile, the logfile name is also added to my slogger menu. I have now more than 15 logfile names in my menu. How can I delete them from the menu? I have tried uninstall several times but did not solve th e problem. I deleted {EE.....} file but nothing happened. I am using firefox 1.5.0.1 and linux SuSE 10. any suggestion will be appreciated. Regards Hesham Marei __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com From heshammarei at yahoo.com Mon Feb 20 06:54:01 2006 From: heshammarei at yahoo.com (hesham marei) Date: Mon Feb 20 09:54:59 2006 Subject: [Slogger] How can I clone the click toggle file? Message-ID: <20060220145401.46158.qmail@web54313.mail.yahoo.com> Hi I have more than 8 profile. and there is only 6 toggle file that help me to save my pages "HTML personal profile". Each time i would like to save a page I click on the black toggle file (e.g. toggle file 1 for first profile, toggle file 2 for the second profile, etc.). as i said i have more than 8 different profile and would like to clone or copy the buttons in order to use it with the rest of my profile. Regards Hesham Marei __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com From kschutte at csail.mit.edu Mon Feb 20 17:52:08 2006 From: kschutte at csail.mit.edu (Ken Schutte) Date: Mon Feb 20 17:52:23 2006 Subject: [Slogger] How can I delete my logfile entries from the menu In-Reply-To: <20060220144944.44479.qmail@web54313.mail.yahoo.com> References: <20060220144944.44479.qmail@web54313.mail.yahoo.com> Message-ID: <43FA4818.6090908@csail.mit.edu> hesham marei wrote: > I have created a lot of profiles in the last few days. > Then I have noticed that everytime I add a new > profile, the logfile name is also added to my slogger > menu. I have now more than 15 logfile names in my > menu. > How can I delete them from the menu? Yes, this is a kind of annoying "feature". Enter "about:config" in the URL bar of Firefox. Find and edit the edit for "slogger.customMenu". It controls what's in that menu. The format is just, label1|url1|label2|url2|... As far as your other question in another email to the list, I'm not sure what you mean. Ken From swisses at gmail.com Thu Feb 23 10:41:58 2006 From: swisses at gmail.com (swisses) Date: Wed Feb 22 23:42:25 2006 Subject: [Slogger] non ascii characters in Slogger logs Message-ID: <43FD3D16.2040104@gmail.com> Hello, Here is temporary solution for title problem in log files in sloggerPrefs.js: -------------------------------- //........................ function sloggerSetVar() { //........................ else { if (val == undefined) { val = ""; } //+++++start if (name == "title") { val = encodeURIComponent(val); } //+++++end var cmd = "prefs.set" + vartype + "Pref(name, val)"; eval(cmd); } } } //........................ function sloggerGetVar(name) { //........................ eval(cmd); //+++++start if(name == "title") { val = decodeURIComponent(val); } //+++++end return val; } -------------------------------- You have to modify log file header encoding to UTF-8: Regards, Dmitry -------------- next part -------------- A non-text attachment was scrubbed... Name: unicode.gif Type: image/gif Size: 7753 bytes Desc: not available Url : http://mozdev.org/pipermail/slogger/attachments/20060223/000c2ce0/unicode.gif