K
K
Kostya2015-05-05 21:41:24
HTML
Kostya, 2015-05-05 21:41:24

How to upload an image and paste the MarkDown code from the URL at the end of the textarea?

Firework!
There is input type="file" and textarea . The task is to upload an image to the server (without reloading the page, there is a PHP loader) and insert the MarkDown code ![Image.](/url/img.png) (together with the image URL) at the end of the textarea (preserving the previously written text). Is there any solution in JavaScript for example?
Thank you in advance for your help.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
G
Gram, 2015-05-05
@Kostyaan

Full of solutions. It's called "WYSIWYG editors" and they do a lot more. Here is a good list:
habrahabr.ru/post/129262

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question