LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 11-15-2023, 06:05 PM   #1
mfoley
Senior Member
 
Registered: Oct 2008
Location: Columbus, Ohio USA
Distribution: Slackware
Posts: 2,587

Rep: Reputation: 179Reputation: 179
iframe attributes fit view toolbar


I have the following iframe tag:
Code:
<iframe style="display: block; margin: 0 auto; margin-top: 20px; width: 900px; height: 11.2in;" 
src="mydoc.pdf#view=fit&toolbar=0&navpanes=0&statusbar=0">
</iframe>
I created this a long time ago, so things may have changed with HTML5. Two questions:

1. I cannot find the #view=fit in any searched. The # would seem to indicate a name tag in the document, so that doesn't make sense, but if I change it = ?view=fit, none of the other parameters work. Also, the scrolling=no tag attribute (not in my iframe) is deprecated, so how would I remove the scrollbar? I see no official attribute for this. The only way I can make the scrollbar disappear is to create a sufficiently long iframe.

2. The toolbar=0 works on Edge
 
Old 11-15-2023, 10:36 PM   #2
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 4,874
Blog Entries: 1

Rep: Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871
Sounds like an pdf-specific extension. See this: https://stackoverflow.com/questions/...n-embedded-pdf
 
Old 11-17-2023, 12:49 AM   #3
mfoley
Senior Member
 
Registered: Oct 2008
Location: Columbus, Ohio USA
Distribution: Slackware
Posts: 2,587

Original Poster
Rep: Reputation: 179Reputation: 179
Quote:
Originally Posted by NevemTeve View Post
Sounds like an pdf-specific extension. See this: https://stackoverflow.com/questions/...n-embedded-pdf
Other browsers support the toolbar=0, but not Firefox. There is a rather elaborate way of allegedly doing so using a userContent.css: https://support.mozilla.org/en-US/questions/1119523, but I'm not willing to go to that extreme. Perhaps one day Firefox will fix this.

Nevertheless that doesn't really answer my question about the #view=fit, nor why #view works but ?view does not. I thought the "#" is normally a reference to an internal name tag, but apparently not for pdfs. Perhaps I just copied this noop from someone's example once-upon-a-time and it never did anything.
 
Old 11-17-2023, 11:19 AM   #4
NevemTeve
Senior Member
 
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 4,874
Blog Entries: 1

Rep: Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871Reputation: 1871
You might have missed this bit: this is a pdf-specific extension, which has nothing to do with standard meaning of character # in html
 
  


Reply

Tags
firefox, iframe, toolbar



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
When changing color for toolbar in Libre Office only half the toolbar changes Reno232 Linux - Desktop 2 07-18-2022 02:24 PM
A virus changed all my index files with iframe, how to remove that iframe line? Farman Linux - Security 10 07-16-2009 08:40 AM
force iframe content to remain in iframe? frieza Programming 1 09-17-2008 06:29 AM
KDE 3.5.9 - Konqueror - location toolbar can't be placed next to the main toolbar bhy Linux - Desktop 2 07-23-2008 07:50 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration