FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » IE8 crashes when back button clicked after sending email from PHP script
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: IE8 crashes when back button clicked after sending email from PHP script [message #172180 is a reply to message #172178] Thu, 03 February 2011 11:43 Go to previous messageGo to previous message
alvaro.NOSPAMTHANX is currently offline  alvaro.NOSPAMTHANX
Messages: 277
Registered: September 2010
Karma:
Senior Member
El 03/02/2011 10:33, P E Schoen escribió/wrote:
> I just finished a simple HTML form which asks for a password to access
> (and add to) an email list maintained in an SQlite database. The emails
> are displayed as <a href="mailto:Addy(at)example(dot)com">, so the addresses
> are clickable. It brings up my Windows Live Mail (which is part of IE8
> in a way), but if I send an email or cancel, and then click the BACK <-
> button, I get a message that IE has stopped working. The email is sent
> OK, but this crash happens consistently. I have everything on my Apache
> xampp localhost. IE8 recovers and reloads the tab with my HTML form. The
> list of names and emails are just echoed to STDIN.
>
> Any ideas where to look or how to test for what's causing this?

I'd dare say it's a bug in some Microsoft product: Internet Explorer,
Windows Live Mail or Windows itself. The only imaginable way to crash a
browser with a server side language is to send HTML from an infinite loop.


> BTW, I'm beginning to like PHP now that I got my feet wet. But I had a
> really hinky bug where I got errors of "unexpected
> T_CONST_ENCAPSED_STRING and T_ENCAPSED_AND_WHITESPACE". The error
> occurred on a line that was perfectly fine, and even when I commented
> the line with // or */ .. /*. Finally I found an unpaired single and or
> double quote, and a missing ). But the -l lint was not much help in this
> case. Any better tools that might catch this sort of error?

The -l option should tell you the exact error message, file and line
number. But I assume you are referring to errors are detected several
lines later, such as mismatched parenthesis and the like:

<?php
foreach($foo as $i){
blah();
// Missing bracket here

if($bar){
blah();
blah();
}
// Error reported here

Well... You basically need to understand the error messages and gather
some experience. Error messages are normally self-explanatory but they
may also refer to parser tokens and that makes them difficult to
understand them. Tokens are explained here:

http://es.php.net/manual/en/tokens.php

Curiously, T_CONST_ENCAPSED_STRING does not appear to be documented
(:-!) but there is T_CONSTANT_ENCAPSED_STRING. If you look at both
definitions, it's clear that something failed when building a complex
double-quoted string.

For an automated parser, it's extremely difficult to figure out what you
actually had in mind. Any decent editor should feature syntax
highlighting and thus warn you about unmatched quotes but the editor
doesn't really have a reliable way to figure out where you intended to
close the string. Whatever, it's worth noting that the JetBrains
PhpStorm IDE (written in Java and non-free) does a very good
mind-reading job anyway.



--
-- http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web: http://borrame.com
-- Mi web de humor satinado: http://www.demogracia.com
--
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: REQ: Looking for a script program called paCheckbook
Next Topic: json and non UTF8
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sat Nov 23 11:09:56 GMT 2024

Total time taken to generate the page: 0.05004 seconds