The Joomla! Forum ™





Post new topic Reply to topic  [ 7 posts ] 
Author Message
PostPosted: Wed Apr 02, 2008 7:55 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
I've created a Property Sales component, and wish to using the Media Manager popup to allow the user to select a thumbnail and full image of the required property. I've copied the code from the Editor to open the popup, but when I select the image, it populates the Editor window rather than the input form that I have supplied.

Code:
<tr>
                     <td>
                        <label for="thumbnailImage"><?php echo JText::_( 'Thumbnail Image' ) ?></label>
                     </td>
                     <td>
                        <input id="thumbnailImage" name="thumbnailImage" value="<?php echo $row->thumbnailImage; ?>" />
                        <a class="modal-button" rel="{handler: 'iframe', size: {x: 570, y: 400}}" href="index.php?option=com_media&view=images&tmpl=component&e_name=thumbnailImage" title="Image">Image</a>
                     </td>
                  </tr>


How can I use this to populate the URL into my input box, without hacking the javascript for the popup? Is there a better way to do this?


Top
 Profile  
 
PostPosted: Fri Apr 04, 2008 7:56 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
Can anyone help on this or suggest a suitable plugin?


Top
 Profile  
 
PostPosted: Thu Apr 10, 2008 10:31 am 
Joomla! Intern
Joomla! Intern

Joined: Fri Nov 04, 2005 9:23 am
Posts: 95
http://www.phpletter.com/

The Ajax File / Image manager is good and can be tied into your components with a little reading through their forums. Tie it into the Editor or launch it to populate a form field with the path to the file and save that.


Top
 Profile  
 
PostPosted: Thu Apr 10, 2008 1:19 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
Super. Thanks for that I'll take a look.


Top
 Profile  
 
PostPosted: Mon Apr 14, 2008 12:09 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
Would I need to install the component again or is there a way to hook in to the existing functionality deployed with FCK/TinyMCE? These seem coded to use the Editors rather than populate a specific form field. Can you give me any pointers on where to look?


Top
 Profile  
 
PostPosted: Tue Apr 15, 2008 8:11 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
I found a solution to this at

http://groups.google.com/group/joomla-d ... dca7eec259

Essentially you pass through a parameter (say noeditor=1) and then perform the relevant action and return the URL to the field. Nice.


Top
 Profile  
 
PostPosted: Tue May 06, 2008 12:04 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Jan 23, 2008 5:35 pm
Posts: 139
Update:

Using this solution works fine in Firefox, but there seems to be an Internet Explorer problem whereby you get an Unspecified Error when opening the popup window and then a 'can't execute code from a freed script joomla' error when choosing an image. This appears to be an IE only issue. Does anyone have an idea of how I might fix this?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 



Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group