6 ms·
Save Time On Hacker News: Mark All Read
- turshija 14y agoGreat addition, but not compatible with this: https://chrome.google.com/webstore/detail/lgoghlndihpmbbgmbpjohilcphbfhddd https://chrome.google.com/webstore/detail/lgoghlndihpmbbgmbp... Probably because of infinite scroll, I have to scroll down a little bit to load few pages, then select hide read ...
- danmaz74 14y agoI just tried and it works (even if not perfectly, as the colors aren't the same). What is your problem exactly? Did you try the button at the top of the page instead of the one at the bottom?
- jwallaceparker 14y agoLooks cool. It would be great if you could differentiate between the items you've actually visited and those you've "marked as read."
- danmaz74 14y agoI tried to do that with CSS :visited selector, but without success at first - I'll try again as soon as I'll have time!
- angry-hacker 14y agoModern browser won't let you change :visited selector except color... because of security. A random webpage would have the knowledge of pages you have visited then :) I think IE7 and below have that bug. And you can't check the color of a visited link with javascript. You were able to build a list of controversial webpages (to compare them with my browser history), put to your css file that a:visited color: red; (just an example) and check with javascript which links have foreground color red - and voilaa. You know what pages I have in my history. You need to save data to localstorage or something like that instead. And you can only save those clicks which are made from hackernews site... not populate it from browser history.
- danmaz74 14y agoI'll have to try with just css then. I can't keep track of all clicks :)
- angry-hacker 14y agoBut you can't identify which links are visited... because of security issues I described. Sorry my english is horrible maybe I described it very in a very bad way. https://bugzilla.mozilla.org/show_bug.cgi?id=147777 https://bugzilla.mozilla.org/show_bug.cgi?id=147777 It is fixed in modern browsers now...
- danmaz74 14y agoYou can't with javascript, but the a:visited selector works in pure CSS, doesn't it? I'd like to do it so that I don't know which links you actually visited, but you would see them in a different color anyway. I think this should work somehow, I'll have to make some more tests.
- angry-hacker 14y agoYou can only change the color, nothing else... :)
- danmaz74 14y agoAnd that's all I need ;)
- jwr 14y agoCool. I expect kill-files will come afterwards. Several more extensions and hacks like that and we will have built a poor-man's USENET in the browser.
- deleted 14y ago[deleted]
- unimpressive 14y agoWell the original USENET was killed by it's lack of web features. And file sharers, and spammers...
- blahedo 14y ago...just like we've built a poor-man's everything else in the browser. I cringe every time I visit a website with YA (broken) reinvention of YA GUI widget that has been polished and clean on desktop GUIs for two decades. (I cringe a lot.)
- angry-hacker 14y agoGreat addition, but why not write it as a userscript instead of Chrome plugin? Chrome, Opera support them natively. You can install it just like an extension. Firefox needs Greasemonkey to be installed but most power users have it anyway. Not sure about IE and Safari but problably they can support userscripts in some way also.
- danmaz74 14y agoThis was just an experiment, and the extension looked like the easiest way to do it (I use chrome 90% of the time). But I was thinking about publishing the source to github; the js is very simple, if anybody wants to fork it for other browsers is welcome :) By the way, can you use css files with userscripts?
- angry-hacker 14y agoYou can but they need to be hosted somewhere or you need to create a link tag with javascript and add it dynamically... Something like that: var css = document.createElement('link'); css.textContent = 'css here'; document.head.appendChild(css);
- dnewcome 14y agoI wrote something like this as a user script that works in FF(w/Greasemonkey)/Chrome/Opera a while ago [1]. The idea is to remove individual stories or add filters rather than removing everything like the OP. My script is based on VI-style shortcut keys though so that may influence how useful you find it. [1] https://github.com/dnewcome/hn-plonk https://github.com/dnewcome/hn-plonk
- Brajeshwar 14y agoCool. Something I asked long time back. Thanks.
- sidwyn 14y agoWorks great, but how do I undo?
- danmaz74 14y agoRight now you can't... what is your use case? Was it just because you were testing, or you would really need an undo?
- smectos 14y agoSomeone should consider implementing this functionality into the site.
- realrocker 14y agoshouldn't it toggle read/unread?
- maybird 14y agoThis Firefox extension does it: https://addons.mozilla.org/en-US/firefox/addon/link-visitor-3/ https://addons.mozilla.org/en-US/firefox/addon/link-visitor-...
- realrocker 14y agothanks. i haven't used firefox for 3 years though.
- alain94040 14y agoI wish that when I read a large discussion (100+ comments) there would be a way to distinguish comments I have already seen. Because for a large discussion I care about, I'll revisit it several times to see what was added. Except right now, I have to rescan everythng. When I was using micromobs.com for discussion groups, they had a very simple and elegant system: keep all comments in place to preserve context, but grey out the ones I have already seen. The problem on HN is that it would conflict with bad comments. Maybe use a different color?
- danmaz74 14y agoFor that I use this very nice extension: https://chrome.google.com/webstore/detail/fpndmkcfggkffpablcooicmihgcgalil https://chrome.google.com/webstore/detail/fpndmkcfggkffpablc...
- icebraining 14y agoI use the HNHalfLife[1] userscript, and I know find it extremely annoying to browse HN without it. Thanks polyfractal! [1]: https://github.com/polyfractal/HNHalfLife https://github.com/polyfractal/HNHalfLife
- nuttendorfer 14y agoI've just installed it (Chrome) but it doesn't seem to do anything, would you happen to know what I'm doing wrong? Edit: Using the https version of news.ycombinator.com
- icebraining 14y agoI don't know, it "just worked" here. Click on comments page, close it and then it'll mark new comments when you return to it or see it on the stories list.
- mgurlitz 14y agoThe hckrnews.com browser extension does this with an orange bar on the left of new comments, and on the hckrnews.com homepage it will list how many new comments have been added to the story alongside the total count.
- jawns 14y agoI made a similar Greasemonkey user script a while back, and it's been great: http://coding.pressbin.com/74/Update-on-Greasemonkey-script-for-Hacker-News-homepage http://coding.pressbin.com/74/Update-on-Greasemonkey-script-...
- danmaz74 14y agoCool - so for FF there is already a solution :)
- sentenza 14y agoI wish there was more than one rss feed. What I really want to appear in my rss reader are the highest rated stories, not all of them. As it is, using the rss feed is actually more inefficient than visiting the page every now and then.
- bazzargh 14y agoThere's an account on twitter called @hackernewsbot that tweets the highest rated stories. Twitter accounts have RSS feeds, which are a bit awkward to find, but it's been automated, just type the username in here: http://charlieharvey.org.uk/page/twitter_rss http://charlieharvey.org.uk/page/twitter_rss Which gives: https://api.twitter.com/1/statuses/user_timeline.rss?screen_name=hackernewsbot&fetch=+Fetch+RSS+ https://api.twitter.com/1/statuses/user_timeline.rss?screen_... Hopefully this gives what you were after?
- bazzargh 14y agoHmm, I did that without looking and it seems the RSS urls aren't complicated any more. They used to need your uid not your screen name, which is why that tool exists.
- hackerpolicy 14y agoPerhaps http://feedhint.com/ http://feedhint.com/
- lini 14y agoCool, but not really compatible with HTTPS Everywhere :( Have to browse HN on HTTP to see the extension in action.
- xbryanx 14y agoTried to install. Got an error. "Manifest file is invalid."
- danmaz74 14y agoSorry, it was probably while I was uploading a fixed version for https. Try again and let me know. PS: it's really odd though, when I uploaded the new version it gave me an error and I didn't get to save the changes. I didn't expect the broken manifest to be live!
- xbryanx 14y agoWorked now. Thanks!
- branola 14y agoLove it! . . . But . . . I have Chrome set to delete all cookies whenever I close my browser and to save session cookies otherwise. So this extension works as long as the browser hasn't been closed once. But after the browser is closed and cookies deleted, the extension forgets what has been read when HN is reopened.
- danmaz74 14y agoActually it uses html5 localstorage, but if you delete that too, the list gets reset...
- dewiz 14y agothis is extremely useful and it is one more reason why I really miss Chrome (and Firefox) on both tablets and smartphone. I read HN mostly on these devices where HN UX is really poor, this is one of those features I would love. Another one is having bigger upvotes buttons and easier clickable links. Too often I have a hard time to click on the microscopic comments link, other times I open the wrong news or upvote the wrong one.
- renata 14y agoI find http://ihackernews.com/ http://ihackernews.com/ to be pretty useful for small-screen devices.
- readme 14y agoDefinitely a cool idea but it needs some work. * Upon installing the plugin, I tried to "hide read" thinking it would hide the posts that I had already viewed, but they were not hidden. It should be possible to hide these with a css selector. * After installing and clicking a post to read it, then clicking hide read, this post was not hidden (must not be considered read, again, css selector) Finally I have a feature request: I would like a "mark read" link to appear next to each link, so that I can mark an individual link read without reading it. Great idea and I hope that my feedback can help you to improve the app. Thanks.
- danmaz74 14y agoThanks for the feedback. It could be possible to mark individual items read, but hiding the ones you actually clicked on (without marking them read) is unfortunately impossible: As pointed out somewhere else in the comments, with javascript you can't read the "visited" selector, and with only css I could perhaps hide just the visited link, but not the encasing and trailing TR.
- readme 14y agoI figured out another way you can hide links as they are clicked. With jQuery override the .click() event of every link on the page. Then, when the link is clicked get the URL of the link from the event parameter that is passed to .click(). From that information, you can construct a CSS selector like this one (with jQuery) $("a[href=\"http://stackoverflow.com/questions/10668292/is-there-a-setting-on-google-analytics-to-suppress-use-of-cookies-for-users-who\] http://stackoverflow.com/questions/10668292/is-there-a-setti...) Which can then be used to hide the clicked link. The problem now is one of persisting the data between sessions. Your options are localStorage, remote storage, and my suggestion: sqlite in webkit a'la: http://stackoverflow.com/questions/6200976/sqlite-in-chrome http://stackoverflow.com/questions/6200976/sqlite-in-chrome After you have saved the "read" urls in SQLite, you should be able to hide the surrounding data as well in the other <tr> tag by traversing the DOM with jquery. I really would love if you did this. Please consider giving it a try.
- 14y ago
- pm90 14y agoI read hacker news from thunderbird via RSS. This problem doesn't exist for me :)