Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Ordered Lists, Get Text Format, HTML Export

Featured Replies

  • Newbies

Hello everybody,

I got a question regarding ordered lists and the ways to read the text format attributes of a text within a text field.

Challenge: Within a text field the client wants to add some ordered lists with indents (Text Ruler) and some text lines without. He then wants to export all the records as HTML while keeping the text attributes (like indents).

Solution: I know there's getAsCSS but it doesn't get all text attributes (indents should become ul resp. ol tags) and in addition to that it doesn't output valid XHTML. So I have to find my own solution.

Question: How can I read out all attributes of a text field (including indents).

Any ideas on how to do this?

Best,

DH

Perhaps they should be entering tabs to indent a line, instead of modifying the ruler.

In any case, a free-form text field is not a good way to enter structured data (esp. in a database). A list of items should be entered into a portal, or at least into a dedicated field.

  • Author
  • Newbies

Perhaps they should be entering tabs to indent a line, instead of modifying the ruler.

Thanks for your answer, comment. Using tabs however isn't going to work, because long lines / new lines are not automatically "tabbed in". If you scale a window you get even more problems with this method.

Basically you're right with your opinion that a text field is not good for structured data, but the customer has this exact requirement. Sometimes he wants to add just a note, sometimes he wants to add a structured list as well as some "normal" text lines above or underneath.

Maybe a WYSIWYG editor inside a web viewer and saving the generated HTML code in is the only way to do it. :-(

Maybe a WYSIWYG editor inside a web viewer and saving the generated HTML code in is the only way to do it. :-(

That could be worth exploring, esp. now with HTML 5.

Basically you're right with your opinion that a text field is not good for structured data, but the customer has this exact requirement. Sometimes he wants to add just a note, sometimes he wants to add a structured list as well as some "normal" text lines above or underneath.

I have done something similar with clients. I give them buttons that take a selection (in this case the indented parts) and calculate the HTML for them. I do this with BOLD, UNDERLINE, ITALIC, ORDERED LIST, UNORDERED LIST. And you can specify H1, H2, etc. or many other tags. You probably can work out what needs to be done for this client within the text field and give them the options they need. You can PREVIEW the calculated HTML in the Web Viewer if that helps them.

it's what they want, it's what they get... :)

Beverly

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.