Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I need heavy duty favor on a bulleted list

Status
Not open for further replies.

chinedu

Technical User
Mar 7, 2002
241
US
I am working on cataloging items for a pharmaceutical company.

Basically, there are categories and products associated with each category.

I have worked out those nicely.

The problem I am having now is on product description.

The descriiptions are done in a bulleted formatlike:

. Mighty red dog
. The red nosed rendeer
. Beanies
etc..

My big worry is how to input these descriptions and have them appear in the format above.

I have tried entering them and using split function to split them at every ocurrance of . (dot).

That didn't work.

Then I tried coming up with this code in such that once descriptions for a product are entered, they appear in a bulleted list.

I am not getting any errors but the values being generated are not in bulleted form.

Can someone please help.

Here is the code I am using for creating bullted list.

Maybe this code should be in the insert page, not on the form input page.
strUserText = rs("catdescription")
strUserText = Replace(strUserText, VbCrLf, "<li>")
Code:
Then the code is invoked here:
[code]
    <tr>
      <td>Product Description:</td>
      <td> <textarea name="pdescription" cols="30" rows="5" value="<%=strUserText%>"></textarea>
    </tr>

Thanks in advance

 
I prefer to use a markup code for entry and storing in the db then have some functions that replace the markup with html on display, as in this post. thread333-893429

BTW your textarea code should be

Code:
      <td><textarea name="pdescription" cols="30" rows="5><%=strUserText%></textarea></td>

If this is your display code as well, html is not executed inside a text area everything is treated as plain text. So if that's where you are expecting to see the lists, it won't happen.


Chris.

Indifference will be the downfall of mankind, but who cares?
A website that proves the cobblers kids adage.
Nightclub counting systems

So long, and thanks for all the fish.
 
Wow, you guys are just too fast and too good in this forum.

Yes, you are right Chris, the way I was using it wasn't working.

It is working now, I had the code right, however, I was sticking the code on the wrong page plus what you just mentioned.

Thanks again.

I hope you gurus will be around when I get started on a huge project next month.

 
also for formatting you could encase your strusertext in <UL> and </UL> and replace the dots/periods ( would be wiser to use a less commmon character like "pipe" ) with <LI> to make bullets via HTML

[thumbsup2]DreX
aKa - Robert
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top