Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

trying to go to the source ...

  • 3 replies
  • 0 have this problem
  • 2 views
  • Last reply by cor-el

more options

I am using firefox on a debian installation base: $ firefox-esr --version Mozilla Firefox 91.13.0esr $ uname -a Linux debian 5.10.0-18-amd64 #1 SMP Debian 5.10.140-1 (2022-09-02) x86_64 GNU/Linux $ These days web pages come with all kinds of cr@p; so, at times you need to just get all the links inside the page to parse/eyeball them. What I do is grab the "page source" and/or use "Link Gopher". I have been noticing lately that they don't work anymore. Why? The problem seems to relate to javascript generated pages. When you try to see the source all you see is some javascript one liner.

Of course, firefox must have a way to show the source since it shows to you the actual page unencrypted. Which settings in about:config should you change in order to be able to "go to the source" again? lbrtchx



edit: fixed some formatting issues

I am using firefox on a debian installation base: $ firefox-esr --version Mozilla Firefox 91.13.0esr $ uname -a Linux debian 5.10.0-18-amd64 #1 SMP Debian 5.10.140-1 (2022-09-02) x86_64 GNU/Linux $ These days web pages come with all kinds of cr@p; so, at times you need to just get all the links inside the page to parse/eyeball them. What I do is grab the "page source" and/or use "Link Gopher". I have been noticing lately that they don't work anymore. Why? The problem seems to relate to javascript generated pages. When you try to see the source all you see is some javascript one liner. Of course, firefox must have a way to show the source since it shows to you the actual page unencrypted. Which settings in about:config should you change in order to be able to "go to the source" again? lbrtchx edit: fixed some formatting issues

Modified by James

All Replies (3)

more options

Have you not tried to contact the site to ask them as well?

more options

You have two choices for viewing the current HTML source of the page as modified by scripts:

(1) Select the entire page content (Ctrl+A), right-click > View Selection Source (not working for me today for some reason)

(2) Open the Page Inspector (right-click the body > Inspect) then right-click the HTML tag at the top of the hierarchy > Copy > Copy Outer HTML and paste into your preferred editor for HTML

more options

You can of course JavaScript (bookmarklet) to get all the links on a page. Getting elements with a JavaScript onclick handler can be a problem, but normal getting links should work like with using document.querySelectorAll('a[href]') or document.links.


javascript:(function(){var L=[],E=prompt('*[onclick]\na[href]','a[href]');if(E){document.querySelectorAll(E).forEach(r=>{var N=r.nodeName;L.push('<'+N+(r.hasAttribute('onclick')?' onclick="'+r.getAttribute('onclick').toString()+'"':'')+(r.href?' href="'+r.href+'"':'')+'>'+(r.textContent?r.textContent.trim():'no-title')+'</'+N+'>')});prompt(L.join('\n'),L)}})()

Modified by cor-el