Textpattern CMS support forum

You are not logged in. Register | Login | Help

#41 2017-11-23 13:31:44

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

Hello,

it’s been a long time, but AFAIR there is no limitation in the plugin itself. The browser and/or the server can limit the number of simultaneously uploaded files, though, but I don’t know how to fix it, sorry.


etc_[ query | search | pagination | date | tree | cache ]

Offline

#42 2017-11-23 15:43:04

momono-02
New Member
From: Netherlands
Registered: 2016-06-09
Posts: 4
Website

Re: [feedback] Image upload directly in the write tab

Thanks man! I already persuaded my client to limit the amount of photos to upload ?
He was kind of eager to upload as much photos as possible.

Offline

#43 2018-11-04 20:39:47

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

I have slightly modified abc_article_image to enable drag-drop uploaded article images on textareas support. Nothing fancy, just allows you to insert <txp:image /> tag at the drop cursor position. Requires txp 4.7.

# Name: abc_article_image v0.5 
# Type: Admin/AJAX plugin
# 
# Author: 
# URL: 
# Recommended load order: 5

# .....................................................................
# This is a plugin for Textpattern CMS - http://textpattern.com/
# To install: textpattern > admin > plugins
# Paste the following text into the 'Install plugin' box:
# .....................................................................

YToxMTp7czo0OiJuYW1lIjtzOjE3OiJhYmNfYXJ0aWNsZV9pbWFnZSI7czo2OiJhdXRob3Ii
O3M6MDoiIjtzOjEwOiJhdXRob3JfdXJpIjtzOjA6IiI7czo3OiJ2ZXJzaW9uIjtzOjM6IjAu
NSI7czoxMToiZGVzY3JpcHRpb24iO3M6MDoiIjtzOjQ6ImNvZGUiO3M6NjIzNzoiZ2xvYmFs
ICRldmVudDsNCg0KaWYoJGV2ZW50ID09ICdhcnRpY2xlJyAmJiBoYXNfcHJpdnMoJ2ltYWdl
LmVkaXQub3duJykpDQp7DQoJcmVnaXN0ZXJfY2FsbGJhY2soJ2FiY19maWxlX3VwbG9hZCcs
ICdhcnRpY2xlX3VpJywgJ2FydGljbGVfaW1hZ2UnKTsNCglyZWdpc3Rlcl9jYW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50aHVtYi5waHAnOw0K
CSRpZHMgPSBhcnJheSgpOw0KCSRmaWxlcyA9IFR4cDo6Z2V0KCdcVGV4dHBhdHRlcm5cU2Vy
dmVyXEZpbGVzJyktPnJlZmFjdG9yKCRfRklMRVNbJ2FydGljbGVfZmlsZSddKTsNCg0KCWZv
cmVhY2ggKCRmaWxlcyBhcyAkZmlsZSkgew0KCQkkbWV0YSA9IGFycmF5KCdhbHQnID0+ICRm
aWxlWyduYW1lJ10pOyAgLy9jYXB0aW9uLCBjYXRlZ29yeQ0KCQkkaW1nX3Jlc3VsdCA9IGlt
YWdlX2RhdGEoJGZpbGUsICRtZXRhKTsNCg0KCQlpZiAoaXNfYXJyYXkoJGltZ19yZXN1bHQp
KSB7DQoJCQlsaXN0KCRtZXNzYWdlLCAkaWQpID0gJGltZ19yZXN1bHQ7DQoJCQkkaWRzW10g
PSAkaWQ7DQoJCX0NCgl9DQoNCgkkR0xPQkFMU1snSUQnXSA9IGludHZhbCgkcnNbJ0lEJ10p
Oy8vIHNpYyENCgkkaWRzID0gaW1wbG9kZSgnLCcsICRpZHMpOw0KCSRpZHMgPSBpbXBsb2Rl
KCcsJywgZG9fbGlzdF91bmlxdWUoJHJzWydJbWFnZSddLicsJy4kaWRzKSk7DQoJc2FmZV91
cGRhdGUoJ3RleHRwYXR0ZXJuJywgIkltYWdlPSciLmRvU2xhc2goJGlkcykuIiciLCAnSUQ9
Jy4kR0xPQkFMU1snSUQnXSk7DQp9IjtzOjQ6InR5cGUiO3M6MToiNCI7czo1OiJvcmRlciI7
czoxOiI1IjtzOjU6ImZsYWdzIjtzOjE6IjAiO3M6NDoiaGVscCI7czowOiIiO3M6MzoibWQ1
IjtzOjMyOiJhY2M5ZGE0ODQ1MTZhN2U3ZmI0ZTM1NTA3ZjAzYzUzZSI7fQ==

etc_[ query | search | pagination | date | tree | cache ]

Offline

#44 2018-11-08 10:29:19

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

Version 0.6: now with drag image on article body to upload and insert.

# Name: abc_article_image v0.6 
# Type: Admin/AJAX plugin
# 
# Author: 
# URL: 
# Recommended load order: 5

# .....................................................................
# This is a plugin for Textpattern CMS - http://textpattern.com/
# To install: textpattern > admin > plugins
# Paste the following text into the 'Install plugin' box:
# .....................................................................

YToxMTp7czo0OiJuYW1lIjtzOjE3OiJhYmNfYXJ0aWNsZV9pbWFnZSI7czo2OiJhdXRob3Ii
O3M6MDoiIjtzOjEwOiJhdXRob3JfdXJpIjtzOjA6IiI7czo3OiJ2ZXJzaW9uIjtzOjM6IjAu
NiI7czoxMToiZGVzY3JpcHRpb24iO3M6MDoiIjtzOjQ6ImNvZGUiO3M6ODQ1MToiZ2xvYmFs
ICRldmVudDsNCg0KaWYoJGV2ZW50ID09ICdhcnRpY2xlJyAmJiBoYXNfcHJpdnMoJ2ltYWdl
LmVkaXQub3duJykpDQp7DQoJcmVnaXN0ZXJfY2FsbGJhY2soJ2FiY19maWxlX3VwbG9hZCcs
ICdhcnRpY2xlX3VpJywgJ2FydGljbGVfaW1hZ2UnKTsNCglyZWdpc3Rlcl9jYWxsYmFjaygn
YWJjX2ZpbGVfc2F2ZScsICdhcnRpY2xlX3Bvc3RlZCcpOw0KCXJlZ2lzdGVyX2NhbGxiYWNr
KCdhYmNfZmlsZV9zYXZlJywgJ2FydGljbGVfc2F2ZWQnKTsNCglyZWdpc3Rlcl9jYWxsYmFj
aygnYWJjX2ZpbGVfanMnLCAnYWRtaW5fc2lkZScsICdib2R5X2VuZCcpOw0KfQ0KDQpmdW5j
dGlvbiBhYmNfZmlsZV9qcygkZXZlbnQsICRzdGVwKSB7DQplY2hvIHNjcmlwdF9qcygnDQpm
dW5jdGlvbiByZWFkZmlsZXMoZmlsZXMsIGlucHV0KSB7DQp2YXIgZm9ybURhdGEgPSBuZXcg
Rm9ybURhdGEoKSwgY291bnQgPSAwOw0KDQpmb3IgKHZhciBpID0gMDsgaSA8IGZpbGVzLmxl
bmd0aDsgaSs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YWdlPSciLmRvU2xhc2goJGlkcykuIiciLCAnSUQ9
Jy4kR0xPQkFMU1snSUQnXSk7DQp9IjtzOjQ6InR5cGUiO3M6MToiNCI7czo1OiJvcmRlciI7
czoxOiI1IjtzOjU6ImZsYWdzIjtzOjE6IjAiO3M6NDoiaGVscCI7czowOiIiO3M6MzoibWQ1
IjtzOjMyOiI0MjAwNzk3ZDgxNzA1NDE4ZTQ2MzZhMTlhZjdmMGU1OSI7fQ==

etc_[ query | search | pagination | date | tree | cache ]

Offline

#45 2018-11-09 12:47:53

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

Version 0.7 allows you to define how images should be imported via Preferences/Admin/abc_file_image pref (disable/enable the plugin to trigger the prefs creation). Examples:

  • <txp:image id="{#}" /> (default): insert one image tag per image.
  • <txp:images id="{##}" form="galery" />: insert one common images tag for uploaded images.

Enjoy!

# Name: abc_article_image v0.7.2 
# Type: Admin/AJAX plugin
# 
# Author: 
# URL: 
# Recommended load order: 5

# .....................................................................
# This is a plugin for Textpattern CMS - http://textpattern.com/
# To install: textpattern > admin > plugins
# Paste the following text into the 'Install plugin' box:
# .....................................................................

YToxMTp7czo0OiJuYW1lIjtzOjE3OiJhYmNfYXJ0aWNsZV9pbWFnZSI7czo2OiJhdXRob3Ii
O3M6MDoiIjtzOjEwOiJhdXRob3JfdXJpIjtzOjA6IiI7czo3OiJ2ZXJzaW9uIjtzOjU6IjAu
Ny4yIjtzOjExOiJkZXNjcmlwdGlvbiI7czowOiIiO3M6NDoiY29kZSI7czo5OTg3OiJnbG9i
YWwgJGV2ZW50Ow0KDQpyZWdpc3Rlcl9jYWxsYmFjaygnYWJjX2ZpbGVfaW5zdGFsbCcsJ3Bs
dWdpbl9saWZlY3ljbGUuYWJjX2FydGljbGVfaW1hZ2UnKTsNCg0KaWYoJGV2ZW50ID09ICdh
cnRpY2xlJyAmJiBoYXNfcHJpdnMoJ2ltYWdlLmVkaXQub3duJykpDQp7DQoJ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2VfZGF0YSgkZmlsZSwgJG1ldGEpOw0KDQoJ
CWlmIChpc19hcnJheSgkaW1nX3Jlc3VsdCkpIHsNCgkJCWxpc3QoJG1lc3NhZ2UsICRpZCkg
PSAkaW1nX3Jlc3VsdDsNCgkJCSRpZHNbXSA9ICRpZDsNCgkJfQ0KCX0NCg0KCSRHTE9CQUxT
WydJRCddID0gaW50dmFsKCRyc1snSUQnXSk7Ly8gc2ljIQ0KCSRpZHMgPSBpbXBsb2RlKCcs
JywgJGlkcyk7DQoJJGlkcyA9IGltcGxvZGUoJywnLCBkb19saXN0X3VuaXF1ZSgkcnNbJ0lt
YWdlJ10uJywnLiRpZHMpKTsNCglzYWZlX3VwZGF0ZSgndGV4dHBhdHRlcm4nLCAiSW1hZ2U9
JyIuZG9TbGFzaCgkaWRzKS4iJyIsICdJRD0nLiRHTE9CQUxTWydJRCddKTsNCn0iO3M6NDoi
dHlwZSI7czoxOiI0IjtzOjU6Im9yZGVyIjtzOjE6IjUiO3M6NToiZmxhZ3MiO3M6MToiMCI7
czo0OiJoZWxwIjtzOjA6IiI7czozOiJtZDUiO3M6MzI6IjA1MGE4MWYyOTExMzE1OTY3Njdm
Y2ZmNThiZTczNmM1Ijt9

etc_[ query | search | pagination | date | tree | cache ]

Offline

#46 2018-11-09 13:02:24

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 8,631
Website

Re: [feedback] Image upload directly in the write tab

etc wrote #315128:

Version 0.7 allows you to define how images should be imported

Sounds more like smd_imagery with every release ;)

I’ll check this out, thank you for writing it.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#47 2018-11-10 09:29:37

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

Bloke wrote #315129:

Sounds more like smd_imagery with every release ;)

Version 0.7.1: uses thumbnails if present :-)


etc_[ query | search | pagination | date | tree | cache ]

Offline

#48 2019-04-30 12:56:54

zenman
Member
Registered: 2017-08-28
Posts: 36
Website

Re: [feedback] Image upload directly in the write tab

etc wrote #315138:

Version 0.7.1: uses thumbnails if present :-)

I am using the plugin currently on txp 4.6. Is it possible to select images from the uploaded ones like with bot_image_upload?

Offline

#49 2019-04-30 22:18:19

etc
Developer
Registered: 2010-11-11
Posts: 3,159
Website

Re: [feedback] Image upload directly in the write tab

zenman wrote #317834:

Is it possible to select images from the uploaded ones like with bot_image_upload?

It depends on what you mean by “uploaded ones”. No if they just have been uploaded via Write tab (all will be added to the current article, but this seems logical). Yes if you mean previously uploaded images — click on Add link to open the pane.


etc_[ query | search | pagination | date | tree | cache ]

Offline

#50 2019-05-01 06:34:20

zenman
Member
Registered: 2017-08-28
Posts: 36
Website

Re: [feedback] Image upload directly in the write tab

etc wrote #317838:

It depends on what you mean by “uploaded ones”. No if they just have been uploaded via Write tab (all will be added to the current article, but this seems logical). Yes if you mean previously uploaded images — click on Add link to open the pane.

yes, i mean “previously uploaded”.
for now whether i check Add or not, it is uploading a new image to an article. it does not open the pane.

!https://buddha.by/images/944.png!

Offline

Board footer

Powered by FluxBB