Keyword

[SOLVED] Image upload problems in frontend editor

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago - 11 years 1 week ago #129209 by Diego Schmidt
Hello, thanks in advance for your time :P. I'm having problems with Tinymce and image upload / browse server, i can't upload an image and when i navigate the server all folders are shown as locked up, when i change to JCE there is no problem at all. Any idea? . I'm using Joomla! 3.3 and k2 2.6.9

Please Log in or Create an account to join the conversation.

More
11 years 1 week ago #129210 by Lefteris
Replied by Lefteris on topic Re: Tinymce image upload problems
Hi. Are you talking about the editor buttons or the buttons that K2 provides ( in "Image", "Media" etc. tabs ) ?

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago #129211 by Diego Schmidt
Replied by Diego Schmidt on topic Re: Tinymce image upload problems
Sorry for not including that info. I'm talking about the tinymce image tab in the frontend editor

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago #129212 by Diego Schmidt
Replied by Diego Schmidt on topic Re: Tinymce image upload problems
Or is it the k2 image tab? on the frontend editor, I'm not sure if it is tinymce or k2 core, excuse my ignorance about the topic

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago #129213 by Diego Schmidt
Replied by Diego Schmidt on topic Re: Tinymce image upload problems
It seems that im talking about the k2 tab, nothing related to tinymce

Please Log in or Create an account to join the conversation.

More
11 years 1 week ago #129214 by Lefteris
Replied by Lefteris on topic Re: Tinymce image upload problems
Check the browser console for any errors after you click the "browse server" button.

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago #129215 by Diego Schmidt
Replied by Diego Schmidt on topic Re: Tinymce image upload problems
In Firefox i get this error.

El uso de getAttributeNode() es obsoleto. Use getAttribute() en su lugar. mootools-core.js:108
load: temporizador iniciado elfinder.min.js:12
El uso de getPreventDefault() es obsoleto. Use defaultPrevented en su lugar. jquery.min.js:2

Please Log in or Create an account to join the conversation.

More
11 years 1 week ago #129216 by Lefteris
Replied by Lefteris on topic Re: Tinymce image upload problems
I just tested and had no issues. Is this affected by the editor you are using? Or you get the same results on both editors?

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago - 11 years 1 week ago #129217 by Diego Schmidt
Replied by Diego Schmidt on topic Re: Tinymce image upload problems
Same results with any editor. This only happens in the frontend, the backend k2 media manager works fine.
This is what i see when hit the Browse button in the image tab.

Please Log in or Create an account to join the conversation.

More
11 years 1 week ago #129218 by Lefteris
Replied by Lefteris on topic Re: Tinymce image upload problems
This is normal. Uploading using the media manager is disabled in front-end.

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 1 week ago #129219 by Diego Schmidt
Replied by Diego Schmidt on topic k2 image tab frontend upload
So there is nothing i can do about it? If i turn on JCE there is no problem in uploading from the frontend but i like the k2 image tab more.

Please Log in or Create an account to join the conversation.

More
11 years 6 days ago #129220 by Lefteris
Replied by Lefteris on topic Re: k2 image tab frontend upload
JCE is a different extension. K2 media manager is always set to read-only mode when used in front-end.

Please Log in or Create an account to join the conversation.

  • Diego Schmidt
  • Diego Schmidt's Avatar Topic Author
  • Offline
  • New Member
More
11 years 6 days ago #129221 by Diego Schmidt
Replied by Diego Schmidt on topic Re: k2 image tab frontend upload
Ok then, that makes the k2 image tab totally useless in front end. Thanks for the support.

Please Log in or Create an account to join the conversation.

More
11 years 6 days ago #129222 by Lefteris
Replied by Lefteris on topic Re: k2 image tab frontend upload
You are welcome.

Please Log in or Create an account to join the conversation.

More
10 years 7 months ago #129223 by MessageDJ
Replied by MessageDJ on topic Re: Image upload problems in frontend editor
if you really like to add this feature (like i did)

open file:
/administrator/components/com_k2/controllers/media.php

search for: (around line 71)
			// Read only access for front-end. Full access for administration section.
			switch($attr)
			{
				case 'read' :
					return true;
					break;
				case 'write' :
					return ($mainframe->isSite()) ? false : true;
					break;
				case 'locked' :
					return ($mainframe->isSite()) ? true : false;
					break;
				case 'hidden' :
					return false;
					break;
			}

		}

		if ($mainframe->isAdmin())
		{
			$permissions = array(
				'read' => true,
				'write' => true
			);
		}
		else
		{
			$permissions = array(
				'read' => true,
				'write' => false
			);

change to:
			// Read only access for front-end. Full access for administration section.
			switch($attr)
			{
				case 'read' :
					return true;
					break;
				case 'write' :
					return ($mainframe->isSite()) ? true : true;
					break;
				case 'locked' :
					return ($mainframe->isSite()) ? true : true;
					break;
				case 'hidden' :
					return false;
					break;
			}

		}

		if ($mainframe->isAdmin())
		{
			$permissions = array(
				'read' => true,
				'write' => true
			);
		}
		else
		{
			$permissions = array(
				'read' => true,
				'write' => true
			);

Remember, this is a hack, i have not checked anything in safety and security, use it for your own risk.

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum