HF View Last Post on 'Your Posts'

Add a View Last Post link to the 'Your Posts' page.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

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

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

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

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name        HF View Last Post on 'Your Posts'
// @description Add a View Last Post link to the 'Your Posts' page. 
// @include     *hackforums.net/search.php*
// @require     http://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js
// @version     1
// @namespace https://greasyfork.org/users/24272
// ==/UserScript==
var pageText = $('body').html().toString();

var foundText = pageText.indexOf("Last Post");

if (foundText == -1) {
    $(".trow1 a[href*='showthread.php?tid=']").each(function(e) {
        uid = $(this).attr("href");




        if (uid.indexOf('pid') > -1) {} else {

            $(this).after("<a href=" + uid + "&action=lastpost><b><u>View Last Post</u></b></a>");
            $(this).after(" || ");
        }

    })

    $(".trow2 a[href*='showthread.php?tid=']").each(function(e) {
        uid = $(this).attr("href");

        if (uid.indexOf('pid') > -1) {} else {

            $(this).after("<a href=" + uid + "&action=lastpost><b><u>View Last Post</u></b></a>");
            $(this).after(" || ");
        }

    })
}