Reply to Re: Problem on IE refreshing form elements values

Your name:

Reply:


Posted by Paul Lautman on 06/22/06 21:34

odgarro wrote:
> Hi,
> I have this problem I can΄t solve.
>
> I΄m using some mix of javascript / php / ajax code to open a text
> file, process its info and close it.
>
> While skiping through the text file lines, I΄d like some of myForm
> elements be updated with the info extracted from the file.
>
> This way, the user realice that actually some process is being
> executed and forgets about "oh ! this isn΄t working, I'll try closing
> and opening the app again".
>
> Here is some part of the HTML code:
>
> <FORM name="myForm" id="myForm" method="POST" >
>
> <INPUT type="text" name="employee" id="employee">
>
> <INPUT type="button" name="btnProcess" id="btnProcess"
> onclick="xajax_ProcessFile();" >
>
> </FORM>
>
> and part of my ProcessFile() php function should look like:
>
> $h = fopen($file_name,"rb") ;
>
> while( ($fld = fgetcsv($h, 35," ")) !== FALSE ) {
> $emp = $fld[0] ;
>
> $objResponse->addScript("document.getElementById('employee').value='$emp';");
> }
> fclose($h);
> return $objResponse->getXML();
>
> Now... on Mozilla/FireFox this works just like I expect.
> As the function skips through the text file lines, the value of
> myForm.employee.value is updated with some text of the line being
> processed.
> But, on IE nothing happens until the function reachs the end of the
> text file (when the last record do appears on myForm.employee.value )
> So, on both navigators my function reaches its propose (that is to
> process the text file) but on IE the info is not shown on the form
> while processing.
>
> Any idea ???

Wouldn't this be better handled on comp.lang.javascript, it really isn't
anything to do with PHP

[Back to original message]


УдалСнная Ρ€Π°Π±ΠΎΡ‚Π° для программистов  •  Как Π·Π°Ρ€Π°Π±ΠΎΡ‚Π°Ρ‚ΡŒ Π½Π° Google AdSense  •  England, UK  •  ΡΡ‚Π°Ρ‚ΡŒΠΈ Π½Π° английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Π‘Π°ΠΉΡ‚ ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ Π² Π‘Ρ‚ΡƒΠ΄ΠΈΠΈ Π’Π°Π»Π΅Π½Ρ‚ΠΈΠ½Π° ΠŸΠ΅Ρ‚Ρ€ΡƒΡ‡Π΅ΠΊΠ°
ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ΠΈΠ΅ ΠΈ ΠΏΠΎΠ΄Π΄Π΅Ρ€ΠΆΠΊΠ° Π²Π΅Π±-сайтов, Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚ΠΊΠ° ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠ½ΠΎΠ³ΠΎ обСспСчСния, поисковая оптимизация