...

View Full Version : problems with firefox



o0O0o.o0O0o
05-16-2008, 02:21 AM
hi guys ,


I think i will go mad with firefox , everything working fine with IE but in in FF sometimes it works and sometimes it won't .Its all jquery and there are not enough members who can answer that. Yesteraday i tried hard to find why JS was not working and after 5 hous my compuer restarts and when i tried after restart , it starts working . I don't know how and why,

I am wasting too much time with FF. Just wanted to know from you guys.
If i start making site without testing in FF.

later on how much time or how much code chnages i had to make in complete project to make in working in FF. because now i am stuck with FF and if i take that into consideration i can't move further.


There should me minor changes i have to make or i have to completely redesign the site to make it work in FF.

oracleguy
05-16-2008, 02:27 AM
Building against IE isn't considered a good idea. On the whole stuff will work in IE that won't work in other browsers due to poor implementation of the browser internals.

If you build against FF (or any other more standards compliant browser) you should only have to make minor tweaks to handle quirks with IE. And the behavior of FF and the like will be more consistent since they don't do as much guessing as IE.

o0O0o.o0O0o
05-16-2008, 05:15 AM
Approximately how much time u think it will take , in case first i build site according to IE and after completing the making it work for FF.

gnomeontherun
05-16-2008, 05:39 AM
There is no way to tell, because how big is the site, what kinds of techniques did you use? Do you have a link for us to judge by?

o0O0o.o0O0o
05-16-2008, 05:55 AM
basically i have problem with AJAX in FF . I have tested the same code in FF and its now not working . I have no idea where is the problem . and i can't waste time on that



<script language="javascript" type="text/javascript" src="jquery.js"></script>

<script type="text/javascript">

function chk()
{


$.get('page2.html' ,function(data) {alert("data");});


}

</script>


<input type = "submit" value = "ajax" onclick ="chk();">

That was the most basic code . it is working very well on IE . It woked on FF before not now . I tried reisntalled the FF but , its not working .

I am using jquery to use Validation , form submit , upadate and all that.
Now my first basic step is not working on FF . I don't know i should stay or proceed further

If i had only woked fro IE , i think i should have finished my whole website.

gnomeontherun
05-16-2008, 06:13 AM
That was the most basic code . it is working very well on IE . It woked on FF before not now . I tried reisntalled the FF but , its not working .

I am using jquery to use Validation , form submit , upadate and all that.
Now my first basic step is not working on FF . I don't know i should stay or proceed further

If i had only woked fro IE , i think i should have finished my whole website.

Did you try the iframe script I linked to? Can you show the page or all of the code you are working on? That would help a lot...

Just because it works in IE doesn't mean that the scripts are working as designed. I don't know anything about jquery, but I know if you develop in FF and then hack or modify it to work in IE you are almost always going to be developing stronger code that plays by the rules.

o0O0o.o0O0o
05-16-2008, 06:27 AM
i usually save the the piece of code which worked before. The problem which i have is that same peice of code don't work afterwards .

I don't understand whether its my compuer or browser.now that piece of code did worked for me before not now. e,g

Leave jquery . i try using this link as well given by Aero
http://www.dynamicdrive.com/dynamicindex17/ajaxcontent.htm

the simple test link is also not woking in FF



<html>
<body>

<head>
<script type="text/javascript">

/***********************************************
* Dynamic Ajax Content- &#169; Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/

var bustcachevar=1 //bust potential caching of external pages after initial request? (1=yes, 0=no)
var loadedobjects=""
var rootdomain="http://"+window.location.hostname
var bustcacheparameter=""

function ajaxpage(url, containerid){
var page_request = false
if (window.XMLHttpRequest) // if Mozilla, Safari etc
page_request = new XMLHttpRequest()
else if (window.ActiveXObject){ // if IE
try {
page_request = new ActiveXObject("Msxml2.XMLHTTP")
}
catch (e){
try{
page_request = new ActiveXObject("Microsoft.XMLHTTP")
}
catch (e){}
}
}
else
return false
page_request.onreadystatechange=function(){
loadpage(page_request, containerid)
}
if (bustcachevar) //if bust caching of external page
bustcacheparameter=(url.indexOf("?")!=-1)? "&"+new Date().getTime() : "?"+new Date().getTime()
page_request.open('GET', url+bustcacheparameter, true)
page_request.send(null)
}

function loadpage(page_request, containerid){
if (page_request.readyState == 4 && (page_request.status==200 || window.location.href.indexOf("http")==-1))
document.getElementById(containerid).innerHTML=page_request.responseText
}

function loadobjs(){
if (!document.getElementById)
return
for (i=0; i<arguments.length; i++){
var file=arguments[i]
var fileref=""
if (loadedobjects.indexOf(file)==-1){ //Check to see if this object has not already been added to page before proceeding
if (file.indexOf(".js")!=-1){ //If object is a js file
fileref=document.createElement('script')
fileref.setAttribute("type","text/javascript");
fileref.setAttribute("src", file);
}
else if (file.indexOf(".css")!=-1){ //If object is a css file
fileref=document.createElement("link")
fileref.setAttribute("rel", "stylesheet");
fileref.setAttribute("type", "text/css");
fileref.setAttribute("href", file);
}
}
if (fileref!=""){
document.getElementsByTagName("head").item(0).appendChild(fileref)
loadedobjects+=file+" " //Remember this object as being already added to page
}
}
}

</script></head>

<a href="javascript:ajaxpage('form3.html', 'result');">test</a>


<div id ="result">

</div>





</body>
</html>


Put anything in form3.html and have a check in FF . It works in IE and opera
There may be problem with my browser , is there any offline emulator for FF in which i can check

gnomeontherun
05-16-2008, 06:43 AM
It works...but your page has the <body> before the <head>...that should be fixed and maybe it would work.

o0O0o.o0O0o
05-16-2008, 06:56 AM
I restarted my computer again and now everything is working.
even with <body> tag before head

i really don't know what should i do . Is any virus doing all this .

so this thing wasted my whole day on this , although nothing was wrong.
Thast why i was asking if i code for iE for small site , how much time it will take to make it work for FF.

Beacsue i won't know whether i am wrong some where or this is just my browser
my so much time has been wasted in finding errors which were never there

oracleguy
05-16-2008, 07:36 AM
I won't speak to the JS issues but when you are manipulating the page content with JS and you have a serious markup error like having the head tag inside the body, that could cause weird issues.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum