corsasport.co.uk
 

Corsa Sport » Message Board » Off Day » Geek Day » Embeding an Exchange 2010 OWA calander within a frame.


New Topic

New Poll
  Subscribe | Add to Favourites

You are not logged in and may not post or reply to messages. Please log in or create a new account or mail us about fixing an existing one - register@corsasport.co.uk

There are also many more features available when you are logged in such as private messages, buddy list, location services, post search and more.


Author Embeding an Exchange 2010 OWA calander within a frame.
Paul
Member

Registered: 16th Apr 02
Location: Oop north.
User status: Offline
13th Jun 11 at 21:02   View User's Profile U2U Member Reply With Quote

Hi,

I have the below piece of code that I am trying to embed into another page.

Everytime the page loads it pulls me off to another page and doesn't stay within the iframe.

Any ideas why?

Any help is greatly appreciated

<script>
function LoginToOWA (server,domain,username,password) {


var url = "https://" + server + "/owa/auth/owaauth.dll";
var p = {destination:'https://' + server + '/owa/myemailaddress@domain.com/?cmd=contents&f=Calendar&view=weekly',flags:'0',forcedownlevel:'0',trusted:'0',isutf8:'1',username:domain + '\\' + username,password:password};


var myForm = document.createElement("form");
myForm.method="post" ;
myForm.action = url ;

for (var k in p) {

var myInput = document.createElement("input") ;
myInput.setAttribute("name", k) ;
myInput.setAttribute("value", p[k]);
myForm.appendChild(myInput) ;
}


document.body.appendChild(myForm) ;
myForm.submit() ;
document.body.removeChild(myForm) ;
}
</script>

<body onload="javascript:LoginToOWA('mywebmail.domain.com','logon domain','username','password');">

</Body>
:thumbs:
ed
Member

Registered: 10th Sep 03
User status: Offline
13th Jun 11 at 21:20   View User's Profile U2U Member Reply With Quote

I'd take a guess that you're trying to do authentication in an iframe. Just about all web services out there don't let you do that and you have to authenticate in a pop-up so that the user can see the url of the authentication page.

Also, you don't need to put the javascript:; bit in the onload attribute of the body, just the function name and it's arguments.
pow
Premium Member

Avatar

Registered: 11th Sep 06
Location: Hazlemere, Buckinghamshire
User status: Offline
14th Jun 11 at 08:20   View Garage View User's Profile U2U Member Reply With Quote

Didn't think you could do it, as ed said it's an MS security thing that the user has to see the web address.

 
New Topic

New Poll

  Related Threads Author Forum Replies Views Last Post
Outlook Web Access sukhwant Geek Day 7 497
22nd Mar 06 at 21:03
by MikeLamb
 
Exchange to download/send POP3 Mail (help needed) Aaron Geek Day 5 851
21st Dec 08 at 15:53
by ENB
 
iPhone/Exchange E Mail help Aaron Geek Day 7 328
4th Feb 09 at 13:10
by ENB
 
Trying to get my works email onto laptop.. can someone help chris_uk Geek Day 14 870
28th Oct 09 at 13:29
by pow
 
I need to update somebodys Outlook Calendar... Whittie Geek Day 3 273
19th Nov 10 at 16:58
by Whittie
 

Corsa Sport » Message Board » Off Day » Geek Day » Embeding an Exchange 2010 OWA calander within a frame. 28 database queries in 0.0133860 seconds