Elinks configuration?

#1

Good Day Folks,

I was wondering if we have any Elinks gurus here?
I want to know how one would go about creating a custom CSS stylesheet? I am trying to remove prelinks from a website when I load it (see images below). There are so many links that I have to scroll down a few pages before I can get to the reading bit.
Any ideas?

1 Like
#2

I dont think you can use anything like CSS with a text only based web browser, your best bet would be to get familiar with the commands within elinks.

https://wiki.archlinux.org/index.php/ELinks

#3

@s7l - elinks has some support for css according to ArchWiki - no examples though.

@fatboy - did you try “o” (lower case o) while running elinks? That brings up a configuration menu. If not css, maybe use lua or guile (according to elinks site) - elinks documentation

2 Likes
#4

@PackRat so it does, my skim reading is bad of late :face_with_monocle:

Ive tried searching for css for elinks but not had any luck so far, surely there is an example file somewhere.

#5

I tried that too, same result. Makes me suspect that any elinks support for css is useless.

#6

I have played with the config tool of Elinks and things are better, not exactly how I want them though.haha.
No complaints though.

The thing is, I use Elinks as a reader / opening links from newsboat. This is why I would like a reader mode, or something that strips out all the links and images I am not going to follow/view.

#7

Have you checked out some of the other text-based browsers linke lynx or w3m? Maybe there’s one that does what you’re after.

Wouldn’t surprise me if someone that uses surf or similar browser has written that extension; I can see where that would be handy. A search of the Arch forum may be worth your while.

#8

Newsboat looks interesting. How does that work? Configure it to get the rss feed from news sites and pipe the output to elinks?

#9

Newsboat has a URL config file, insert your rss feed url there.
You can then further configure newsboat by selecting a default browser.
When you want to open an article, you press “o”.

Here are my configs:

My config

browser         "elinks"
player          "mpv"
download-path   "~/downloads/%n"
save-path       "~/downloads"
reload-threads  20
cleanup-on-quit yes
text-width      74

color background          white   black
color listnormal          cyan   black
color listfocus           white  blue   dim
color listnormal_unread   yellow black
color listfocus_unread    yellow blue   bold
color info                white  blue   bold
color article             white   black

bind-key - quit
bind-key G end
bind-key g home
bind-key j down
bind-key k up

My URLs

https://www.goal.com/feeds/en/news "~Goal.com"
https://www.barcablaugranes.com/rss/current.xml "~Barca Blaugranes"
https://www.linuxjournal.com/node/feed "~The Linux Journal"
http://www.barcelonafootballblog.com/feed/ "~Barcelona Football Blog"
https://feeds.feedburner.com/sciencealert-latestnews "~Science Alert"
https://blog.xfce.org/feed/ "~XFCE Blog"

The “~website” is the how the link is displayed in newsboat

1 Like