This is a migrated thread and some comments may be shown as answers.

FireFox - Javascript problem

10 Answers 147 Views
Window
This is a migrated thread and some comments may be shown as answers.
Bader
Top achievements
Rank 1
Bader asked on 05 Jan 2011, 12:09 PM
Hello,

I have a problem with opening the radwindow control in firefox browser (It is working in all other browsers).

here is my java script code which opens the radwindow control in full width and full height:
function UseMainRadWindow() {
            var width = screen.width;
            var height = screen.height;
            var mapPosition = '<%= Session["MapPositionSession"].ToString() %>'
            var ctgrsLst = document.getElementById('ResultsLabel').innerText; 
            var oWnd = $find("<%= RadWindow1.ClientID %>");
            oWnd.show();
            oWnd.setUrl("Pages/FullMaps/MainMap.aspx?width=" + width.toString() + "&height=" + height.toString() + "&mapPosition=" + mapPosition.toString() + "&ctgrsLst=" + ctgrsLst.toString().replace(" & ", "."));
            oWnd.maximize();
        }

The above javascript code is placed on a MainMapWebUserControl.ascx, and "ResultsLabel" is placed on Default.aspx which calls MainMapWebUserControl.ascx.

Note, I tried the above code in other browsers and it is working fine whithout problems, but unfortunatily it is not working in firefox browser.
Please view the attached images: 1.jpg is the result on firefox and 2.jpg is the result on other browsers.

Please, I need your help,
It is apprecited to send me the modified code.

Regards,
Bader

10 Answers, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 06 Jan 2011, 03:26 PM
Hi Bader,

Try setting ShowContentDuringLoad=true for the RadWindow / RadWindowManager that you are using. If this doesn't help, please provide a project that isolates the problem so we can check it.


Regards,
Georgi Tunev
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Bader
Top achievements
Rank 1
answered on 07 Jan 2011, 10:38 PM
Hello,

Thank you for your reply,
I added ShowContentDuringLoad=true to my code, but unfortunatilly it is not working.
Accroding to the requirements of the application I have to add th RadAjaxPanel property to the code. After adding this property the radwindow is not opened any more in all browsers.

Please run the following application: [link was deleted because it contained dev version] , and do the fhe following steps in order to show you the problems.
Problem 1 = Check "Category1" checkbox and then click the "FullScreen"Button. Here I recieve the error message which is showed in 1.jpg (attached).

Problem 2 = Check "Category1" checkbox and then click one of the small maps in the upper right side of the screen and after that ckick "FullScreen" Button. Here I recieve the error message which is showed in 2.jpg (attached).

Note: Clicking of "Full Screen" button will open a radwindow which contains same content of the map including links (if exists).

I have spent alot of time just trying to understand the problem source and to fix it, but it is not working for me.
So please, I need an immediate help.
It is apprecited to send me the modified code.

Regards,
Bader
0
Bader
Top achievements
Rank 1
answered on 08 Jan 2011, 09:37 PM
Hello,

Continued to my last post.
I'm still trying to solve the problem alone, I manged to fix part of the problem by changing the code:
var oWnd = $find("<%= RadWindow1.ClientID %>"); 
            oWnd.show(); 
            oWnd.setUrl("Pages/FullMaps/MainMap.aspx?width=" + width.toString() + "&height=" + height.toString() + "&mapPosition=" + mapPosition.toString() + "&ctgrsLst=" + ctgrsLst.toString().replace(" & ", ".")); 
            oWnd.maximize(); 

The new javascript code is:
var oWindow = radopen("Pages/FullMaps/MainMap.aspx?width=" + width.toString() + "&height=" + height.toString() + "&mapPosition=" + mapPosition.toString() + "&ctgrsLst=" + ctgrsLst.toString().replace(" & ", "."), "RadWindow1");
            oWindow.set_visibleTitlebar(false);
            oWindow.set_visibleStatusbar(false);
            oWindow.maximize();

But I still have a problem with my code, I hope you can help me with it.

Before expalining the problem please explain to me what is the difference between the above codes.

Please make the following steps in order to show you the problem source:
1)  Download the sample application from:[link was deleted because it contained dev version]
2) run the application:
3) Check the "Category1" checkbox.
4) click on the "Full Screen" button. Now a radwindow will open and shows the map in a big size including links (if exists).
5) Press any key to close the radwindow control.
6) Click on one of the small maps in the upper right side of the screen, and click the "Full Screen" button. Now a web page error occures (Show attached image).

I don't understand why does this problem oocures and what I should do in order to fix it. what is the expected object which bans the radwindow appearance.

Back to the FireFox problem. The RadWindow doesn't opens at all in FireFox Browser. What I should modify in my code in order to solve this problem.

Please, I need an immediate help, it is VERY important.
It is appreciated to send me the modified code.

Regards,
Bader
0
Georgi Tunev
Telerik team
answered on 13 Jan 2011, 09:41 AM
Hi Bader,

The 2 code snippets do basically the same. The only difference that I see is that in the first, you get a reference to the RadWindow control by using $find() while in the second, you call it with radopen(). I cannot say why these 2 snippets behave differently on your side - I'll need to examine your project first.
I see that you have already opened a support ticket - please send the project there and we will check it.


Kind regards,
Georgi Tunev
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Bader
Top achievements
Rank 1
answered on 13 Jan 2011, 01:07 PM
Hello,

Thank you for your reply,
I attached a sample application in support ticket.

Please, I need an immediate help ,
It is very appreciated to send me the modified code.

Regards,
Bader
0
Svetlina Anati
Telerik team
answered on 13 Jan 2011, 03:22 PM
Hello Bader,

 I already answered your support thread and for your convenience and for others who might have the same issue  I pasted my reply regarding this problem below:

 The js error is not directly to RadControls but to general ASP and javascript knowledge and it comes because of the following 2 facts:
     - innerText is undefined under Firefox and you can find more information about this on the net, e.g below:

http://www.google.bg/#hl=bg&source=hp&biw=1676&bih=827&q=innerText+firefox&rlz=1W1ADFA_en&aq=f&aqi=g1&aql=&oq=&gs_rfai=&fp=754a4e81c12f1ecb

That is why I suggest to use innerHTML instead.

    - a known limitation of AJAX is that it does not parse scripts - you can find many topics on the net about this, e.g below:

http://www.google.bg/#hl=bg&biw=1659&bih=827&rlz=1W1ADFA_en&q=script+after+ajax&aq=f&aqi=&aql=&oq=&gs_rfai=&fp=754a4e81c12f1ecb

We have also prepared a blog about this below:

http://blogs.telerik.com/tervelpeykov/posts/08-10-20/ajax_using_ajax_to_load_a_usercontrol_that_has_javascript_declared_in_it.aspx

In your case I suggest to use the ScriptManager's RegisterClientScriptBlock.

Kind regards,
Svetlina
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Bader
Top achievements
Rank 1
answered on 18 Jan 2011, 10:10 AM
Hello,

Thank you very much for the modified application, it solves the big part of the problem. There still a small problem which occures in some browsers. I already posted this issue in the support ticket. Here is the problem:
In Chrome browser the links are alive (working) just in the "Full Screen" Mode, but in the normal mode the links are not alive (not working).
In Firefox browser the links are not alive in both modes (Normal and Full Screen).
In IE browser the links are alive in both modes.

Please, In need your help,
It very appreciteed to send me the modified code.

Regards,
Bader
0
Svetlina Anati
Telerik team
answered on 19 Jan 2011, 09:18 AM
Hi Bader,

 I already answered your thread and for your convenience I pasted my reply below:

 I am glad I could help.


As to the new problem you report, I am afraid that I could not understand your explanations, which are the links (do you mean the small images or the links at the top?), what do you mean by "alive", etc. I played around with the demo under IE and FF but I could not see a difference between them.

On a side note, the problem you report does not seem to be related to RadWindow and RadControls and our support is focused on our products only. If so, please try to find a solution on the net. In case the problem is really related to RadWindow, prepare and send me a sample video capture of the problem reproduced with the very same demo which is attached and I will do my best to help.


Best wishes,
Svetlina
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Bader
Top achievements
Rank 1
answered on 19 Jan 2011, 10:15 AM
Hello,

Thank you for your reply, I checked my code again and I built another page which not contains radwindow and it is working. So I think that the problem is related to the radwindow control.
Attached with this post two images:
1.jpg shows a link (RadDock control) which is displayed by clicking "Eilat" hyperlink control. This link is not working in FF and Chrome but it is working in IE.
2.jpg shows the same link (in 1.jpg) but in Full Screen mode. It is working in IE and Chrome but it is not working in FF.

Please,  I need your help.
It is apprecited to send me the modified code.

Regards,
Bader
0
Svetlina Anati
Telerik team
answered on 21 Jan 2011, 09:03 AM
Hi Bader,

 I examined your other thread and you said there that you found out that the problem was actually not directly related to RadControls and that you were able to fix it on your own. If I am not correct, let me know and I will address your last post.

Best wishes,
Svetlina
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
Window
Asked by
Bader
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Bader
Top achievements
Rank 1
Svetlina Anati
Telerik team
Share this question
or