Issue 46: Enhancement: Pass parameters like height and width to links that get picked up by the tag ‘class=nyroModal’.
Status:  Accepted
Owner: ----
Project Member Reported by william....@gmail.com, Jul 11, 2008
What steps will reproduce the problem?
1. N/A
2.
3.

What is the expected output? What do you see instead?
N/A

What version of the product are you using? On what operating system?
Version 1.2.8
Windows XP
IE 6

Please provide any additional information below.

I understand that the modal autosizes which is a very nice thing.  Now you 
don’t have to specify a size and toy around with getting it right.  But 
there are cases where you may want to specify a size like when an iframe 
is used.  Or when you want to make the box modal where it cannot be 
clicked off of.

Example from < http://nyromodal.nyrodev.com/> where this would be nice:
<a href="http://www.perdu.com/" class="nyroModal">Iframe Automatique via 
other hostname</a>

I understand I can alter the minHeight and minWidth settings or intercept 
the processHandler to detect modals of type : iframe and set a size but I 
wanted to be able to do it with out javascript.  Like how thickbox allows 
it.

Example from <http://jquery.com/demo/thickbox/>:
<a href="iframeModal.html?
placeValuesBeforeTB_=savedValues&TB_iframe=true&height=200&width=300&modal=
true" title="add a caption to title attribute / or leave blank" 
class="thickbox">Open iFrame Modal</a>

 
Jul 11, 2008
Project Member #1 william....@gmail.com
See attachment to my attempt.  It is pretty weak approach that I did but it got hte 
job done.  Could something like this be done, if not done already?

run nyromodal.html
patchattempt.zip
47.9 KB   Download
Jul 12, 2008
Project Member #2 nyro...@gmail.com
nyroModal isn't designed to work this way.
The reason for that is simple: I don't want to change the URl of a link only for
nyroModal.
As there's no possibility set parameter in the link URL, your method is great.

As it could be a future request, could I use your code sample in the wiki? (which I
need to enable and start write more example...)
Jul 13, 2008
Project Member #3 william....@gmail.com
Sure no problem.  Thanks for the reply.  I am gonna work it out a little better
because I want to be able to alter all the settings through the url so it works like
thickbox more.  I want to be able to use NYRO Modal in place of thickbox and that
seems to be the only thing that beat Nyro right now.
Jul 14, 2008
Project Member #4 william....@gmail.com
heres a better one i worked up. it just gets included in the header after the 
nryo*.js files
jquery.nyroModal.urlplugin-0.0.1.pack.js
2.2 KB   View   Download
Aug 11, 2008
Project Member #5 william....@gmail.com
fixed a bug where it was not setting minHeight but if you specify a height smaller 
than min height, min height takes over
jquery.nyroModal.urlplugin-0.0.1.pack.js
2.7 KB   View   Download
Jan 26, 2009
Project Member #6 nyro...@gmail.com
Hi William,
As you're a memeber of the nyroModal Project, could you post your code on the
download tab (if you can)?
If so, it could be nice if you could create a webpage to document your plugin.
Thansk anyway for your great work on it!
Jan 27, 2009
Project Member #7 william....@gmail.com
np, i will do it in the next couple of weeks. i have been very busy lately.
Jan 28, 2009
Project Member #8 nyro...@gmail.com
great, thanks!
Status: Accepted
Labels: -Type-Defect Type-Enhancement
Feb 4, 2009
Project Member #9 william....@gmail.com
i uploaded the version which contains a demo inside of it. the demo is quite poor but
i hope it gets the point accross. ill add support for more settings later.  please
remove the *.rar version off the download page. i cannot figure out how to remove it
my self. i uploaded the *.zip version cuz that seems to be the standard.
Feb 17, 2011
#10 rowils...@gmail.com
ese "jquery-1[1].2.6.pack.js" me crea bastante conflicto
Feb 17, 2011
#11 rowils...@gmail.com
Regards, something simple. All "iframes" open with the same size
Here is a bad example of what I need, and believe me problems nyromodalsettings
//////////////
<script type="text/javascript">
$(function() {
  $('.nyroModal2').nyroModal();
  $.nyroModalSettings({width:900,height:500});   
});
</script>

<a href="1_1.html" target="_blank" class="nyroModal2">Submenu 1</a>
/////////////////

help me please!!!
thanks in advance. 
Jun 22, 2011
#12 lorenzo....@gmail.com
Many thanks William, it saved my day :)