This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use the new forum.
Home » legacy support » symfony 1.0 » Template not shown in IE 6
Template not shown in IE 6 [message #98594] Thu, 06 May 2010 08:44 Go to next message
gentrobot  is currently offline gentrobot
Messages: 20
Registered: October 2009
Junior Member
Hi,

I have a form on the paidListingCheckoutSuccess.php page. I have an onclick event on the submit button to call the js function ValidateAgentSiteCheckout(). Under the validate() function, the form is submitted using

document.checkOutForm.submit()

The action of the form is payment/paymentCheckoutFinal and it is required to display paymentCheckoutFinalSuccess.php on successful submission.

I checked by putting logs at the various parts in action and in template as well. All the logs are displayed properly but the template paymentCheckoutFinalSuccess.php is not displayed in IE6. It is working fine in other browser that include IE7,Chrome,Firefox. Sad

I used "sfContext::getInstance()->getLogger()->info(" before the header and after the footer in paymentCheckoutFinalSuccess.php and i can see it in the log file. Also, using $this->logMessage() showed that the action executePaymentCheckOutFinal() is executed completely.

What can be done to make it work in IE6? Any tweak? Or am I lacking something?

A part of the log file:

May 06 11:49:12 symfony [info] <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>< ><>
Log at the last line of Action execution
<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>< ><>
May 06 11:49:12 symfony [info] {sfView} initialize view for "payment/paidListingCheckoutFinal"
May 06 11:49:12 symfony [info] {sfView} render "full path...payment/templates/paidLis
tingCheckoutFinalSuccess.php"
May 06 11:49:12 symfony [info] >>>>>>>>>>>>>>>>>>>>>>First log in template>>>>>>>>>>>>>>>>>>>>>>>>>>>>
May 06 11:49:12 symfony [info] {PartialHelper} call "home->executeHeader()"
May 06 11:49:12 symfony [info] {sfView} initialize view for "home/_header"
May 06 11:49:12 symfony [info] {sfView} render " /home/mohsin/workspace/zam_fe/apps/frontend/modules/home/tem plates/_header.ph
p"
May 06 11:49:12 symfony [info] {PartialHelper} call "home->executeFooter()"
May 06 11:49:12 symfony [info] {sfView} initialize view for "home/_footer"
May 06 11:49:12 symfony [info] {sfView} render " /home/mohsin/workspace/zam_fe/apps/frontend/modules/home/tem plates/_footer.ph
p"
May 06 11:49:12 symfony [info] {sfView} initialize view for "global/_talkToUs"
May 06 11:49:12 symfony [info] {sfView} render " /home/mohsin/workspace/zam_fe/apps/frontend/templates/_talkT oUs.php "
May 06 11:49:12 symfony [info] >>>>>>>>>>>>>>>>>>>>>Last log in template<<<<<<<<<<<<<<<<<<<<<<<<<<<
May 06 11:49:12 symfony [info] {sfView} decorate content with " /home/mohsin/workspace/zam_fe/apps/frontend/templates/layout .p
hp"
May 06 11:49:12 symfony [info] {sfView} render " /home/mohsin/workspace/zam_fe/apps/frontend/templates/layout .php "
May 06 11:49:12 symfony [info] {sfCreole} prepareStatement(): UPDATE `table` SET column ='value' WHERE column
=value
May 06 11:49:12 symfony [info] {sfCreole} executeUpdate(): UPDATE `table` SET column ='value' WHERE column
=value
May 06 11:49:12 symfony [info] {sfFilter} render to client
May 06 11:49:12 symfony [info] {sfResponse} send status "HTTP/1.0 200 OK"
May 06 11:49:12 symfony [info] {sfResponse} send header "Content-Type": "text/html; charset=utf-8"
May 06 11:49:12 symfony [info] {sfResponse} send content (57567 o)
May 06 11:49:12 symfony [info] {sfTimerManager} Configuration 2.74 ms (15)
May 06 11:49:12 symfony [info] {sfTimerManager} Action "payment/paidListingCheckoutFinal" 10.67 ms (1)

[Updated on: Thu, 06 May 2010 08:49]

Re: Template not shown in IE 6 [message #98595 is a reply to message #98594 ] Thu, 06 May 2010 09:08 Go to previous messageGo to next message
gentrobot  is currently offline gentrobot
Messages: 20
Registered: October 2009
Junior Member
Also, I would like to add to the information,when I checked the log file on IE6 and firefox 3.6.3,he log files were the same.
Re: Template not shown in IE 6 [message #98604 is a reply to message #98594 ] Thu, 06 May 2010 10:43 Go to previous messageGo to next message
halfer  is currently offline halfer
Messages: 9535
Registered: January 2006
Location: West Midlands, UK
Faithful Member
Sounds like a JS problem. Have you run everything through Firebug to ensure you're not getting any errors?

Also it sounds like your JS approach could be improved a bit. I am guessing that if JS is disabled, your site will no longer work. It would be better I think if you attach an event handler (onSubmit) to the form and return false from ValidateAgentSiteCheckout if validation fails and you want to stop the submission.

Since JS can fail on the client side, you should also be validating the submission in the paymentCheckoutFinal action as well.

Lastly if you are modifying data, this should be a POST. Accordingly to prevent back-button problems, you should redirect in paymentCheckoutFinal, and not render a template in the same request.

So, I am not sure what the problem is, but the above should make it work x-browser.


Remember Palestine
Re: Template not shown in IE 6 [message #98605 is a reply to message #98594 ] Thu, 06 May 2010 10:50 Go to previous messageGo to next message
halfer  is currently offline halfer
Messages: 9535
Registered: January 2006
Location: West Midlands, UK
Faithful Member
Btw, I'd recommend attaching events `unobtrusively` i.e. with jQuery or similar, rather than adding onX attributes to the form tag. This is considered a better approach, IMO.


Remember Palestine
Re: Template not shown in IE 6 [message #98607 is a reply to message #98605 ] Thu, 06 May 2010 11:26 Go to previous messageGo to next message
gentrobot  is currently offline gentrobot
Messages: 20
Registered: October 2009
Junior Member
Thanks a lot halfer ! I think you are right. Js might be the culprit, I will just try to do whatever you suggested (adding onsubmit). Will post here when successful ! Smile

Once again, thank you very much for your help !
Re: Template not shown in IE 6 [message #99250 is a reply to message #98594 ] Tue, 18 May 2010 07:09 Go to previous messageGo to next message
gentrobot  is currently offline gentrobot
Messages: 20
Registered: October 2009
Junior Member
Sorry for replying with delay. I have just added the onsubmit=return function() and removed the document.formname.subit() form the function(). Its working absolutely fine.

Thanks once again!

Re: Template not shown in IE 6 [message #102993 is a reply to message #99250 ] Fri, 23 July 2010 12:26 Go to previous message
skywalker  is currently offline skywalker
Messages: 334
Registered: March 2008
Location: Norway
Faithful Member
In my opinion, IE is (in general) a pain in the a**s. That is why I always put something like this in the global layout file:

<!--[if lt IE 8]>
  <p class="error">
    You are using an old version of IE - please update!
  </p>
<![endif]-->


Smile


May the source be with you
Previous Topic:Propel 1.5 for Symfony 1.0?
Next Topic:dynamic routing
Goto Forum:
  

powered by FUDforum - copyright ©2001-2004 FUD Forum Bulletin Board Software