
najwilson
New User
Mar 19, 2003, 1:04 PM
Post #1 of 2
(262 views)
|
While(<database>) display results
|
Can't Post
|
|
Does anyone have a clue how to solve this problem! I want to add code that will limit 10 or so, per page results to display, to tie in with the following while(<database>)code without using a module.. open (DATABASE, "$datafile") || die "Can't Open $datafile"; while(<DATABASE>) { chop; @results = grep(/$searchstr/i,$_); if ($#results >= 0) { foreach $i (@results) { chomp ($i); ($sku, $category, $price, $short_description, $image, $long_description, $shipping, $user1, $options) = split(/\|/, $_); No help needed for this part - goes on to print result.......
|