WEvent ToolBox Beta

Ajout du profile editor & co

Versione datata 25/04/2021. Vedi la nuova versione l'ultima versione.

Dovrai installare un'estensione come Tampermonkey, Greasemonkey o Violentmonkey per installare questo script.

You will need to install an extension such as Tampermonkey to install this script.

Dovrai installare un'estensione come Tampermonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Userscripts per installare questo script.

Dovrai installare un'estensione come ad esempio Tampermonkey per installare questo script.

Dovrai installare un gestore di script utente per installare questo script.

(Ho già un gestore di script utente, lasciamelo installare!)

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

(Ho già un gestore di stile utente, lasciamelo installare!)

// ==UserScript==
// @name            WEvent ToolBox Beta
// @icon            data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3wYBBicLUdqBwAAAA1lJREFUWMPFl0tIVFEYx39nug46qE1DYoWU1KJAKZHEoEVRLhwXQUFGKG6CHpsy7KlEi/BJA7myxyKoGSKDAhfpwoIWQWJgQzNQQTZa9DJKKjTG0dPijDo6984cG6UPLsy9c875/8/3/oSUEl15FITuF8iBIQiNwOiY+u50QP5KKMoH9xZEWaH2kQgdAie9yPZukBHASLI4uqa2HBoPIBz2FAg0dyHrfRqgVjIBTdVwfg9iwQQKzyKDw4CN1GQKCtZC/yVEup04JnEEJibBdRj5+w+LKpnpEGpHuDLnkogjkHVo8cFjSXztQGTE+IVtvtqXChzg9x8oucCcG9tiHS44nCLCpApJItZLgsMKK45AvTd1h3MXw48bcO0IELZYZIN6H4yFYwicvI0kzWKDVDfTeVY51ZbDu8BXm4CEAQ13lRaElBJbFebBOAmXayDPBToJc0MulKyffX/wHPa1gdnlBDDlQxi9AesM5y6Guop/N8nerVC9E7xPTRQbgd4AGD1+pFWmexSEgRCsWaEHmGGH7IzZ99A36OyzNkOPH2kMDFkfGI5A8ZmojTWkugxuH1O/33yCTacgkeUGhsAIjSQ5Nc3chqYOHk1xL9/D5rNgXQGiGhoBY7qkLobcegLjYbj3LDk4qHKuH/kS9peq4mKtArjXpwc+s8Xp0AP3t0DncajZsXgaczrAyM+Bwa+JF77ywMbV0eoqAd16sSyx/+TngKjzSul5aL7AbsBrj2q3puXnuLKzjnz8Adsuqmgyk7oKMMq3IDxd5rmgsnQuOKg4j431RJK7HHYXQLffvHUrL0IkTsUTcP807C2Z/dQ/CG+/aDSbAj58h1O3oqawSsUAJ8rhSo95DtjXBt5aqNquPnX0ws3Hui5uDg5wwh1TDZsOICxruB2qr8D1KOjn0eihOo+w7pwbK9W/My1ZSxfy/J0EPUEEnNkw+sv6VrpNavNBOLdnHoGZTvgDSyoFeRBondXNHALjE5B7FPnrfzWl6Wnwrh2Rlb404KF2NRuYNqXToeHKhC9XEYV5SfL+QgaTPHXz+TMBZi4ngIw0eNmKaD6YuMNNKhHlcIFWpXbxL8PpWBgaOhc2nApD5ZaUh9O4Fi0A3X7kiyF4N388z4GideAuQpQV6CvpLyjrNaUqOdRiAAAAAElFTkSuQmCC
// @namespace       WFTB_ns
// @version         0.0.1
// @description:en  Added edotor profile and other
// @description     Ajout du profile editor & co
// @author          exolium
// @match           http://*.waze.com/*/events/*
// @match           https://*.waze.com/*/events/*
// @copyright       2015-2021 exolium
// @licence         GNU GPL v2
// @grant           GM_xmlhttpRequest
// ==/UserScript==

/* **************************************************************************** *
 * Info version : Alpha release      : 0.0.1.1, 0.1.1.1, 1.1.2.1,...
 * Info version : Beta release       :  0.0.1 ,  0.2.1 ,  1.1.1 ,...
 * Info version : Production release :   1.0  ,   1.1  ,   2.0  ,...
 * **************************************************************************** *
 * Thanks to beta tester and script developer who bring innovative ideas to me
 * laurenthembord, laurenthembprd,....
 * *************************************************************************** */

//============================== Options ================================//
var WEvents_Log_level = 5; // 0 = no log / 1 = error / 2 = warn / 3 = min log / 4 = Medium Log / 5 = high detail Log
var WEvents_targetblank = true;
var WEvents_button_editorprofil = 'Editor Profil A';

//================================ Vars ======================================//
var WEvents_beta_editor_verify = false;
var WEvents_beta_editor = false;
var WEvents_profil = Array();
var WEvents_Settings = {};
var WEvents_search = '//*[contains(@class, \'mte-user__name\')]';

//================================ Code ======================================//

function WEvents_xpath(WEvents_L_query, WEvents_L_element) {
 //WEvents_Log('WEvents_xpath', 4, 'Start');

 var WEvents_L_result = document.evaluate(WEvents_L_query, WEvents_L_element, null, XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null);
 var WEvents_L_table = new Array();
 var WEvents_L_cpt = 0;

 for (WEvents_L_cpt = 0; WEvents_L_cpt < WEvents_L_result.snapshotLength; WEvents_L_cpt++) WEvents_L_table.push(WEvents_L_result.snapshotItem(WEvents_L_cpt));
// WEvents_Log('WEvents_xpath', 4, 'End');
 return WEvents_L_table;
}

function WEvents_single_xpath(WEvents_L_query, WEvents_L_element) {
// WEvents_Log('WEvents_single_xpath', 4, 'Start');
 var WEvents_L_elmFirstResult = document.evaluate(WEvents_L_query, WEvents_L_element, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue;
// WEvents_Log('WEvents_single_xpath', 4, 'End');
 return WEvents_L_elmFirstResult;
}

(function() {
    'use strict';
 var WEvents_L_result = WEvents_xpath(WEvents_search, document);
 WEvents_L_result[0].innerHTML='<a target="_blank" href="https://www.waze.com/fr/user/editor/' + WEvents_L_result[0].innerHTML + '">' + WEvents_L_result[0].innerHTML + '</a>';
    // Your code here...
})();

//============================================================================//