Please or Register to create posts and topics.

Insert images inside the post

Page 1 of 3Next

Hi

how i can allow users upload images and insert it inside the posts like all other forums the users can upload and insert inline images inside the post not as attachment files or thumbnail, how can i add new button next to attachment name to insert it inside the Topic.

Uploaded files:
  • attach.jpg
  • attach1.jpg

Hello radone,

there is an image-button inside your editor which allows you to put a link to an image inside your post. This image will be inserted directly into the location where you have added it.

If you want to support the development of Asgaros Forum, you can leave a good review or donate. Thank you very much!

Hello Asgaros,

Thanks for your replay, this button allows image’s URL only, almost of users don’t like this way to upload them images and copy the line to insert it in the dialog , i hope you allow users can upload images from there computer and insert it inside the post, just need filebrowser  all other forums allow that, i know you don’t like to use third-party plugin so i asked you to add it as a button like add media button or add a button after attachment name, thank you again and i hope you think for allow users to upload and insert images inline.

the attach pic of how the image insert inside topics in phpbb fourm, i am sure its easy for you to do it and we hope you update the forum.

Uploaded files:
  • phpuplaod.jpg

Hi radone,

Add to functions.php :

function change_editor_settings($settings) {
  $settings['teeny'] = false;
  $settings['media_buttons'] = true;
  return $settings;
}

add_filter('asgarosforum_filter_editor_settings', 'change_editor_settings');

Set permissions

Hi Yworld,

Thanks for your help but the users in this case can see all uploaded media , is there anyway users can’t see the old uploaded media , i mean every user can see only his uploaded media .

There are plugins to restrict viewing images

i added this functions

//**===================
function change_editor_settings($settings) {
 $settings['teeny'] = false;
  $settings['media_buttons'] = true;
  return $settings;
}
add_filter('asgarosforum_filter_editor_settings', 'change_editor_settings');
//*****************

function add_my_media_button(){
 echo '<a href="'.get_site_url().'/wp-admin/media-new.php" class="button button-default">Insert Image</a>';
}
add_action('media_buttons', 'add_my_media_button');

it show insert image button with media button , what just i need to hide media button and when click insert image button its open a file browser dialog .

can you give me please a name of any plugin to  restrict viewing old media.

sorry for bothering you but its very important.

Uploaded files:
  • uploader.png

As an example WP Users Media

Not good idea, if users upload files them got error (Sorry, you are not allowed to attach files to this post.), and to fix this error i have to allow them to  edit_others_pages/posts,  edit_published_pages/posts , and that’s not good to allow forums users to edit posts and pages.

Hi Yworld,

i added this plugin (Remove Dashboard Access ) and now every thing is going ok but when i click the images on post its not enlarge .

Uploaded files:
  • uploading.png
Page 1 of 3Next