2
votes

yes its a joomla question and im sorry to annoy but asking on the joomla forum takes forever or gets ignored.

Im really trying to find where i can modify the iframe modal box to be larger than the default.

When you go into article edit mode and choose to insert an intro image or full article image theres a select input field button. When select is clicked it opens a modal window that is quite small. I wanted to apply a full screen modal to it or at least make it 960x600px as opposed to 800x500px

But the thing is that the select button is generated by an xml file with fields in it.

The xml must be calling a function somewhere that generates the html for that button based on type=media inside the xml file but i cant seem to find where that function or code snippet is.

I just want the modal for selecting an image to be larger, it seems crazy not to make such a thing bigger instead of having horizontal and vertical scroll bars.

the file im referring to in joomla 2.5 for the xml fields:

line 540 and 572 ( Thats the two instances of intro image and full image )

administrator/components/com_content/models/forms/article.xml

That is the file where the image intro and full article image select fields are located.

then this file generates the output of them:

line 203 ( It does a foreach loop to grab the xml fields )

administrator/components/com_content/views/article/tmpl/edit.php

But i cant for the life of me figure out where this part in the html output on the article edit mode in the joomla admin is generated:

<div class="button2-left">
<div class="blank">

<a class="modal" title="Select" href="index.php?option=com_media&amp;view=images&amp;tmpl=component&amp;asset=34&amp;author=&amp;fieldid=jform_images_image_intro&amp;folder=news" rel="{handler: 'iframe', size: {x: 800, y: 500}}"> Select</a>

</div>
</div>

Thanks in advance john

2
You might be interested in supporting a Joomla version of StackOverflow area51.stackexchange.com/proposals/34294/joomla-answersTryHarder

2 Answers

4
votes

The file you are looking for is:

libraries/joomla/form/fields/media.php

line 121:

. ' rel="{handler: \'iframe\', size: {x: 800, y: 500}}">';
2
votes

Since it appears that key details of the accepted answer to the original poster's question occurred via direct communication (based on comments in the first answer), for me it was necessary for me to search around for more information on where to change the sizing of modal windows—especially since it seems that the sizing of various popups are defined in different places.

So, in the hopes that this is helpful to others in similar circumstances, I'm leaving what information I was able to find out about which files have to do with modal behavior, appearance, and configuration.

Here's how the list is organized:

  • All the files in which I was able to find modal settings defined (or items that seemed closely related to modal appearance and/or behavior)
  • The line number on which relevant settings/configuration occurs (as of 2.5.6)
  • Quotes of any nearby text that might provide insight to where/how that particular modal is being used (when trying to determine if this controls the modal you want to change), or a note of any information that seems relevant/helpful

And here's the list itself:

  • \administrator\components\com_contact\elements\contact.php : 53 “COM_CONTENT_SELECT_A_CONTACT"

  • \administrator\components\com_contact\models\fields\modal\contacts.php : 69 “COM_CONTACT_CHANGE_CONTACT_BUTTON"

  • \administrator\components\com_content\elements\article.php : 55 “COM_CONTENT_SELECT_AN_ARTICLE"

  • \administrator\components\com_content\models\fields\modal\article.php : 78 “COM_CONTENT_CHANGE_ARTICLE"

  • \administrator\components\com_menus\models\fields\menutype.php : 71

  • \administrator\components\com_menus\views\item\tmpl\edit_modules.php : 46 “COM_MENUS_EDIT_MODULE_SETTINGS"

  • \administrator\components\com_menus\views\menus\tmpl\default.php : 113 “COM_MENUS_EDIT_MODULE_SETTINGS"

  • \administrator\components\com_modules\models\fields\moduleposition.php : 77 “COM_MODULES_CHANGE_POSITION_TITLE"

  • \administrator\components\com_newsfeeds\models\fields\modal\newsfeeds.php : 81 “COM_NEWSFEEDS_CHANGE_FEED_BUTTON"

  • \administrator\modules\mod_multilangstatus\tmpl\default.php : 14 “MOD_MULTILANGSTATUS"

  • \components\com_content\views\article\tmpl\default_links.php : 65
    “class="content-links"”

  • \components\com_weblinks\views\category\tmpl\default_items.php : 110

  • \libraries\cms\form\field\user.php : 94
    "JLIB_FORM_CHANGE_USER"

  • \libraries\joomla\html\toolbar\button\popup.php : 53
    This looks like it may be the php file setting up the base parameters & such, which is invoked and built off of everywhere else.

  • \media\system\js\modal-uncompressed.js : entire file
    Contains the interactive (client-side) logic for modal usage (note that Joomla modal windows are SqueezeBox derived).

  • \media\system\js\modal.js : entire file
    Same content as the file above, just minified.

  • \plugins\user\profile\fields\tos.php : 81
    As far as I can see, this seems to be used for displaying terms of service to end users—probably if you created your own TOS that your users need to be aware of and agree to.