13 Replies Latest reply on Aug 16, 2014 11:14 AM by ultranix

    Resize entire page in webviewer to 80%

    ultranix

      Title

      Resize entire page in webviewer to 80%

      Post

           How to resize the entire page, that is displayed by webviewer to 80%? I tried searching internet, but most cases found contain images resizing, and I don't need just images, I need ENTIRE WEB PAGE.

           I am not very familiar with CSS, so, when you post reply, be as specific as possible.

        • 1. Re: Resize entire page in webviewer to 80%
          ultranix

               I am quite amazed, that such a "basic" feature and question is not yet resolved...

          • 2. Re: Resize entire page in webviewer to 80%
            philmodjunk

                 Are you displaying data from a web site or is this a web viewer with a "data URL" that will display data from the database?

                 If a web site, the site's API may offer a "zoom" option that you can use for this. I've been able to do such with Google Maps.

            • 3. Re: Resize entire page in webviewer to 80%
              ultranix

                   Basically, I am displaying web page in webviewer, the link to which is calculation field. Because I use it to have our web CRM on that window on the left, and the fields that I'm working with on the right. So in order not to have Filemaker database and Internet browser window, I decided to incorporate internet window (web viewer) and have side by side with my actual database.

                   I am not familiar with API's, but as I viewed our CRM source, there was no "height" or "width". I tried also entering "width = 80%" in that WEbviewer window, but nothing really change, site was displayed at original 100% zoom. It's not the feature that I cannot live without, but it would definately be good to have it.

                   Another issue - I am not sure why javascript (in the webviewer window) is not fully supported. Some buttons are not working, when clicked, while they work on Internet Explorer, Mozilla and Chrome. Same could be said about conditional parts of the site: for example, if I set a particular status, it may ask me to enter comment (and no next action fields are visible) or just enter next action details (date, time) but no comment field is visible. So when I change statuses, nothing updates and shows the same comment window, while most of the times I only need to set next action and no comment. What could this be? This bug causes more headache, because I then have to open web-browser and re-do the stuff again.

              • 4. Re: Resize entire page in webviewer to 80%
                philmodjunk

                     An API documents how web site developers set up a site so that software from other sources (Such as FileMaker, a SmartPhone app or a web browser) can interact with their web site. This API can be different with every web site and often does not exist for a given site.

                     

                          I am not sure why javascript (in the webviewer window) is not fully supported. Some buttons are not working,

                     That sounds like something to report as a possible bug over in Report an Issue.

                      

                • 5. Re: Resize entire page in webviewer to 80%
                  ultranix

                       I tried another solution - enlarge objects on my layout by 33% and resize the whole FileMaker window to 75%. But graphics now look poor - lines are blurry, text doesn't seem to look sharp.

                       Is there anything else I could do?

                  • 6. Re: Resize entire page in webviewer to 80%
                    calebmiranda

                         I have a web viewer linked to a calculation field. That solves the problem for me:

                          

                         "data:text/html," &

                          

                         "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">

                         <html>

                         <head>

                         <style>

                         body {

                           font-family: verdana;

                           font-size: 12px;

                           padding: 0;

                           margin: 0;

                           background: #fff;

                           zoom: 5%;

                         }

                         ...

                    • 7. Re: Resize entire page in webviewer to 80%
                      ultranix

                           I tried to place this into Webviewer:

                           

                                BASE::link &

                                "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">
                                <html>
                                <head>
                                <style>
                                body {
                                  font-family: verdana;
                                  font-size: 12px;
                                  padding: 0;
                                  margin: 0;
                                  background: #fff;
                                  zoom: 5%;
                                }"

                           But it only told me that "webpage cannot be displayed". Where did I go wrong?

                      • 8. Re: Resize entire page in webviewer to 80%
                        calebmiranda

                             O, I'm sorry, do you mean you want an external website to be displayed as 80% zoom. I thought you were building your html code. In the html code you are building, that would work as a CSS

                        • 9. Re: Resize entire page in webviewer to 80%
                          ultranix

                               YEs, external website.

                          • 10. Re: Resize entire page in webviewer to 80%
                            calebmiranda

                                 maybe you should take a look at this function. I guess it could work as you'd expected (I didn't test) - Maybe.

                                  

                                 http://www.briandunning.com/cf/985

                                  

                            xExtractHtmLContent (url, query, data, v-width, v_height, L_offset, T_offset, scalewidth, scaleheight)

                            • 11. Re: Resize entire page in webviewer to 80%
                              calebmiranda

                                   another option, if you are willing to use a plugin, is MBS plugin. I own it, and I have tested the function Webview.zoomPageOut in my Mac and it worked. They also have a windows function for that (Webview.setZoom). But, well, you'd have to have a plugin and all the cost, in money and in maintenance, it requires. If you have a personal / semi-professional project, it's definitely a go. In case it's a fully professional job, you could consider it. Link to all the functions of the plugin: 

                                   http://www.monkeybreadsoftware.de/filemaker/

                                   of course, the plugin has way more than this WebViewer Zoom feature (I bought it because of the print Webviewer feature). Even though, it has some nice extras (Syntax Coloring is something I already cannot live without.)

                                   happy filemaking,

                              • 12. Re: Resize entire page in webviewer to 80%
                                raybaudi

                                     If the site that you want to display accepts Iframes, you could try to put this calculation into the Web Viewer:

                                     "data:text/html,
                                     <!DOCTYPE html>
                                     <html>
                                     <head>
                                     <style>
                                     BODY {
                                        border:none;
                                        overflow:hidden;
                                     }
                                     IFRAME {
                                        width: 1000px;
                                        height: 600px;
                                        zoom: 0.8;
                                     }
                                     </style>
                                     <body>
                                     <iframe src='
                                     " & YourTable::site URL & "
                                     '></iframe>
                                     </body>
                                     </html>"
                                • 13. Re: Resize entire page in webviewer to 80%
                                  ultranix

                                       Thank you raybaudi. It worked!

                                       Too bad, that google doesn't work with iframe. But I remember that Philmodjunk was able to resize google page?