Gossamer Forum
Home : Products : DBMan : Customization :

Short and long output

Quote Reply
Short and long output
I have a search that outputs all fields of the results, and then when you clik on one of the links it brings up a review of that record (restaurant).

I'd like to have another output of results that shows a truncated output, and then maybe if you click on a flag or "twirlie" you can see the rest of the listing.

If this has been addressed in another thread please direct me to the appropriate location.

TIA!!

BTW, I'm happy to say that my DBMan database has been up and running for several months and tasteofbrooklyn.com has been getting more and more hits monthly! Thanks to all of you!!
Quote Reply
Re: Short and long output In reply to
Have you looked at the short/long display mod on my site? Or are you looking for something else?

(The short/long display mod is at http://www.jpdeni.com/...ds/short_html_pl.txt )



------------------
JPD





Quote Reply
Re: Short and long output In reply to
Yes, I just found that again after doing a search! Is there somewhere I can see an example?

Also, if I want to use that Mod AND the current html.pl I'm using, I assume I just create new db.cgi file, default.cfg etc. for everything? (except the default.db as that's where it'll get its info from). Yes ? No?

Ta.

Quote Reply
Re: Short and long output In reply to
You can see it in action at

http://www.jpdeni.com/...&ISBN=*&sb=1

Of course, you can set it up any way you want.

The only file you'll need to change is the html.pl file, and that just needs a little tweaking. Basically, you'll change sub html_record and add a new subroutine.

BTW, glad to know your site is working out so well! Smile



------------------
JPD





Quote Reply
Re: Short and long output In reply to
I guess I should put this "new" html.pl (for the short display) in another directory (or re-name it) so it doesn't interfere with the current html.pl. (as I'd like to use both)

Also, I must create another db.cgi and default.cfg?

Please advise.

TIA.
Quote Reply
Re: Short and long output In reply to
You probably won't want to interrupt your ongoing database while you work on something new. I would copy all of the existing files to another directory and then start working on the html.pl file so you can get the short/long mod to working. Once it's working to your satisfaction, move the temporary html.pl file to your main directory and delete the temporary one.

I was mistaken about the changes between the short/long display and the regular html.pl file. There are some little changes in some of the other subroutines that make it all work together.

Does this help?


------------------
JPD





Quote Reply
Re: Short and long output In reply to
Yes, that helps, however I want to use both.
(the short/long display AND the long display)

Is that possible? Do I use different directories and point to the same default.db ?

Thanks again.
Quote Reply
Re: Short and long output In reply to
Well, you could set a switch that the users could select when they do a search. But you really want to just have one html.pl file -- and one of each of the other files, too, if you're using the same data.

Why don't you play around with the short/long display first? Get it as you want it to look and then we'll work on a switch for you.


------------------
JPD