June 27, 201114 yr I have two web viewers, showing custom code generated based on field objects. Each was working perfectly yesterday. Today, for no reason I can discover, they are both exceeding the bottom border of their bounding boxes (in the picture, they bottom edges are in the blue bar but should stop within the white box above that). I've tried changing their size (both bigger and smaller) with no change in symptoms. Creating a new web viewer with the same calculation as the content Did fix the problem, though. Any ideas on how I can avoid this in the future? I can't find anything about it on the web (though I may not have used the necessary terminology correctly - this is my first attempt using web viewers for manually created code). Thanks! Matthew
June 30, 201114 yr Author One additional note: the WebViewer elements are layered behind all other elements on the page except the background box. And are still showing up overlapping the elements below them (but not always...<sigh>...I hate intermittent problems). Any suggestions gratefully welcomed!
June 30, 201114 yr A file showing the problem might help. the WebViewer elements are layered behind all other elements on the page A web viewer object is always in the front (unless it's empty).
June 30, 201114 yr Author A web viewer object is always in the front (unless it's empty). Oh, I didn't know that. So in layout mode you can layer it behind all other elements, but that's not how FM treats it in browse mode? -Just tested and confirmed this for myself...<sigh>. So, sorry for the newbie question: any idea why it would exceed the bounds I defined for it? Is that "expected" behavior, too? (I wish I knew more about these things!).
June 30, 201114 yr Author Follow-up: even weirder, further testing revealed that it is related to the content. Showing the border revealed that the web viewer bounds were exactly where I'd placed them; the internal white space (content) was overlapping the border of the viewer! Copying the web address definition and pasting into a new web viewer resulted in the same problem. Pasting into a text editor and then copying and pasting back into a new web viewer solved the problem. I have two of these viewers right next to each other, each displaying different content; previously had trouble with both but today only the one on the left is overlapping. In case it helps resolve this, here is the code in the web address definition: WebviewerHTMLData ( Null ; Null ; // css HTMLCSS ( List ( "* { font: 11px Georgia, serif; }"; ".header { font: 18px \"Trebuchet MS\", Arial, sans-serif; margin-top: 10px; margin-bottom: 2px; border-bottom: 1px solid #919191; }"; "label { display: block; font-weight: bold; margin-left: -10px; }"; ".address, .phone, .email { margin-left: 20px; }" ) ); // body List( If ( not IsEmpty ( $$PERSON.ADDRESS ) ; HTMLWrapTag ( "Addresses" ; "div" ; "class=\"header\"" ) ); If ( not IsEmpty ( $$PERSON.ADDRESS ) ; RenderHTMLAddress ( $$PERSON.ADDRESS ) ); If ( not IsEmpty ( $$PERSON.ADDRESS[2] ) ; RenderHTMLAddress ( $$PERSON.ADDRESS[2] ) ); If ( not IsEmpty ( $$PERSON.ADDRESS[3] ) ; RenderHTMLAddress ( $$PERSON.ADDRESS[3] ) ); If ( not IsEmpty ( $$PERSON.ADDRESS[4] ) ; RenderHTMLAddress ( $$PERSON.ADDRESS[4] ) ); If ( not IsEmpty ( $$PERSON.ADDRESS[5] ) ; RenderHTMLAddress ( $$PERSON.ADDRESS[5] ) ); ) ) 'WebviewerHTMLData, HTMLCSS, HTMLWrapTag, and RenderHMLAddress are custom functions from Matt Petrowsky over at filemakermagazine.com and filemakerstandards.org.
June 30, 201114 yr I am afraid I cannot help without being able to reproduce the problem. I suggest you hunt down the difference by comparing the resulting HTML in a text editor. --- P.S. Please update your profile to reflect your platform.
Create an account or sign in to comment