Greasemonkey and jQuery 1.4.2 not working

I am trying to use Greasemonkey and jQuery 1.4.2. When I install the Greasemonkey script, jQuery definitely loads and appears in the scripts directory. However, the code below does not add anything to the elements of the class PAPAGETITLE. What am I doing wrong?

// ==UserScript==
// @name           PS Timesheet
// @namespace      http://www.steelebit.com/gmscripts
// @description    Used to fix a terrible implementation
// @include        https://intranet.site.com/*
// @require        http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js
// ==/UserScript==

// Append some text to the element with id #someText using the jQuery library.
$(".PAPAGETITLE").append(" more text.");
+3
source share
2 answers

Update:

As with Greasemonkey version 0.9.1, jQuery 1.5.1 seems to work fine in all my scripts and tests.


Greasemonkey does not work with jQuery 1.4 without any hacking.

Use jQuery 1.3.2.

: http://forum.jquery.com/topic/importing-jquery-1-4-1-into-greasemonkey-scripts-generates-an-error ( ).

+2

, jQuery 1.4. *

+1

Source: https://habr.com/ru/post/1753772/


All Articles