I want to come back to a GM script code I have asked here a couple of days 
before.

I simplified the task and want to replace the <strong>...</strong>element by 
just the string "aaa" from the URL line this page:

http://www.printfriendly.com/print?url=http%3A%2F%2Fdeutsche-wirtschafts-nachrichten.de%2F2014%2F12%2F26%2Fein-gutachten-wie-ein-donnerhall-gez-
sender-haben-ausgedient%2F&partner=Shareaholic#

with the GM script (code) shown at the bottom of this email.
I have successfully installed this user script in Firefox.

However when I load/reload the webpage it is NOT applied.

When I copy exactly the two statements from script and run it in Firebug 
console then it IS executed!!

This is very strange.

For better understanding of my problem I created a short screenrecording video 
(download links:

http://s000.tinyupload.com/index.php?file_id=34584556186685118864

or

http://d01.megashares.com/dl/GoQRtzi/script%20only%20working%20on%20console.avi

or

https://www.sendspace.com/file/n9ciuj


As you can see GM knows that the script is matched but does NOT execute it.

Why?

I guess the javascript code cannot be the culprit. It must be either the header 
definition or Greasemonkey preferences.

Ben



// ==UserScript== 
// @name            ChangeLayoutDWN
// @namespace       nsChangeLayoutDWN
// @description     Change Layout deutsche-wirtschafts-nachrichten.de
// @include         http://*deutsche-wirtschafts-nachrichten.de/*
// @include         http://www.deutsche-mittelstands-nachrichten.de/*
// @include         http://www.printfriendly.com/*
// @version         2.2.0
// @grant           GM_addStyle
// @require         http://code.jquery.com/jquery-latest.js
// ==/UserScript== 

var content = document.getElementById("pf-src"); 
content.innerHTML=content.innerHTML.replace(/<strong>deutsche-wirtschafts-nachrichten.de<\/strong>/g,"aaa");
 


















-- 
You received this message because you are subscribed to the Google Groups 
"greasemonkey-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/greasemonkey-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to