[mapguide-users] Bypassing initial view at startup

gingerbbm stuart.jones at jacobs.com
Thu Aug 28 13:40:52 EDT 2008


This is an old thread but very important for me right now.

I want to set the initial view (coords and scale) of a map and have been
struggling conceptually with how to implement this. I have a page containing
an iframe. The iframe's src attribute is the path to a MapGuide web layout,
e.g.

/mapguide/mapviewerajax/?WEBLAYOUT=Library://Trial/Trial.WebLayout&LOCALE=en

Originally I thought that I would need to interrupt the initial map load to
dabble with the web layout's XML, but http://tinyurl.com/6jkdyj talks about
creating a copy of the web layout, making the desired changes, and saving it
to the session, and using the copy. So would the following be the right way
to go?

1. Change the main page's iframe to have no src attribute specified
2. On page load, call a PHP script to create a web layout in the session
based upon the one in the library
3. Dynamically set the iframe's src to be something like
"...?WEBLAYOUT=Session://..."

I hope one of you seasoned MapGuide developers can put me straight on this!
Thanks for your time.

Stuart
-- 
View this message in context: http://www.nabble.com/Bypassing-initial-view-at-startup-tp9623015p19205498.html
Sent from the MapGuide Users mailing list archive at Nabble.com.



More information about the mapguide-users mailing list