Closed Thread Icon

Topic awaiting preservation: Need Help With ASP Search Engine (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=12839" title="Pages that link to Topic awaiting preservation: Need Help With ASP Search Engine (Page 1 of 1)" rel="nofollow" >Topic awaiting preservation: Need Help With ASP Search Engine <span class="small">(Page 1 of 1)</span>\

 
Ramasax
Paranoid (IV) Inmate

From: PA, US
Insane since: Feb 2002

posted posted 07-31-2003 09:20

This is hard for me to explain even though I'm sure it is a very simple thing to do.

I 'd like to be able to display a portion of the contents of a database field on an ASP webpage. I can generate the code to display the field, but have not found a way to limit the number of characters or amount of data that is displayed. (ie. Search engine results . . .) Not worried about highlighting words or anything like that.

I'm relatively new to ASP and Access/SQL databases so I'm learning as I go. Any help would be appreciated.

Ramasax
Paranoid (IV) Inmate

From: PA, US
Insane since: Feb 2002

posted posted 07-31-2003 10:11

And it was, thanks anyways.

Left(string, 400)

Ramasax


Emperor
Maniac (V) Mad Scientist with Finglongers

From: Cell 53, East Wing
Insane since: Jul 2001

posted posted 07-31-2003 10:20

Ramasax: Glad we could help

___________________
Emps

FAQs: Emperor

Pugzly
Paranoid (IV) Inmate

From: 127.0.0.1
Insane since: Apr 2000

posted posted 07-31-2003 18:23

You'll want to check if the field is longer than 400 before you truncate it, especially if you're adding something like '...' to it. Otherwise, you'll end up with some data that's less than 400 that still has the '...' on it.

Hope that makes sense.

Ramasax
Paranoid (IV) Inmate

From: PA, US
Insane since: Feb 2002

posted posted 07-31-2003 23:22

Makes perfect sense. I actually cut that down to 150 characters, and I am pulling from the entire text of all the pages, so it won't be a problem as far as I can see. I could always add an if statement to be sure I suppose.

Thanks,

Ramasax

« BackwardsOnwards »

Show Forum Drop Down Menu