Saurabh Singh | 6 Dec 12:23
Picon

Newbie: Using elinks to convert html table to text file for printing on dot matrix printer

Hi All,

I have just discovered elinks in my hunt for a Html->PrettyText solution.

A little background of my use-case:

My java application is formatting some data as html tables (basically simple reports) and sending them to my users' browser.
This is shown nicely in their graphical browsers (firefox etc) but when someone wishes to print it on text only (dot matrix) printer, the printer sees the data as a graphical image and proceeds to print it very slowly.
eg: character C would be printed in 3-4 passes by the printer - making it very very slow

I am trying to pass this html string via a converter which will convert it to text, keeping intact the column alignment for tables (i.e. keeping intact the vertical alignment of cell data across the rows - by adding extra spaces or wrapping text as required).

  • Can I use elinks in a way where I give it a 'string' which is fully formed html page and get the text output which I can then send to the user's browser for fast printing?
I am using java code running in tomcat on linux.

Thanks in advance,
S.Singh
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users
Lars Bjørndal | 7 Dec 16:32

Compile problem

The compile process fails.

>From configure output:

ECMAScript (JavaScript) ......... SpiderMonkey document scripting
Browser scripting ............... SpiderMonkey

Even though, I get the following error when compiling:

lib.o: In function `get_temp_name':
/home/lrs/rpmbuild/BUILD/elinks-0.13.GIT/src/session/download.c:1008: warning: the use of
`tempnam' is dangerous, better use `mkstemp'
lib.o: In function `spidermonkey_eval_stringback':
(.text+0x4b61c): undefined reference to `JS_GetStringBytes'
lib.o: In function `spidermonkey_eval_stringback':
(.text+0x4b640): undefined reference to `JS_GetStringBytes'
lib.o: In function `document_write_do':
document.c:(.text+0x4b837): undefined reference to `JS_GetStringBytes'
document.c:(.text+0x4b85b): undefined reference to `JS_GetStringBytes'
lib.o: In function `document_set_property':
document.c:(.text+0x4ba91): undefined reference to `JS_GetStringBytes'
lib.o:document.c:(.text+0x4babe): more undefined references to `JS_GetStringBytes' follow
lib.o: In function `input_set_property':
form.c:(.text+0x4db9c): undefined reference to `JS_GetStringChars'
form.c:(.text+0x4e003): undefined reference to `JS_GetStringBytes'
form.c:(.text+0x4e033): undefined reference to `JS_GetStringBytes'
form.c:(.text+0x4e062): undefined reference to `JS_GetStringBytes'
form.c:(.text+0x4e092): undefined reference to `JS_GetStringBytes'
form.c:(.text+0x4e0c1): undefined reference to `JS_GetStringBytes'
lib.o:form.c:(.text+0x4e0ed): more undefined references to `JS_GetStringBytes' follow
lib.o: In function `jsval_to_bookmark_string':
bookmarks.c:(.text+0x786d0): undefined reference to `JS_AddNamedRoot'
bookmarks.c:(.text+0x78734): undefined reference to `JS_RemoveRoot'
bookmarks.c:(.text+0x78760): undefined reference to `JS_RemoveRoot'
bookmarks.c:(.text+0x78771): undefined reference to `JS_RemoveRoot'
lib.o: In function `cache_entry_set_property':
cache_object.c:(.text+0x78d4a): undefined reference to `JS_GetStringBytes'
cache_object.c:(.text+0x78d9c): undefined reference to `JS_GetStringBytes'
cache_object.c:(.text+0x78e12): undefined reference to `JS_GetStringBytes'
lib.o: In function `smjs_do_file_wrapper':
core.c:(.text+0x79186): undefined reference to `JS_GetStringBytes'
lib.o: In function `jsstring_to_utf8':
(.text+0x7950a): undefined reference to `JS_GetStringChars'
lib.o: In function `elinks_set_location':
elinks_object.c:(.text+0x79706): undefined reference to `JS_GetStringBytes'
lib.o: In function `elinks_execute':
elinks_object.c:(.text+0x797f4): undefined reference to `JS_GetStringBytes'
elinks_object.c:(.text+0x79818): undefined reference to `JS_GetStringBytes'
lib.o: In function `elinks_alert':
elinks_object.c:(.text+0x798fc): undefined reference to `JS_GetStringBytes'
elinks_object.c:(.text+0x79920): undefined reference to `JS_GetStringBytes'
lib.o:globhist.c:(.text+0x79b64): more undefined references to `JS_GetStringBytes' follow
lib.o: In function `smjs_loading_callback':
load_uri.c:(.text+0x7a72b): undefined reference to `JS_RemoveRoot'
lib.o: In function `smjs_load_uri':
load_uri.c:(.text+0x7a799): undefined reference to `JS_GetStringBytes'
load_uri.c:(.text+0x7a80e): undefined reference to `JS_AddNamedRoot'
lib.o: In function `view_state_set_property':
view_state_object.c:(.text+0x7aa24): undefined reference to `JS_GetStringBytes'
view_state_object.c:(.text+0x7aa48): undefined reference to `JS_GetStringBytes'
collect2: ld returned 1 exit status
make[1]: *** [elinks] Error 1
make[1]: Leaving directory `/home/lrs/rpmbuild/BUILD/elinks-0.13.GIT/src'
make: *** [all-recursive] Error 1

I use Fedora 15, and I think the relevant packages are
js-1.8.5-6.fc15.i686 and js-devel-1.8.5-6.fc15.i686.

I tried to update my elinks source files, but it seems that they was last
updated in 2010. Any ideas how to get elinks work again, after upgrading
from Fedora 14 to Fedora 15?

Thanks,
Lars
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users

enathaniel | 15 Dec 17:47

Weird characters

Good day guys,

I'm having a bit of display trouble when using Elinks from Putty:

http://i.imgur.com/omWJZ.png

Would anyone happen to know why?

System:
- Ubuntu Server 10.10
- Installing elinks from apt-get repo (no modification/customization)
- Using Putty

The odd part is that if I use the console directly, elinks will display borders as expected

Cheers
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users
Chris Jones | 15 Dec 19:04
Picon

Re: Weird characters

On Thu, Dec 15, 2011 at 11:47:59AM EST, enathaniel <at> pcis.com wrote:
> Good day guys,
> 
> I'm having a bit of display trouble when using Elinks from Putty:
> 
> http://i.imgur.com/omWJZ.png 
> 
> Would anyone happen to know why?
> 
> System: 
> - Ubuntu Server 10.10
> - Installing elinks from apt-get repo (no modification/customization)
> - Using Putty
> 
> The odd part is that if I use the console directly, elinks will display 
> borders as expected

Saw something similar with the ELinks version that I picked up from the
debian ‘lenny’ repos (may be the same as Ubuntu 10.10), that may have
had something to do with unicode support. The fact that you don't see
the problem in the linux console and see it in putty suggests you may
have run into the same problem.

Anyway, I downloaded the source of a more current version of ELinks and
made sure that I checked ‘VT100 frames’ in the pull down menu (Setup ->
Terminal Options) and the problem went away. 

But then again my environment is quite different, since I have my locale
set to the default UTF-8 and I am using a unicode-capable version of
xterm (uxterm or ‘xterm -u8’). 

Unless someone more knowledgeable comes up with a real solution, I would
suggest you play a bit with changing your locale, switch to a unicode
version of putty (if relevant) or a different emulator, and use the
Terminal Options dialog to specify different frames and see if you get
them to display correctly. I have a feeling that the ‘no frames’ option
that gives you ASCII characters such as ‘+-----+’ instead of the frames
drawn using the prettier line-drawing characters and that should work in
all circumstances. This might provide a tolerable workaround while you
research this further.

CJ
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users
Lars Bjørndal | 15 Dec 20:49

Terminal problems after upgrading to Fedora 15

Hi

After upgrading from Fedora 14 to Fedora 15, I was able to compile
ELinks-0.13-GIT, although I had to disable ECMAscript support. Now, I
have strange terminal problems that only occures within a screen session
(I don't use any X). I've read somewhere that the screen program from
Fedora 14 is not compatible with the same program from Fedora 15. What's
happening, is that, for every new page that ELinks loads, the terminal
beeps. After that, the terminal beeps also if I change screen window.
Also, I notice that sometimes the terminal get stuck, and missdisplay
the page. Noticable is the top line, which shows the information too
long to the left.

Are some of you able to tell me how to fix this problem? I'm used to
ELinks, and don't want to miss it.

Thanks and regards,
Lars
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users

Joe | 17 Dec 09:02
Picon
Gravatar

Re: Weird characters

2011-12-15T10:04:16-0800, cjns1989 <at> gmail.com wrote: 
> On Thu, Dec 15, 2011 at 11:47:59AM EST, enathaniel <at> pcis.com wrote:
>> Good day guys,
>> 
>> I'm having a bit of display trouble when using Elinks from Putty:
>> 
>> http://i.imgur.com/omWJZ.png 
>> 
>> Would anyone happen to know why?

Go into the menu, choose Setup -> Terminal Options, and change the
setting under `Frame Handling' and see if that helps.

`No Frames' might be the best choice because it just uses ASCII.

http://i.imgur.com/kQuSq.gif

--

-- 
Joe
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users

Witold Filipczyk | 17 Dec 10:36
Picon
Favicon

Re: Compile problem

Lars Bjørndal <lars <at> lamasti.net> writes:

> 
> The compile process fails.
> 
> >From configure output:
> 
> ECMAScript (JavaScript) ......... SpiderMonkey document scripting
> Browser scripting ............... SpiderMonkey
> 
[snip]

Are you sure, you got the latest sources of ELinks?
Recent changes were made in November 2011.

_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users
Adam Bogacki | 18 Dec 20:19
Picon

Weird characters

I had the same problem recently on both Debian and WattOS_R4 (a low-energy use *buntu derivative) drives.

After some searching the advice I found was that it was a gnome-terminal error, easily fixed by typing 'reset' at prompt
to reset the display, or else closing and re-opening gnome-terminal.

Since then, so good .. so far.

Adam.

adam.bogacki <at> clear.net.nz
_______________________________________________
elinks-users mailing list
elinks-users <at> linuxfromscratch.org
http://linuxfromscratch.org/mailman/listinfo/elinks-users

Gmane