An annoying thing that happens when upvoting a post here in the forums.

18 respuestas [Último envío]
pogiako12345
Desconectado/a
se unió: 07/11/2014

You know when you upvote a post here in the forums, you are being navigated to the top? It's annoying isn't it? I honestly think it should be like reddit, wherein when you upvote, it does not bring you to the top or the start of a thread. Please do something about it? The same should go for downvote. Thanks!

pogiako12345
Desconectado/a
se unió: 07/11/2014

Please don't hate me, I'm just being honest. :D I'm not angry towards the Trisquel devs lol.

Jabjabs
Desconectado/a
se unió: 07/05/2014

There has been a bit of dislike about the whole voting system in general but that is more about the concept rather than the technology. About the only reason I can think that it working the way that it does is due to a reduced need on browser based scripting. Every time you do a vote it will reload the entire page, not ideal but it works.

lloydsmart

I am a member!

Desconectado/a
se unió: 12/22/2012

There's nothing wrong with browser-based scripting if the software is free. If the appropriate tags can be added to allow LibreJS compatibility, then I agree that this should be switched to Javascript.

tomlukeywood
Desconectado/a
se unió: 12/05/2014

i disagree even if the software is libre
its run normally without the users permission
automatically while it would be miles
better to have libre automatic js
its still better for any program
to only be run with the users permission

people should always be-able to use
a website without java-script

Jabjabs
Desconectado/a
se unió: 07/05/2014

I have no major issues with Java script but it is a case of - if a simple task like an up vote can be done server side then it might as well be done like that. It is not a case of freedom here just a case of simplifying the technology.

tomlukeywood
Desconectado/a
se unió: 12/05/2014

i have no problem with javascript i just have a problem
when a program is run without the users permission

onpon4
Desconectado/a
se unió: 05/30/2012

I like that it works without JavaScript. Reddit, I can't stand, because nothing there works without gratuitous JavaScript. It's not as bad as Diaspora, but still.

The only way I am going to accept JavaScript-based extensions that aren't being sent from a machine I have control over is if a libre browser exists which allows the user to specify exactly what scripts to install, and installs those scripts permanently. See my essay for more information (I updated it recently):

https://onpon4.github.io/other/kill-js/

ssdclickofdeath
Desconectado/a
se unió: 05/18/2013

I right-click-->Open link in new tab on the upvote/downvote button, then close the new tab after it loads. It's not ideal, but it works.

Magic Banana

I am a member!

I am a translator!

Desconectado/a
se unió: 07/24/2010

I right-click-->Open link in new tab

A middle click does that.

ssdclickofdeath
Desconectado/a
se unió: 05/18/2013

I sometimes press my laptop mouse buttons at slightly different times, so it registers as a left click (opening in the same window instead of a new one,) so I gave that sequence out of habit. Yes, that works too, though more reliably with a real mouse.

lembas
Desconectado/a
se unió: 05/13/2010

I find it MUCH easier to use the corner of the touchpad as middle button rather than the simultaneous buttons click. And I agree real mice for the win. (Except when table top space is very limited or when it's important to be as silent as possible...)

ssdclickofdeath
Desconectado/a
se unió: 05/18/2013

How can that be set?

lembas
Desconectado/a
se unió: 05/13/2010

This should make the right top corner of your touchpad act as middle mouse button

synclient RTCornerButton=2
pogiako12345
Desconectado/a
se unió: 07/11/2014

Holy shit! This actually works! Haha! I'll be using Ctrl + left click more often.

buildcomplete
Desconectado/a
se unió: 01/26/2015

This is possible without javascript.
each post could have a bookmark and the up/downvote could redirect to that after reloading the page.

edit: (I can see the already do have a bookamr, so it should be rather simple :) )

lembas
Desconectado/a
se unió: 05/13/2010

> bookmark

HTML anchor

buildcomplete
Desconectado/a
se unió: 01/26/2015

true, anchor is the name :)

Mampir
Desconectado/a
se unió: 12/16/2009

The vote buttons can be easily made to work both with and without JavaScript.

Here's a trivial program which should do this, although it appears there are other scripts which get in the way right now:

function initVoteButtons() {
    var rateButtons = document.querySelectorAll('a.rate-button');

    function sendVote(event) {
        event.preventDefault();
        var xhr = new XMLHttpRequest();
        xhr.open('HEAD', this.href);
        xhr.send();
    }

    for (var i = 0; i < rateButtons.length; ++i) {
        rateButtons[i].addEventListener('click', sendVote, false);
    }
}

window.addEventListener('load', initVoteButtons, false);