Discussion

Forum addition, textarea ?

1

Dan 2021-02-21 09:45

Hello,

can we have (or is it possible to) make a codebox/textarea for the postings ?

It would help to paste code in a clean way, separated from the comment.

In html it would be like this:

<textarea wrap=soft name="code" cols="80" rows="10" style="font-family: courier, sans-serif;" readonly="readonly"> Html "<input>" type attribute: button Defines a clickable button (mostly used with a JavaScript to activate a script) checkbox Defines a checkbox color Defines a color picker date Defines a date control </textarea>


G-9 2021-02-21 10:11

Cols and rows would be unreadable on iPhones :) Also we have markdown, as you can see my improved version of your work :D :

<textarea wrap=soft name="code" cols="80" rows="10" style="font-family: courier, sans-serif; color:white; background-color:#404040; border:5px outset black;" readonly="readonly"> Html "<input>" type attribute: button Defines a clickable button (mostly used with a JavaScript to activate a script) checkbox Defines a checkbox color Defines a color picker date Defines a date control </textarea>


Dan 2021-02-21 10:25

finetuning has to be done, ofc.
And maybe use some monospaced font ? :D


Timo 2021-02-21 12:05 (Edited)

In markdown code is shown with a monospace font. Click on "Attach..." to see more options, activate "Markdown" and then write you code like this:

```
IF A=0 THEN
PRINT "HELLO"
ELSE
PRINT "BYE"
END IF
```

(I wrote it with spaces, but you see them with markdown only.)


Timo 2021-02-21 12:05 (Edited)

And it will look like this:

IF A=0 THEN
  PRINT "HELLO"
ELSE
  PRINT "BYE"
END IF


was8bit 2021-02-21 14:15

@Timo, somehow i missed that.... great to know, thanks :)


G-9 2021-02-21 15:18

Fun fact : this tip is usable on WhatsApp !!


Dan 2021-02-21 16:44

Aha, great.


Log in to reply.