You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Juri Tanganelli <ju...@gmail.com> on 2007/05/29 15:39:43 UTC

[users@httpd] Problem with Apache Http server and javascript redirect

I use a javascript generated by "ap_rputs" to manage a cokie session and to
redirect an XML document. When I try to view the page in Internet explorer
it doesn't work and I get an error: javascript code doesn't activate the
redirect and I get mixed page javascript/XML.

This is my javascript

<html><head><title></title></head><body>
<form name=paramform method="POST" action="http://new_page.xml">
<script language='javascript'>
document.open()

document.cookie = "Token_DOM_opriskev='SessionAcquisitionError_ID'"

document.paramform.submit()
document.close()
</script>
</form></body></html>

When I browse the page in internet explorer the redirect doesn't work and I
get a mixed page like this

<html><head><title></title></head><body>
<form name=paramform method="POST" action="
http://opriskev.sviluppo.local/opriskev/CRYSTAL_REPORT_SCHEMA.do?query1=test
">
<script language='javascript'>
document.open()

document.cookie = "Token_DOM_opriskev='SessionAcquisitionError_ID'"

document.paramform.submit()
document.close()
</script>
</form></body></html>
<?xml version="1.0" encoding="UTF-8"?><xs:schema xmlns:xs="
http://www.w3.org/2001/XMLSchema">

--- XML body..... -----------------------------------

How to redirect correctly my XML page?