NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript== // @name Low_float_Linkage // @namespace http://tampermonkey.net/ // @version 0.1 // @description LinkToTradingView and Robinhood // @author You // @match https://lowfloat.com/* // @grant none // @require https://code.jquery.com/jquery-3.3.1.slim.js // @require https://openuserjs.org/src/libs/aremesh/External_Lib.js // @license MIT // ==/UserScript== (function () { 'use strict'; // AddTopLinks() // AddIndLinks(); // AddPortfolioLinks(); // DetectAjaxChanges();*/ AddLinksToAll(); // Add_to_tradingview_watchList(); // Your code here... })(); function AddLinksToAll() { var newall = $("a[href*='https://finance.yahoo.com']"); newall.each(function (x) { var stockName = $(this).html(); var existing = $(this).parents("td").html(); var finalLink1 = GenerateLowfloatLinks(stockName, existing) $(this).parent("td").html(finalLink1) }) } function AddIndLinks() { var stockName = window.location.search.split("&")[0].split("=")[1] var existing = $(".ta-settings-button").html() var finalLink = GenerateLinks(stockName, existing, false) $(".ta-settings-button").html(finalLink) } function AddPortfolioLinks() { var all = $("td[title] a.screener-link-primary"); if (all.length === 0) { all = $("#body-table-portfolio td[title] a b") } all.each(function (x) { var stockName = $(this).html(); var existing = $(this).parents("td").html(); var finalLink = GenerateLinks(stockName, existing) $(this).parent("a").parent("td").removeAttr("onclick").parent("tr").removeAttr("onclick"); $(this).parent("a").parent("td").html(finalLink) $(this).parent("td").html(finalLink) }) } function DetectAjaxChanges() { var _send = XMLHttpRequest.prototype.send; XMLHttpRequest.prototype.send = function () { /* Wrap onreadystaechange callback */ var callback = this.onreadystatechange; this.onreadystatechange = function () { if (this.readyState == 4) { /* We are in response; do something, like logging or anything you want */ } callback.apply(this, arguments); AddPortfolioLinks(); } _send.apply(this, arguments); } } function Add_to_tradingview_watchList() { var newall = $(".screener-link-primary"); var allLink = "" var stockName = [] newall.each(function (x) { stockName.push($(this).html()) }) $(".fullview-links").each(function () { if ($(this).html().indexOf("save as portfolio") > 0) { $(this).prepend("<a class='tab-link' href='https://www.tradingview.com/symbols/F/?" + stockName.join(",") + "'>Add to tradingview watchlist</a> | ") } }) }