03-13-2013
Help on filtering the table in HTML
1. how to get the filter option on table so that user can enter the fields which ever they want to print only according to the need ?
2.how to print the full fledge table if there is no value in the rows of the table but it should print the whole rows and column in proper tabular form?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi !!
I have HTML Tables through which i want to generate graphs, but for creating graphs i need the file in CSV format so can anyone can please help me in how can i convert my HTML table file to CSV format.
Thanks in Advance (2 Replies)
Discussion started by: i_priyank
2 Replies
2. Shell Programming and Scripting
Hello All,
I have a perl script that prints a HMTL table. I want to convert this data into a report and this want to export this information into Excel. How can I do this?
Regards,
garric (3 Replies)
Discussion started by: garric
3 Replies
3. Shell Programming and Scripting
Hi All,
I have an html table which looks like this:
<table align="center" border="1">
<CAPTION><EM>Heading for Table</EM></CAPTION>
<tr><td><b>1</b></TD><TD><b>2</b></TD><TD><b>3</b></TD><TD><b>4</b></TD><TD><b>TOTAL</b></TD><TD><b>DATE</b></td></tr>
<tr><td>88088283</TD> <TD>87613101</TD>... (1 Reply)
Discussion started by: pondlife
1 Replies
4. Shell Programming and Scripting
I have a short time to solve a problem, so I need some help. I've searched the forum, but I couldn't find a solution to my problem.
I made a script to filter some text and now I have a new requirement to make it available as html table. Problem is that I more than one files with different set... (2 Replies)
Discussion started by: tetreb
2 Replies
5. Shell Programming and Scripting
Hi all,
I have a html that contains several tables in it. Need to extract the data from one of them named "orderList". Is it any easy way without using loops.
Thanks (4 Replies)
Discussion started by: valigula
4 Replies
6. Shell Programming and Scripting
HI all,
<html>
<body>
<div>
<table id="orderList">
<thead>
<tr>
<th>order number</th>
<th>order type</th>
<th>product type</th>
<th>status</th>
<th>status date</th>
</tr>
</thead>
<tbody>
<tr class="odd">
... (10 Replies)
Discussion started by: valigula
10 Replies
7. Shell Programming and Scripting
Hello everyone! i I'm trying to write a script that can filter data in a text file.
the source file looks like this
the result file should look like this
As you can see mostly i need to delete fields like _219402757693 and date - time 12.07.2012 8:49:06
i know that it's possible to... (0 Replies)
Discussion started by: o28
0 Replies
8. UNIX for Dummies Questions & Answers
I want to extract a table from an HTML file. the table starts with
<table class="tableinfo"
and ends with next closing table tag
</table>
how can I do this with awk/sed...
---------- Post updated at 04:34 PM ---------- Previous update was at 04:28 PM ----------
also I want to... (4 Replies)
Discussion started by: koutroul
4 Replies
9. Shell Programming and Scripting
please help solving the following. I have access to redhat linux cluster having 32gigs of ram.
I have duplicate ids for variable names, in the file 1,2 are duplicates;3,4 and 5 are duplicates;6 and 7 are duplicates. My objective is to use only the first occurrence of these duplicates.
Lookup... (4 Replies)
Discussion started by: ritakadm
4 Replies
10. UNIX for Beginners Questions & Answers
HI ,
I have a HTML tables as below.
It has 2 tables ,I want to extract the second table .
Please help me in doing it.
<html>
<body>
<b><br>Running Date: </b>11-JAN-2019 03:07</br>
<h2> Schema mapping and info </h2>
<BR><TABLE width="100%" class="x1h" cellpadding="1"... (3 Replies)
Discussion started by: deepti01
3 Replies
LEARN ABOUT MOJAVE
html::filter5.18
HTML::Filter(3) User Contributed Perl Documentation HTML::Filter(3)
NAME
HTML::Filter - Filter HTML text through the parser
NOTE
This module is deprecated. The "HTML::Parser" now provides the functionally of "HTML::Filter" much more efficiently with the the "default"
handler.
SYNOPSIS
require HTML::Filter;
$p = HTML::Filter->new->parse_file("index.html");
DESCRIPTION
"HTML::Filter" is an HTML parser that by default prints the original text of each HTML element (a slow version of cat(1) basically). The
callback methods may be overridden to modify the filtering for some HTML elements and you can override output() method which is called to
print the HTML text.
"HTML::Filter" is a subclass of "HTML::Parser". This means that the document should be given to the parser by calling the $p->parse() or
$p->parse_file() methods.
EXAMPLES
The first example is a filter that will remove all comments from an HTML file. This is achieved by simply overriding the comment method to
do nothing.
package CommentStripper;
require HTML::Filter;
@ISA=qw(HTML::Filter);
sub comment { } # ignore comments
The second example shows a filter that will remove any <TABLE>s found in the HTML file. We specialize the start() and end() methods to
count table tags and then make output not happen when inside a table.
package TableStripper;
require HTML::Filter;
@ISA=qw(HTML::Filter);
sub start
{
my $self = shift;
$self->{table_seen}++ if $_[0] eq "table";
$self->SUPER::start(@_);
}
sub end
{
my $self = shift;
$self->SUPER::end(@_);
$self->{table_seen}-- if $_[0] eq "table";
}
sub output
{
my $self = shift;
unless ($self->{table_seen}) {
$self->SUPER::output(@_);
}
}
If you want to collect the parsed text internally you might want to do something like this:
package FilterIntoString;
require HTML::Filter;
@ISA=qw(HTML::Filter);
sub output { push(@{$_[0]->{fhtml}}, $_[1]) }
sub filtered_html { join("", @{$_[0]->{fhtml}}) }
SEE ALSO
HTML::Parser
COPYRIGHT
Copyright 1997-1999 Gisle Aas.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.18.2 2013-03-25 HTML::Filter(3)