Page 1 of 1

Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 3:52 am
by FalconFour
See here:

viewtopic.php?f=30&t=22752

Any time "voltage" is mentioned... or volts...

Even the word "optimally"... or "optimal"...

Like, uh... you know, I think there's a syntax or format for making your word filter only operate on full words, isn't there?

Re: Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 7:47 am
by GerryAZ
If there is a personal preference setting on the forum to fix this, I hope someone provides directions. I have looked for setting changes to fix this without success.

Gerry

Re: Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 8:24 am
by gshepherd
Perhaps just turn the link-o-matic feature off altogether. It is more distracting than helpful.

Re: Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 8:31 am
by jlv
When I tried to use a T8 driver to loosen the bolt I found it stupidly added links, but then I tried to talk about the Bolt, well in that case it didn't linkify. I tried to focus on why, but before I could blink, I found out why. If you blink you might miss out on the spaces. It's all about spaces.

The offending code is found in http://www.myelectriccarforums.com/toolbar/toolbar2015.php and contains JavaScript that is executed in your browser after the page loads. That's just evil.

Code: Select all

   function tryHighlight(node)
   {
            if (/(My Electric Car Forums)|(Nissan Leaf)|(LEAF)|(Toyota Rav4 EV)|(Rav4EV)|(Rav4 EV)|(Ford C-max Energi)|(C-Max Energi)|(CMax Energi)|(Ford Fusion Energi)|(Fusion Energi)|(Cadillac ELR)|(ELR )|(Chevy Spark EV)|(Spark EV)|(Ford Focus Electric)|(Focus Electric)|(Focus EV)|(Honda Fit EV)|(Fit EV)|(Mitsubishi i-MiEV)|(Mitsubishi iMiev)|(i-MiEV)|(iMiev)|(Mitsubishi Outlander PHEV)|(Outlander PHEV)|(PHEV Outlander)|(Accord Plug-in)|(Accord PHEV)|(Infiniti LE)|(BMW i3)|(i3)|(BMW i8)|(i8)|(Fiat 500e)|(Fiat EV)|(500e)|(Smart ForTwo Electric Drive)|(Smart ForTwo Electric)|(Smart ForTwo ED)|(Smart ED)|(Smart Electric)|(Smart EV)|(Audi A3 E-tron)|(A3 E-tron)|(e-tron)|(EV Motorsports)|(EV motorsport)|(e-Golf)|(eGolf)|(Golf Electric)|(Golf EV)|(Golf Plug-in Hybrid)|(Golf GTE)|( eUp)|( e-Up)|(Kia Soul EV)|(Soul EV)|(Soul)|(e-NV200)|(e NV200)|(Porsche Panamera S e-Hybrid)|(Porsche Panamera)|(Panamera)|(Porsche)|(e-Hybrid)|(Cayenne)|(Macan)|(B-Class ED)|(B-Class Electric Drive)|(B-Class EV)|(B-Class)|(B250e)|(Mercedes-Benz)|(Mercedes)|(c350)|(c-350)|(c550)|(c500)|(Toyota Mirai)|(Mirai)|(Toyota FCV)|(Toyota FCEV)|(Toyota Fuel-Cell)|(Passat GTE)|(Passat PHEV)|(Chevrolet Bolt EV)|(Chevrolet Bolt)|(Chevy Bolt EV)|(Chevy Bolt)|( Bolt )|(BMW x5 eDrive)|(x5 eDrive)|(BMW x5)|(Audi Q7 e-Tron)|(Q7 eTron)|(Q7)|(Volvo XC90)|(XC90 T8)|(XC90)|(T8)|(XC-90)|(Volvo)|(BMW i7)|(BMW i5)|(i7)|(i5)|(Optima PHEV)|(Optima Plug-in)|(Kia Optima)|(Optima)|(Sonata PHEV)|(Sonata Plug-in)|(Hyundai Sonata)|(Sonata)|(Chrysler Pacifica PHEV)|(Chrysler Pacifica Plug-in)|(Chrysler Pacifica)|(Pacifica Hybrid)|(Pacifica)|(Hyundai IONIQ)|(IONIQ)|(Tesla Model 3)|(Model 3)|(Tesla Model X)|(Model X)|(Tesla Model S)|(Model S)|(Tesla)|(Chevy Volt)|(GM Volt)|(Volt)|(Apple EV)|(EVSEUpgrade)|(EVSE Upgrade)|(OpenEVSE)|(store.openevse.com)|(eMotorWerks)|(JuiceBox)|(SunPower)|(SolarCity)|(Solar City)|(EVPlates.com)|(EVPlates)|(TireRack.com)|(TireRack)|(Tire Rack)|(bumper sticker)|(EV Sticker)|(EVSE)|(VersiCharge)|(Eaton)|(Bosch)|(Schnieder)|(Schneider)|(GE Wattstation)|(Wattstation)|( GE )|(Legrand)|(Blink )|(Amazon)|(Clipper Creek)|(ClipperCreek)|(Leviton)|(Siemens)|(AeroVironment)|(TurboCord)|(ChargePoint)|(J1772)|(Extension Cord)|(Extension Chord)|(charger)|(extendmyseat)|(Yakima)|(Thule)|(SeaSucker)|(Leaf Spy Pro)|(Leaf Spy)|(Scan Tool)|(OBD2)|(JESLA)|(JLong)/gi.test(node.data)) {


You might or might not notice that some patterns contain spaces -- "(space)Bolt(space)". If they did the same to that other GM car, then the result wouldn't be so revolting. Of course, spaces inside the RE isn't the correct answer either, because it is what produces the difference between using blink and using blink. (Hint: "blink(dot)" is not linkified because the pattern is "Blink(space)" -- and no leading space is why weblink is incorrectly mangled).

What they should do to correctly fix this is use the \b modifier in all the REs to match word boundaries. E.g., "\bVolt\b".

Re: Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 8:33 am
by jlv
gshepherd wrote:Perhaps just turn the link-o-matic feature off altogether. It is more distracting than helpful.

+1. I have never followed such a link and I never will.

avoiding this breakage

Posted: Mon Oct 17, 2016 9:46 am
by jlv
This is a a test posting of the word voltage without the stupid link.
Or voltage.

Code: Select all

This is a a test posting of the word vol[size=100]t[/size]age without the stupid link.
Or vol[color=#000000]t[/color]age.


Sadly, I had a great example using the unicode greek small letter omicron instead of the "o" (see https://unicodelookup.com/#omicron/1), but that generated a SQL exception on posting.

Re: Breaking up words into context links results in madness

Posted: Mon Oct 17, 2016 3:40 pm
by FalconFour
jlv wrote:When I tried to use a T8 driver to loosen the bolt I found it stupidly added links, but then I tried to talk about the Bolt, well in that case it didn't linkify. I tried to focus on why, but before I could blink, I found out why. If you blink you might miss out on the spaces. It's all about spaces.

The offending code is found in http://www.myelectriccarforums.com/toolbar/toolbar2015.php and contains JavaScript that is executed in your browser after the page loads. That's just evil.

...

What they should do to correctly fix this is use the \b modifier in all the REs to match word boundaries. E.g., "\bVolt\b".


:lol: :lol: :lol: :lol:

Excellent example. It's really quite revolting to see pages so littered with such revolting spam. :lol: (and "evil" is an apt description... making it look like all of us are linking words all over the place!)

The context links really don't take anyone to any monetized resources* anyway, so what purpose do they serve to the forum owners? The car model links just take you to different forums. All of those tags ought to be formatted such as to isolate whole words, not parts of words... and IMO, that should be done at the parser level for each phrase, not bundled into each keyword (which will cause bloat).

The net result will be a whole lot less link impressions, but that's the point -- a whole lot fewer un-targeted mistakes littered all over everyone's posts.

* - ah, I see... many of them are monetized links. That's totally fair. After all, I <3 eMotorWerks and live and breathe JuiceBox, so I sure can't complain about that ;)

Re: Breaking up words into context links results in madness

Posted: Sun Nov 27, 2016 1:42 am
by drees
I agree that it sucks. It sucks so bad, that I block the script that injects that code into the site. Unfortunately, that does block the toolbar, but I have next to no interest in other EV forums, anyway.