Gossamer Forum
Home : Products : DBMan : Customization :

Condtional based on number of hits

Quote Reply
Condtional based on number of hits
Ok, this is sorta a continuation, but a new question.

Im using a fairly complex table arrangment for my dispalying of records.

What kind of conditional can i use to close off the tables at the end of them.

So lets say i had 5 hits. at the end of the 5th, i need to close the table cells. But if there were 6 hits, i would have a slightly differnt code to have at the end of the cell, to prepare the opening tags as wel for the next hit.

I hope that made sense.

I have been looking at the view_success, since im sure its there, but I am really not sure which statement it is.

It would be a if followed by an else statement.

Thanks a ton agian!

Quote Reply
Re: Condtional based on number of hits In reply to
Guessing again. Laugh Couldn't you do this:

if (($db_total_hits == 5)) {
&html_record_5_results(&array_to_hash(0, @hits));
}
else {
&html_record_6ormore_results(&array_to_hash(0, @hits));
}