Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Quick Javascript/CSS Question

Name: Anonymous 2011-05-13 19:41

Howdy, /prog/. Is this place still somewhat good, or did the true /prague/riders get  overrun by skiddie /g/ kids? I mean, more than usual.

My ``serious'' programming experience is limited to silly games I write in Sepples with SDL to amuse myself. However, I still believe that I command a decent knowledge of programming and electronics-related topics. One topic I don't know very much about, however, is ``web development'', apart from what I remember from making stupid web pages on Angelfire as an adolescent. So, basically, I want to know whether something is possible with Javascript.

I want to make a ``bookmarklet'' that uses a few lines of Javascript to insert a CSS rule that sets a width to the body div. Did I say that right? I guess I would use document.write to do this, but I don't know what Javascript is allowed to do in a browser (I've never written a single line of it), so I'm not sure. Is this a feasible thing for one to do?

The idea is that, if you're on one of those sites with text that spans the width of the window, and don't feel like resizing your browser, you can just click the bookmarklet, and the entire page will be stuffed into a nice, legible column of text. If I was going to be browsing a site like this for a long period of time, it would make more sense to slap together a custom CSS file for it, but when you just want to look a single page, this would do the trick quite nicely.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List