The "content" variable is correct for GetLayoutObjectAttribute. Is it possble that you are grabbing the content before it has time to load on FileMaker Go? Keep in mind an iPad is slower than a computer. Maybe throw a pause script step in before reading. Then again, I've been doing this a lot less since the "Insert from URL" script step came out and it automatically pauses until it receives all of the HTML and saves it into a field for me to manipulate.
+1 for using Insert From URL. You may also want to test your capture for the presence of the "</html>" (closing html) tag to make sure you get everything if you decide to stick with the GetLayoutObjectAttribute approach.
When using a web viewer (instead of “Insert from URL”), I recommend using a loop:
First you get the contents, then you examine the contents you retrieved to see if it ends with what you expect to be the last bit of data (e.g. “</html>” or whatever is appropriate). If you don‘t see this “end of page” text, then pause briefly (fraction of a second), and go back to start of loop to try again to retrieve the contents, check for end of page, etc.
By the way, using a web viewer with the scheme I’ve outlined operates almost 10 times faster than using “Insert from URL” (in my tests, anyway). I have submitted this to FileMaker as a bug in “Insert from URL”, and I understand it has been referred to development to be addressed. I suspect at some point “Insert from URL” will be made much faster. But for now, I’m forced to use the old web viewer approach for acceptable performance.
Peace, love & brown rice,
FileMaker + Web: Design, Develop & Deploy
Certifications: FileMaker 9, 10, 11 & 12
Member: FileMaker Business Alliance
One Part Harmony <http://www.onepartharmony.com/>
Austin, Texas • USA
As an additional note:
In past versions of FmGo, it used to be that you could not get at the webviewer content if the content was XML instead of HTML.