Knowledge Base support case for Likno Web Modal Windows Builder, abstracted and stripped of all user’s private info.

Support Case Month: March 2012
Initial Email Subject: Different results in IE browsers

Initial Email From: Dave

I have just started using your software, so I am very new.

I used the Web Modal Window builder to create a popup window. I am very pleased with the results.

However, I noticed that in Internet Explorer on some computers it has strange effects. On some computers the popup will appear, but then it won't go away; not with the escape key, with clicking the close button or by clicking outside the window. On other computers it opens the popup HTML in a new window.

Is there something I am missing? Any help would be appreciated.

I haven't noticed any similarities except that the problems exist in Internet Explorer. I have used versions 7, 8 and 9 on Windows XP and 7. Firefox seems to have no problem. Neither does Chrome.

Reply From: Likno Customer Support

Hello,

It seems that the problem originates from the (non-Likno) menu that you have. Specifically, this menu uses a very old version of jQuery, which produces JavaScript errors in IE and in turn blocks the correct execution of our own library (which uses a newer version of jQuery).

Please check your page and try changing this:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>


Into this:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>

Let me know if this fixed the problem. Also note that in IE you may need to delete the “Temporary Internet Files” before you see the changes.

Best Regards,

Likno Customer Support

www.likno.com

 

Tags: , , , , , , , , , , , , , , , ,

 

Knowledge Base support case for Likno Web Modal Windows Builder, abstracted and stripped of all user’s private info.


Initial Email From:
Stanley
Initial Email Subject: Help for Likno Web Modal Windows Builder
Support Case Month: March 2012

Dear Support,

I like the Modal Windows to display external web page with auto resize (this is the page to display: http://www.pcmaster.com.sg/CardScan_feature.html) when user click on the word something like "Click for product comparison".

Please advise me how to do it.

Thank you in advance for helping this.

Regards,

Stanley


Reply From:
Likno Customer Support

Dear Stanley,

I am afraid that the “auto” size does not work for external pages. Other than that, you can open the external page using the following values:

clip_image002

To call the modal from a specific link you need to add the modal name like so:

<a href="javascript:void(0)" target="Modal_Window_1">Click for product comparison</a>

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!


Reply From:
Stanley

Dear Support,

Is there any way to pass the parameter (link and modal size) to modal windows if I use the same window modal for different link (Single sheet) instead of creating each modal for each external link. As for modal size, though it can be set to percentage but it does not work in IE for height in %.

Something like lytebox:

<a href="cardScan_feature.html" class="lytebox" data-lyte-options="width:96% height:100%">Click</a> for product comparison.

<a href="office2010.html" class="lytebox" data-lyte-options="width:96% height:100%">Click</a>for Office 2010 comparison.

Regards,

Stanley


Reply From:
Likno Customer Support

Dear Stanley,

You can do this too, but this can only be done using the API. In this case, it would be best to create a separate JavaScript function that accepts these parameters and opens the appropriate modal window.

Here is an example of how this would work:

function openModal(url, w, h) {
    Modal_Window_1({bodySource:"<div externalUrl='"+url+"'/>",containerCss:{width:w, height:h});
}

Then this is an example of two links:

<a href="javascript:void(0)" onclick="openModal('compare1.html',500,400);">Click for product1 comparison</a>

<a href="javascript:void(0)" onclick="openModal('compare2.html',400,300);">Click for product2 comparison</a>

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!


Reply From:
Stanley

Dear Support,

Can you take a look at this link at my testing site : {LINK REMOVED}, somewhere at the bottom of the "Description" you can see "Click here to see product features and comparison".

I use this statement to call external link: 

<a href="#" target="cardScan">Click hear to see product features and comparison.

Would you please teach me how to apply your method to this modal window.

Regards,

Stanley


Reply From:
Likno Customer Support

Dear Stanley,

The logic is the same as the one I described in my previous email. If you want this link to also control which page will open and the width of the window, you need to first add the following code in the <head></head> of your page:

<script>

function openModal(url, w, h) {
    cardScan({bodySource:"<div externalUrl='"+url+"'/>",containerCss:{width:w, height:h}});
}

</script>

Then you need to change your link to the following:

<a href="havascript:void(0);" onclick="openModal('/CardScan_feature.html',800,400);">Click Here</a>

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!


Reply From:
Stanley

Dear Support,

May I know is there any way to put % for width and height? (the reason why I like to switch from lytebox to model window is because of % for width and height in lytebox has compatibility issue with IE)

Regards,

Stanley 


Reply From:
Likno Customer Support

Hello,

Yes, on the link values, use something like this:

<a href="havascript:void(0);" onclick="openModal('/CardScan_feature.html','50%','40%');">Click Here</a>

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!


Reply From:
Stanley

Dear Support,

1) I've tried that but did not work (passing width and height in %)

2) How to pass the title to each model window? (it has the same title for each model)

Regards,

Stanley


Reply From:
Likno Customer Support

Hello,

I just tried it in your online page, and the size worked fine…

If you want to also change the title, then you need to add this too in the function..

The link should be:

openModal('/CardScan_feature.html','80%','40%','the title');

and the function:

function openModal(url, w, h, t) {
        cardScan({bodySource:"<div externalUrl='"+url+"'/>",containerCss:{width:w, height:h},header:{text:t}});
}

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!

 

Tags: , , , ,

 

Knowledge Base support case for Likno Web Modal Windows Builder, abstracted and stripped of all user’s private info.


Initial Email From:
Beverly
Initial Email Subject: ESC key not closing modal overlay in IE9 or Chrome but is in Firefox - using build 246
Support Case Month: March 2012

Here is my test page: {LINK REMOVED}

Clicking on the Chris Bruno, Marketing Manager or the email address opens the modal window coded in Web Modal Windows Builder.

But even though I have the ESC option selected, the ESC key does not close the window in IE9 or chrome (or Opera but few of our users browse with that browser).  Can you help me get this working in those browsers?  It works correctly in firefox and safari.  Clicking on the overlay closes the modal window in all browsers as does clicking the close button.

I tried this with all 3 methods of opening the modal window (target, ID and on click) but they all behave the same.

I attached the files I thought might help sort this out.

Thanks for your help.


Reply From:
Likno Customer Support

Hello,

This is actually an expected behavior. When your content is an “external page” it appears as an iframe within your modal window. In this case and when the focus is in the iframe, it is not possible to capture any keyboard events, so the Esc does not work. This is also described in the help:

clip_image001

The difference you see in the behavior of IE9 and Firefox is that in IE9 the focus automatically goes in the iframe as soon as the modal opens. Specifically the cursor goes into the “First Name” field. From what I’ve seen, this is done by a Form script in the external page but it seems it does not work as expected in Firefox.

However you can be certain of one thing in all browsers: if the focus is in the iframe then Esc won’t work, if the focus is in the main page then Esc will work.

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!


Reply From:
Beverly

Thanks for helping me understand this issue.

Is there any way to set the focus on the iframe once it is launched from the clicked link?  Seems like that might make the ESC key recognized.  
One modal program suggested using 
setTimeout(setFocusThickboxIframe, 100);

Another one suggested this for a similar problem in safari:

if (!safari) {
myIframe.focus();
}

The external pages in question are php forms so it looks like I can't embed them so trying to think "outside of the box" without much expertise in the area (always dangerous).


Reply From:
Likno Customer Support

Hello,

Indeed your external pages will have to stay …external! It is not possible to add a PHP page any other way. Unfortunately this means that the ESC key will not work as expected.

In order for this to work, the focus needs to be on the parent page and not the iframe. However, when a user clicks in a form field, the focus is inside the iframe. You should not try to remove it from there programmatically, as then the user will not be able to write in the field!

The only way to reliably make the ESC key work in such a case would be to manually code it in the inner page. You can try adding the following code in your PHP page to see if this fixes things:

<script>
    document.onkeypress = function (e) {
        if (e.keyCode == 27) { // ESC 
            top.contactinfocanada.close ();
        }
    }
</script>

Note that the above code is “out of my head” and has not been tested – it is intended to direct you in the correct direction. Before using it in an “official” page, please make sure that it works at least in IE and Firefox. Also note that this will not work at all if the inner page is not coming from the *exact* same domain as the parent page. For this purpose “domain.com” and “www.domain.com” are considered different domains.

Regards,
Kostas
Likno Customer Support
www.likno.com
Powerful javascript menus (CSS menus/drop-down menus/sliding menus), web trees, buttons, tabs, modals, tooltips, accordions, scrollers, designs for your websites!

 

Tags: , , , , , , , , , , ,

 

Hello,

We have released a new version of Likno Web Modal Windows Builder: Build #246

Check out What's New:

- New feature: "Make certain forms show their results in a specified Modal Window". It is used so that the user views the results of a form (i.e. the content after the form's "submit" button is pressed) into a modal window opening above the page.

Modal Window Form Results

- Fixed an issue with the "Do not re-open on same user" option when the "Opens on Page Load" was selected: it caused the "Do not re-open" to be active when it should not.

- Made some interface improvements.

 

You can download the latest version at:

http://www.likno.com/jquery-modal-windows/download.php

 

Tags: , , , , , , , , , ,

 

Hello,

We have released a new version of Likno Web Modal Windows Builder: Build #244

Check out What's New:

- New feature: the "Do not reopen on same user" action can now be triggered by the user too, through a special checkbox that you add to the modal window.

Modal Window No Reopen

- Added "Example 20 (no reopen)", which demonstrates this new feature.

Modal Window No Reopen Example

- Made the "Opens on Mouse Out of Page (top side only) visible in the preview.

- Fixed an issue in framed websites, where the closing animation did not work properly due to a jQuery bug.

- Fixed an issue where custom animation effects were combined with the project-wide effects.

 

You can download the latest version at:

http://www.likno.com/jquery-modal-windows/download.php

 

Tags: , , , , , , , , , ,

 


© 2009-2012 Likno Blog – Drop-Down Menus, Javascript Menus, CSS Menus