Thanks for pointing me to the iui.js lines.

I added a target to the link to the PDF and it still opens as text.

If I open a new window the PDF is fine but then I loose the nice UI.....

Ben
**


Derek Williams wrote:
> This looks to be because there is no target defined for the anchor, 
> not that you should need to but it looks like iUI is checking for it.
>
> If you look at iUI line 180 "function addEventListener", you'll see 
> that the code is checking for "!link.target", stepping through the 
> code this is where it lands, and so calls iui.showPageByHref, which 
> ends up not showing the pdf at all, but makes an XMLHttpRequest, which 
> is why the raw pdf contents are shown.
>
> 206  else if (!link.target)
> 207 {
> 208 link.setAttribute("selected", "progress");
> 209 iui.showPageByHref(link.href, null, null, null, unselect);
> 210 }
>
>
> On Tue, May 12, 2009 at 6:58 AM, Ben Marchbanks <[email protected] 
> <mailto:[email protected]>> wrote:
>
>     http://www.magazooms.com/labs/iphone/index.php?pubID=ER_8
>
>     select an issue then "click to read"
>
>     Ben
>
>     Derek Williams wrote:
>>     I have iUI up and running, if you want to post more details I can
>>     take a look.
>>
>>     On Tue, May 12, 2009 at 5:17 AM, alQemist <[email protected]
>>     <mailto:[email protected]>> wrote:
>>
>>
>>         I have a link that points to a PDF and it works fine from a
>>         non IUI
>>         interface however when I add the link to my IUI project it
>>         opens as
>>         raw text......Any ideas ?
>>
>>
>>
>>
>>
>>     -- 
>>     Derek Williams
>>     Cell: 970.214.8928
>>     Home Office: 970.416.8996
>>
>>
>
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"iPhoneWebDev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/iphonewebdev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to