Page 1 of 3 123 LastLast
Results 1 to 10 of 23

Thread: pdf within an iframe

  1. #1
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default pdf within an iframe

    hello what I am trying to do , is that I have 2 web pages, the first we will call first.html , and the second, second.html.

    What I want to happen is this , when I click on a certain link , on first.html, I want for second.html , to appear , and also on an iframe , in second.html, I want a pdf to show up.

  2. #2
    Join Date
    Jul 2008
    Location
    Derbyshire, UK
    Posts
    3,033
    Thanks
    25
    Thanked 599 Times in 575 Posts
    Blog Entries
    40

    Default

    It isn't clear what you're trying to achieve. If you show us what you have tried, we can offer suggestions, but unfortunately, we can't troubleshoot something we can't see.

    It sounds like you should do some research into iframes and the target attribute too, so start there and post back when you have a basic demo prepared for us to look at.
    Focus on Function Web Design
    Fast Edit (A flat file, PHP web page editor & CMS. Small, FREE, no database!) | Fast Edit BE (Snippet Manager) (Web content editor for multiple editable regions!) | Fast Apps

  3. #3
    Join Date
    Nov 2014
    Location
    On A Scottish Island
    Posts
    488
    Thanks
    0
    Thanked 62 Times in 58 Posts

    Default

    This sounds like a homework exercise and we won't do your homework for you as you would learn nothing from it.

    As Beverley says, you need to do some research. Try starting here and then here.

  4. #4
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I have done my homework, a whole lot of searching, and cannot find the answer , Go to http://wayfarer.atwebpages.com/first.html and it willl explain things further.
    Last edited by Beverleyh; 11-09-2015 at 03:48 PM.

  5. #5
    Join Date
    Jul 2008
    Location
    Derbyshire, UK
    Posts
    3,033
    Thanks
    25
    Thanked 599 Times in 575 Posts
    Blog Entries
    40

    Default

    Unfortunately, I cannot access your website because it is being flagged as malware by the filters on my network. Hopefully someone else can help
    Focus on Function Web Design
    Fast Edit (A flat file, PHP web page editor & CMS. Small, FREE, no database!) | Fast Edit BE (Snippet Manager) (Web content editor for multiple editable regions!) | Fast Apps

  6. #6
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I do not know why it is considered malware , does the index page show up as malware also??? Anyhow here are pictures or screenshots of the pages.Click image for larger version. 

Name:	first.jpg 
Views:	161 
Size:	15.0 KB 
ID:	5730Click image for larger version. 

Name:	second.jpg 
Views:	190 
Size:	8.7 KB 
ID:	5731

  7. #7
    Join Date
    Nov 2014
    Location
    On A Scottish Island
    Posts
    488
    Thanks
    0
    Thanked 62 Times in 58 Posts

    Default

    Well, you clearly haven't done much research as the first hit on Google for "iframe" led to this page.

    Your page is probably flagged as malware because of the content of the active link which is a JavaScript redirect. If you want to create a link for general use just use the <a>...</a> tags and not Javascript which could hide all sorts of devious stuff (and in your case actually does!).

  8. #8
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I looked at the web page you showed me , and I already knew this stuff, it is not at all what I am trying to do, and there is no devious stuff on my web page, it is a study of the trinity I wrote.

  9. #9
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Now my index page , on that website , I use to have a study on Scribd , but took it off of Scribd , that would be why the study of the index page does not function.
    I could try the <a></a> tag , but in the end it is much more than that , that I am trying to do , instead of writting a seperate page for each study, I wnat all of my studies to show up in this one iframe , on the second web page , I have succeeded in doing this on my studies page, but not on my index page, my iframe is on the studies page.

    Hope you can help , just want answers , not asumptions.

  10. #10
    Join Date
    Nov 2015
    Posts
    12
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Here is a code I used.
    Code:
     <div onClick='document.getElementById("someID").src="https://onedrive.live.com/embed?cid=0912027297A21B07&resid=912027297A21B07%218989&authkey=AD_ol5nd3vdkIvY&em=2&wdStartOn=1&wdEmbedCode=0&wdPrint=0";'>PDF test 1</div>	<br><bR>
    
     
    <iframe id='someID' frameborder="1" scrolling="no" width="100%" height="355"></iframe>
    But now I changed it to an <a> tag.
    Code:
     <a onClick='document.getElementById("someID").src="https://onedrive.live.com/embed?cid=0912027297A21B07&resid=912027297A21B07%218989&authkey=AD_ol5nd3vdkIvY&em=2&wdStartOn=1&wdEmbedCode=0&wdPrint=0";'>PDF test 1</a>	<br><bR>
    
     
    <iframe id='someID' frameborder="1" scrolling="no" width="100%" height="355"></iframe>
    this works on my studies page, but what I want is when I click on a link on my index page, that it brings me to my studies page, and also open my study in the iframe that is on the studies page.

    I tried alot of codes including the web page you sent me too, but thanks for letting me know about stuff on the <a> tag and javascript.
    Last edited by Beverleyh; 11-09-2015 at 07:24 PM. Reason: Formatting

Similar Threads

  1. Including external content: standard iframe, hidden iframe or Ajax?
    By molendijk in forum Coding tips & tutorials threads
    Replies: 0
    Last Post: 10-19-2011, 07:34 PM
  2. Pop over Parent from iframe, feed data from Popup back to iframe
    By cclambie in forum Dynamic Drive scripts help
    Replies: 0
    Last Post: 12-05-2007, 10:38 AM
  3. Replies: 3
    Last Post: 10-17-2007, 03:50 PM
  4. Iframe scrollbar color and Monthly iframe content
    By big-dog1965 in forum JavaScript
    Replies: 1
    Last Post: 09-12-2007, 07:04 AM
  5. Replies: 0
    Last Post: 06-16-2005, 03:16 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •