MapViewer Legend

Hallo,
I am dealing with mapviewer and the legend.
1: I can create a legend by defining each theme and the symbol I use for this. But is there a way that the legend is defined "automaticlly" so that I do not have to define each theme but mapviewer knows which themes are in this map and generates?
2: I can position the legend with position="NORTH_WEST". Are there other way to position it? By using numbers?
3: Are there code samples and where I could use?
4: I can not change the font of the text in the legend?
Thanks in advance Tig

Hi Tig,
Currently you can't generate the automatic legend based on the themes, and also you can't define a location (X,Y) to put the legend. We'll add these items on the enhancement list.
For item 4, MapViewer parses the legend font, however the API method setMapLegend does not have this parameter. We'll also add this enhancement. If you issue a XML request directly, you can define the font as:
<legend bgstyle="fill:#ffffff;fill-opacity:128;stroke:#ff0000"
          position="NORTH_WEST" font="Dialog">Next, is a sample of Java code to generate the structure to pass to the API method setMapLegend:
  String [][][]legenddata = new String[1][][];  // legend with one column
  legenddata[0] = new String[8][];    // column with 8 items
  for(int i=0;i<8;i++)
    legenddata[0] = new String[5]; // description of each item
legenddata[0][i][0] = null; // text
legenddata[0][i][1] = null; // style
legenddata[0][i][2] = "false"; // is title
legenddata[0][i][3] = null; // tab
legenddata[0][i][4] = "false"; // is separator
// <entry text="Map Legend" is_title="true" />
legenddata[0][0][0] = "Map Legend"; // text
legenddata[0][0][2] = "true"; // is title
// <entry style="M.STAR" text="center point" />
legenddata[0][1][0] = "center point"; // text
legenddata[0][1][1] = "M.STAR"; // style
// <entry style="M.CITY HALL 3" text="cities" />
legenddata[0][2][0] = "cities"; // text
legenddata[0][2][1] = "M.CITY HALL"; // style
// <entry is_separator="true" />
legenddata[0][3][4] = "true"; // is separator
// <entry style="C.ROSY BROWN STROKE" text="state boundary" />
legenddata[0][4][0] = "state boundary"; // text
legenddata[0][4][1] = "C.ROSY BROWN STROKE"; // style
// <entry style="L.PH" text="interstate highway" />
legenddata[0][5][0] = "interstate highway"; // text
legenddata[0][5][1] = "L.PH"; // style
// <entry text="County population:" />
legenddata[0][6][0] = "County population:"; // text
// <entry style="V.COUNTY_POP_DENSITY" tab="1" />
legenddata[0][7][1] = "V.COUNTY_POP_DENSITY"; // style
legenddata[0][7][3] = "1"; // tab
mapViewer.setMapLegend("#ffffff","255","#ff0000","MEDIUM","NORTH_EAST",legenddata);
Thanks for your comments.
Joao

Similar Messages

  • Mapviewer legend and note overlap

    I am using Mapviewer 11ea and wish to place a legend above a note in the SOUTH EAST corner of my map. The note is defined in the config file and the legend is provided in the map request. The legend itself seems to create a box larger than required and overlaps the note text below. See the image at http://www.geocities.com/ozspatial/legend-note-overlap.jpg showing the overlap and the large amount of white space at the bottom of the legend.
    The legend component of the request is from the default mapviewer request and looks like:
    <legend bgstyle="fill:#ffffff;stroke:#ff0000" profile="MEDIUM" position="SOUTH_EAST">
              <column>
                <entry text="Map Legend" is_title="true" />
                <entry style="M.STAR" text="center point" />
                <entry style="M.CITY HALL 3" text="cities" />
                <entry style="M.CITY HALL 4" text="big cities" />
                <entry is_separator="true" />
                <entry style="C.ROSY BROWN STROKE" text="state boundary" />
                <entry style="L.PH" text="interstate highway" />
                <entry text="County population:" />
                <entry style="V.COUNTY_POP_DENSITY" tab="1" />
              </column>
      </legend>Does anyone know how to reduce the white space in the legend or some other way to avoid the overlap? (whilst still placing both note and legend in the SOUTH EAST corner)
    thanks,
    Ross.

    Hi Ross,
    I don't think you will be able to reduce the white space at the bottom, but there are some parameters on the legend that you can use.
    1) In overlap situations you can set the transparency of the legend:
    <legend bgstyle="fill:#ffffff;fill-opacity:128;stroke:#ff0000" profile="MEDIUM" position="SOUTH_EAST">
    2) For the profile value there is an internal size defined. In your figure I can note that the advanced style items are also overlapping, which means that the internal size MEDIUM seems not appropriate for this legend. You can assign a height for a legend entry:
    <entry style="V.CA INCOME 2" tab="1" height="150"/>
    3) With version 11 there are two new parameters (location_x and location_y) for the legend that can be used to put the legend in any position. In this case the position attribute is ignored if defined.
    <legend bgstyle="fill:#ffffff;fill-opacity:128;stroke:#ff0000" profile="MEDIUM" location_x="20" location_y="50">
    Joao

  • Mapviewer: circles in legend

    Hi,
    for some reason Mapviewer renders circle-markers as ellipse. The style is dynamic:
    mv.addMarkerStyle("SL.OK", MarkerStyleModel.MARKER_CIRCLE, "black", "green", null, null, null, "5");
    Here is a screenshot:
    http://www.imagehosting.com/show.php/214285_omsmaplegend.png.html
    regards,
    Oyvind Idland

    Hi,
    here is the relevant (I think) lines. Note that there are minor changes from when I made the screenshot, the size is "SMALL" instead of "MEDIUM" + some text changes.
    <box>
    <coordinates>579770.2414294558,6632093.360589514 580111.8134053203,6632264.993850242</coordinates>
    </box>
    <legend bgstyle="fill:#e0e0e0;fill-opacity:128;stroke:black" profile="SMALL" location_x="10" location_y="10" font="Dialog">
    <column>
    <entry text="Tegnforklaring" is_title="true" />
    <entry style="SL.OK" text="Ok" />
    <entry style="SL.ERROR" text="Feil" />
    <entry style="SL.FIXED" text="Reparert nylig" />
    </column>
    </legend>
    <scale_bar position="SOUTH_EAST" mode="METRIC_MODE" color1="#64c864" color2="#c86464" length_hint="0" label_color="#000000" />
    <themes>
    </themes>
    <styles>
    <style name="SL.ERROR">
    <svg>
    <g class="marker" style="stroke:black;fill:red;width=10;height=10">
    <polygon points="201,200,0,200,101,0" />
    </g>
    </svg>
    </style>
    <style name="SL.OK">
    <svg>
    <g class="marker" style="stroke:black;fill:green;">
    <circle r="5" />
    </g>
    </svg>
    </style>
    <style name="SL.FIXED">
    <svg>
    <g class="marker" style="stroke:black;fill:blue;width=10;height=10">
    <polygon points="0,0,0,100,100,100,100,0,0,0" />
    </g>
    </svg>
    </style>
    </styles>
    Regards,
    Oyvind Idland

  • Legend in MapViewer

    I'm modifying the provided demo-files wich are using the MapViewer-bean. Now I want to add a legend.
    I can't find out how to do this.
    In another demo-file is an example, but is using the tags.
    Is there a way to create a legend without using the tags but with using the JavaBean?

    Although it is possible to include a map legend specification in each and every xml map request,
    currently there is no Java api that lets you do that. The JSP tag demo is simply submitting a manually created XML legend request and extracting the url to the legend image itself.
    If you dont need a legend inside each map generated by mapviewer, you can simply pre-generate the map legend through a standalone XML request using one of the forms in the mapviewer homepage. Then save the generated image and place it somewhere in your final web page.
    lj

  • Problem in Legend Map Request

    Hi All,
    I am generating a map request to get a legend in PDF format as follows.
    <?xml version="1.0" standalone="yes"?><map_request
    datasource="MYDATASOURCE" format="PDF_STREAM" width="1188" height="840"
    antialiase="true" srid="8292"><legend bgstyle="fill:#FFFFE8;stroke:#708090;"
    position="SOUTH_EAST" profile="SMALL">
    <column>
    <entry text="LEGEND WITH PROBLEM" is_title="true" />
    <entry style="" text="up to 444.306.878" />
    <entry style="" text="204.299.813 a 444.306.878" />
    <entry style="" text="138.180.596 a 204.299.813" />
    <entry style="" text="118.706.493 a 138.180.596" />
    <entry style="" text="100.910.715 a 118.706.493" />
    <entry style="" text="74.385.591 a 100.910.715" />
    <entry style="" text="38.539.881 a 74.385.591" />
    <entry style="" text="down to 38.539.881" />
    </column>
    </legend>
    </map_request>
    The problem is that the large numbers exceeds the legend size. This just happens with the PDF format.
    I dont want to use the LARGE profile because gets too big.
    Is there any workaround to this problem?
    Thanks.
    Cleber

    Hi Cleber,
    which MapViewer version are you using? This may be related with the PDF graphics library version. This library has been modified to better handle the legend texts. I tested your request and it appears to be OK with the current library. You can send me (by email) a picture of your legend, and I will confirm if this has been fixed.
    Joao

  • Legend in manual mode - Background color

    Hi all,
    To create legend in manual mode I am using following request URL for a style image.
    http://127.0.0.1:8988/mapviewer/omserver?sty=L.ROAD&w=20&h=20&ds=cescdatasource
    Here if the color of style is white (For example white color line style) then it won't be visible. Can I set background color?. I need different background color instead of white.
    Thanks,
    Sujnan

    Either set the background color for the MapDecoration or for the table in which you display the legend or both.
    e.g. (modification of tutorial 36 Map Legend)
    // get the container DIV and set the background color to light blue
    var legendDiv = legend.getContainerDiv();
    legendDiv.style.backgroundColor = "AliceBlue"; //color name may not work in all browsers
    function buildLegend(baseURL)
    var html = "<table *bgcolor='gray'* border=0> <tr><td><img src="+baseURL+"/omserver?sty=L.PH&w=45&h=20&ds=mvdemo></td><td> Highways </td></tr>" +
    " <tr><td><img src="+baseURL+"/omserver?sty=M.CITY+HALL+3&w=20&h=20&ds=mvdemo></td><td> Cities </td></tr>" +
    "</table>";
    return html;
    }

  • Legend map request with german umlaut

    Hello,
    i have a problem sending a legend map request that contains a german umlaut.
    I'm trying to use the pl/sql function for sending and parsing a xml request from the mapviewer documentation (chapter 3.1.16, example 3-19).
    my request looks like this
    <map_request datasource="mvdemo" format="PNG_URL">
      <legend bgstyle="fill:#ffffff;stroke:#ffffff" profile="MEDIUM">
        <column>
          <entry style="C.YELLOW" text="Übernahme"/>    
        </column>
      </legend>
    </map_request>The resulting image does not contain the umlaut Ü but a little square instead.
    I tried replacing the Ü with Ü ;
    <map_request datasource="mvdemo" format="PNG_URL">
      <legend bgstyle="fill:#ffffff;stroke:#ffffff" profile="MEDIUM">
        <column>
          <entry style="C.YELLOW" text="Übernahme"/>    
        </column>
      </legend>
    </map_request>This works when i manually send the request on the mapviewer map request page, but it doesn't work when i use the pl/sql function.
    The documentation says that the request has to be url encoded, so i tried using utl_url.escape on the whole request and on only the umlaut. Both doesn't work.
    Thanks for help in advance,
    Dirk

    Hi Cleber,
    which MapViewer version are you using? This may be related with the PDF graphics library version. This library has been modified to better handle the legend texts. I tested your request and it appears to be OK with the current library. You can send me (by email) a picture of your legend, and I will confirm if this has been fixed.
    Joao

  • Differences between legend in png and pdf output

    Hello,
    i noticed that there is a difference in the legend output of a transparent color style between a png and a pdf output in MapViewer version Ver11_B071001.
    Lets say i have a sytle with 50% opacity like this:
    <?xml version="1.0" standalone="yes"?>
    <svg width="1in" height="1in">
      <desc/>
      <g class="color" style="stroke:#00CC00;stroke-width:2.0;fill:#00CC00;fill-opacity:127">
        <rect width="50" height="50"/>
      </g>
    </svg>If the mapresponse is a png, the style is displayed correct in the legend (with 50% opacity).
    In the pdf output the opacity looks like 100%, so no transparency at all.
    The actuall displayed geometries are displayed with the correct opacity, but not in the legend.
    Is there a workaround for this behavior?
    Thanks for help in advance,
    Dirk

    Hi Dirk,
    transparency is not yet supported in all cases for the PDF graphics.
    Joao

  • Embedded Legend in JSP file

    I would like to embed my legend within my map request. I can display the legend on my page within a Table Row, but I would prefer it located inthe Southwest corner of my map image. Can this be done? I have seen it in XML done this way.
    Here is my legend code as well as my map display code.
    Thanks!
    <tr><td><mv:makeLegend id="myLegend">
    <legend bgstyle="fill:#ffffff;stroke:#ff0000" profile="SMALL" position="SOUTHWEST">
    <column>
    <entry text="Map Legend:" is_title="true" />
    <entry style="M.GREEN" text="No Outages Reported" />
    <entry style="M.RED" text="Outage Reported" />
    <entry style="M.AMBER" text="Degraded Status Reported" />
    </column>
    </legend>
    </mv:makeLegend>
    <IMG SRC="<%=myLegend%>"></td></tr>
    <tr align="center">
    <td valign="top" align="center">
    <input type="image"
    border="1"
    src="<mv:getMapURL />"
    name="userClick"
    alt="Click on the map for selected action">
    </td></tr>

    Hi,
    you can't use the makeLegend tag to embed it on map, but you can add an API method on your jsp code to add the legend. This is an example:
    <%@ taglib uri="http://xmlns.oracle.com/j2ee/jsp/tld/spatial/mvtaglib.tld" prefix="mapviewer"%>
    <%@ page contentType="text/html;charset=windows-1252"%>
    <%@ page import="oracle.lbs.mapclient.MapViewer" %>
    <html>
      <head>
        <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
        <title>untitled</title>
      </head>
      <body title="MapViewer WebMap">
        <DIV align="center">
          <mapviewer:init url="http://stadb35.us.oracle.com:8888/mapviewer/omserver" datasource="mvdemo" id="mvHandle"/>
          <mapviewer:setParam basemap="density_map" width="600" height="450" antialiasing="true" title="My Web Map" centerX="-122.4" centerY="37.8" size="10"/>
        <%
          MapViewer mv = (MapViewer) session.getAttribute("mvHandle");
          mv.setMapLegend("<legend bgstyle=\"fill:#ffffff;stroke:#ff0000\" " +
                          "profile=\"MEDIUM\" position=\"SOUTHWEST\">\n" +
                          "<column>\n" +
                          "<entry text=\"Map Legend:\" is_title=\"true\" />\n " +
                          "<entry style=\"V.COUNTY_POP_DENSITY\" tab=\"1\"/>\n " +
                          "</column>\n " +
                          "</legend>");
        %>
          <mapviewer:run/>
        </DIV>
        <img src="<mapviewer:getMapURL />"/>
      </body>
    </html>

  • Mapviewer errorhandling

    Hi,
    is there a way to handle errors, i.e database connection issues and similar ?
    I simulated a broken database-connection by blocking out the server. When making a request, the server throws java.sql.SQLException's on the console. However, in my client, I get this response:
    <?xml version="1.0" encoding="UTF-8"?>
    <map_response>
    <map_image>
    <map_content url="http://localhost:8888/mapviewer/images/omsmap5_44.png?refresh=-1938097623516322933" />
    <box srsName="sdo:32632">
    <coordinates>586543.8605697479,6642771.753227037 587796.7852685659,6643450.6823 58752</coordinates>
    </box>
    <xfm matrix="0.8968680735991478 0.0 0.0 -0.8968680735992433 586543.8605697479 6643450.682358752" />
    <WMTException version="1.0.0" error_code="SUCCESS"></WMTException>
    </map_image>
    </map_response>
    There is no exceptions thrown on the client-side here, and I get a blue image with scalebar/legend.

    Hello user 1157569,
    you should find the mapviewer.ear in the downloaded "fmw_12.1.3.0.0_mapviewer.jar".
    Unpack the "fmw_12.1.3.0.0_mapviewer.jar" (rename to "fmw_12.1.3.0.0_mapviewer.zip" for instance)
    Go to \Disk1\stage\Components\oracle.mapviewer\12.1.3.0.0\DataFiles\
    Unpack "filegroup1.jar"
    Go to \modules\oracle.mapviewer\mapviewer.ear
    Enjoy the day
    Kind regards
    /kk

  • Legend display and decimal places

    Hi all,
    I'm using mapviewer to create thematic maps and the Ranged Bucket Advanced Style (XML below) with whole numbers but when I generate the legend each range has a ".0" on the end of it. Is there a way of turning this off?
    <?xml version="1.0" standalone="yes"?>
    <non_map_request>
    <add_style name="V.POLK THEMATIC" >
    <AdvancedStyle>
    <BucketStyle>
    <Buckets>
    <RangedBucket low="57" high="146" style="SCOTT:C.IMQ_1"/>
    <RangedBucket low="146" high="307" style="SCOTT:C.IMQ_2"/>
    <RangedBucket low="307" high="504" style="SCOTT:C.IMQ_3"/>
    <RangedBucket low="504" high="714" style="SCOTT:C.IMQ_4"/>
    <RangedBucket low="714" high="1359" style="SCOTT:C.IMQ_5"/>
    </Buckets>
    </BucketStyle>
    </AdvancedStyle>
    </add_style>
    </non_map_request>
    The legend however has these ranges :
    57.0 - 146.0
    146.0 - 307.0
    307.0 - 504.0
    504.0 - 714.0
    714.0 - 1359.0
    Any thoughts anyone? Forgive me if this has been posted before but the forum search doesn't appear to be working right now!
    Thanks
    Steve

    Hi Steve,
    at this time there is no way to turn this off.
    Joao

  • Mapviewer demo mapinit.jsp with svg doesn't work with jdeveloper

    hi ng,
    i tried the source code for the svg-sample in jdeveloper and first of all jdeveloper dislikes the line "<embed id="map" src="<%= mv.getGeneratedMapImageURL() %>...". after "embed" a green line is to be seen.
    When i start the sample the map looks okay, but when i want to hide a theme (or zoom), i get the internet_explorer-message "error on the page".
    "themeVisibleArray[idx]='false';" goes right but the next line occurs the error: "map.window.hideTheme(theme) ;"
    map is not known at this place, it seems to me.
    who can help (please)?
    greetings
    thomas

    hi,
    i still have a problem. i can work on an existing svg-map but not on a just generated svg-map. zoomin2 works.
    here's the code:
    <%@ taglib uri="http://xmlns.oracle.com/j2ee/jsp/tld/spatial/mvtaglib.tld" prefix="mapviewer"%>
    <%@ page contentType="text/html;charset=UTF-8"%>
    <%@ page import="java.io.*"%>
    <%@ page import="java.net.*"%>
    <%@ page import="java.util.*"%>
    <%@ page import="oracle.lbs.mapclient.*"%>
    <%@ page import="oracle.lbs.mapcommon.MapResponse"%>
    <%@ page import="java.awt.Dimension"%>
    <%
    String sizeStr = request.getParameter("initsize") ;
    String scaleStr = request.getParameter("scale") ;
    String cxStr = request.getParameter("centerX") ;
    String cyStr = request.getParameter("centerY") ;
    String baseMap = request.getParameter("basemap");
    String _width = request.getParameter("width") ;
    String _height = request.getParameter("height") ;
    String _infoon = request.getParameter("infoon") ;
    String action = request.getParameter("action");
    boolean infoon = false;
    boolean recenter = false ;
    boolean zoomin = false ;
    boolean zoomin2 = false ;
    int width = 600 ;
    int height = 400 ;
    if(_width!=null && _height!=null)
    try
    width = Integer.parseInt(_width) ;
    catch(Exception e){}
    try
    height = Integer.parseInt(_height) ;
    catch(Exception e){}
    if(baseMap==null) baseMap = "demo_map";
    double size = 0.2 ;
    try
    size = Double.parseDouble(sizeStr) ;
    catch(Exception e){}
    double scale = 2 ;
    try
    scale = Double.parseDouble(scaleStr) ;
    catch(Exception e){}
    double cx = -122.2615 ;
    try
    cx = Double.parseDouble(cxStr) ;
    catch(Exception e){}
    double cy = 37.5266 ;
    try
    cy = Double.parseDouble(cyStr) ;
    catch(Exception e){}
    String dataSrc = request.getParameter("datasrc");
    boolean newSession = false;
    // retrieve mapviewer client handle from session
    MapViewer mv = (MapViewer) session.getAttribute("mvhandle");
    boolean sessionExpired = false ;
    if(mv==null || request.getParameter("initflag")!=null)
    if(request.getParameter("initflag")==null)
    sessionExpired = true ;
    else
    //initializes MapViewer bean instance
    newSession = true;
    String mvURL = request.getParameter("mvurl");
    // create a new mapviewer client handle
    mv = new MapViewer(mvURL);
    mv.setDataSourceName(dataSrc);
    mv.setImageFormat(MapResponse.FORMAT_SVGZ_URL);
    /* the javascript function svgClicked will be called when the svg map
    is clicked. svgClicked is defined in this page, it recenters or zoomins
    the map. */
    mv.setSVGOnClick("svgClicked") ;
    /* initial themes (from an existing base map) */
    mv.addThemesFromBaseMap(baseMap);
    mv.setSVGZoomLevels(3);
    /* disable the builtin navigation bar */
    mv.setShowSVGNavBar(false) ;
    mv.setMapTitle(" MAP TITLE ");
    mv.setMapLegend(
    "<legend bgstyle=\"fill:#ffffff;stroke:#ff0000\" profile=\"MEDIUM\" position=\"SOUTH_EAST\">"+
    " <column>"+
    " <entry text=\"Map Legend\" is_title=\"true\" />"+
    " <entry style=\"M.CITY HALL 3\" text=\"cities\" />"+
    " <entry style=\"M.CITY HALL 4\" text=\"big cities\" />"+
    " <entry style=\"L.PH\" text=\"interstate highway\" />"+
    " </column></legend>");
    mv.setDeviceSize(new Dimension(width, height));
    session.setAttribute("mvhandle", mv); // keep client handle in the session
    String themes[] = new String[0] ;
    if(!sessionExpired)
    themes = mv.getThemeNames() ;
    mv.setCenter(cx, cy);
    mv.setSize(size);
    mv.setSVGZoomRatio(scale) ;
    mv.setSVGShowInfo(infoon);
    String[] checkedThemes = request.getParameterValues("_mthemev_");
    if(checkedThemes!=null && checkedThemes.length>0)
    Hashtable checked = new Hashtable(30) ;
    for(int i=0; i<checkedThemes.length; i++)
    checked.put(checkedThemes, checkedThemes[i]) ;
    for(int i=0; i<themes.length; i++)
    if(checked.get(themes[i])!=null)
    mv.setThemeVisibleInSVG(themes[i], true);
    else
    mv.setThemeVisibleInSVG(themes[i], false) ;
    mv.run() ;
    %>
    <html>
    <head>
    <title>untitled</title>
    <%-- <embed id="map" name="map" src="<%= mv.getGeneratedMapImageURL() %>" width="<%= width %>" height="<%= height %>"></embed> --%>
    <%-- src="images/omsmap3_56.svgz" --%>
    <%-- src="<%= mv.getGeneratedMapImageURL() %>" --%>
    <%-- <object name="map" data="images/test_svg.svgz" type="image/svg+xml" width="800" height="600" standby="Warte noch ein Weilchen..."> --%>
    <%-- </object> --%>
    <script type="text/javascript">
    var mapSize = <%= size %> ;
    var scale = <%= scale %> ;
    var width=<%= width%> ;
    var height=<%= height%> ;
    var rcx = <%= cx %> ;
    var rcy = <%= cy %> ;
    var cx = <%= width/2%> ;
    var cy = <%= height/2%> ;
    var disabled = true ;
    // var themeVisibleArray = ...
    var info = <%= infoon %> ;
    var legend = false ;
    var clickZoomin = <%= zoomin %> ;
    var clickRecenter = <%= recenter %> ;
    function zoomin()
    map.window.setZoomRatio(1.1);
    function zoomin2()
    map2.window.setZoomRatio(1.1);
    </script>
    </head>
    <body>
    <P>
    <form method="GET" action="test2.jsp">
    <P>Name:
    <input type="text" size="60" name="name" value="<%= mv.getGeneratedMapImageURL() %>"/>
    <input type="text" size="60" name="datasrc" value="<%= request.getParameter("datasrc") %>"/>
    <input type="text" size="60" name="basemap" value="<%= request.getParameter("basemap") %>"/>
    <input type="text" size="60" name="centerX" value="<%= request.getParameter("centerX") %>"/>
    <input type="text" size="60" name="centerY" value="<%= request.getParameter("centerY") %>"/>
    <input type="text" size="60" name="initsize" value="<%= request.getParameter("initsize") %>"/>
    <input type="text" size="60" name="width" value="<%= request.getParameter("width") %>"/>
    <input type="text" size="60" name="height" value="<%= request.getParameter("height") %>"/>
    <input type="text" size="60" name="type" value="<%= request.getParameter("type") %>"/>
    </P>
    <P>
    <input type="SUBMIT" value="Submit"/>
    </P>
    </form>
    </P>
    <table>
    <tr>
    <td colspan="2">
    <I>URL</I>[<B><%=mv.getGeneratedMapImageURL()%></B>]
    </td>
    </tr>
    </table>
    <%-- images/test_svg.svgz --%>
    <embed src="<%= mv.getGeneratedMapImageURL() %>" name="map" id="map" width="500" height="500" type="image/svg+xml" />
    <embed src="images/test_svg.svgz" name="map2" id="map2" width="500" height="500" type="image/svg+xml" />
    <%-- <embed id="map" src="<%= mv.getGeneratedMapImageURL() %>" width="<%= width %>" height="<%= height %>"></embed> --%>
    <FORM name="form" action="test2.jsp" method="GET" >
    <input type="radio" name="action" value="zoomin" <%= zoomin?"checked":"" %> onclick="zoomin()" ><B>Zoom In</B>
    <input type="radio" name="action2" value="zoomin2" <%= zoomin2?"checked":"" %> onclick="zoomin2()" ><B>Zoom In2</B>
    <input type="hidden" name="width" value="<%=width%>"/>
    <input type="hidden" name="height" value="<%=height%>"/>
    <input type="hidden" id="cx" name="centerX" value=""/>
    <input type="hidden" id="cy" name="centerY" value=""/>
    <input type="hidden" id="size" name="initsize" value=""/>
    <input type="hidden" id="scale" name="scale" value=""/>
    <input type="hidden" id="infoon" name="infoon" value="<%=(infoon?"yes":"no")%>" />
    </FORM>
    <br>
    <P> 
    </P>
    </body>
    </html>

  • Map Legend

    Hi All!
    Is it possible to get the map legend in a separated image using the MapViewer API?
    I have done it using the MapViewer tag library, with the <mv:makelegend> ...
    Is it possible not use the tag library, but the API?
    Thank you!
    Carlos

    Carlos,
    It is indeed possible to send a map request, using the XML API, for a nonembedded legend (return a legend without a map). To do this, simply send a standard MapViewer request, without a basemap, using the legend tags:
    <?xml version="1.0" standalone="yes"?>
    <map_request
    title="Oracle LBS MAP"
    datasource = "mvdemo"
    width="640"
    height="480"
    bgcolor="#a6cae0"
    antialiase="false"
    format="PNG_STREAM">
    <legend bgstyle="fill:#ffffff;stroke:#ff0000" profile="MEDIUM" >
    <column>
    <entry text="Map Legend" is_title="true" />
    <entry style="M.STAR" text="center point" />
    <entry style="M.CITY HALL 3" text="cities" />
    <entry style="M.CITY HALL 4" text="big cities" />
    <entry is_separator="true" />
    <entry style="C.ROSY BROWN STROKE" text="state boundary" />
    <entry style="L.PH" text="interstate highway" />
    <entry text="County population:" />
    <entry style="V.COUNTY_POP_DENSITY" tab="1" />
    </column>
    </legend>
    </map_request>
    Hope this helps.
    -Justin

  • MapViewer response

    We're using Mapviewer 10.1.2 for our app and I'm trying to get list of themes that are currently displayed in the map so I can include them in the legend. The map response string should list all themes that have any features on the currently generated map (i'm using the URL formats so I have the responseString from the servlet) but it doesn't return me anything? Even when it generates lot of themes - it doesn't even have the themes element. Has anybody have any idea why is that?
    thanks Jan
    PS:
    This is the generated xml response
    <?xml version="1.0" encoding="UTF-8"?>
    <map_response>
    <map_image>
    <map_content url="http://10.64.64.104:7777/mapviewer/images/omsmap144_96.png?refresh=5234959502344620123" />
    <box srsName="default">
    <coordinates>
    1733750.0000000002,5417083.333333334 1759583.3333333333,5442916.666666667 </coordinates>
    </box>
    <xfm matrix="43.05555555555504 0.0 0.0 -43.05555555555504 1733750.0000000002 5442916.666666667" />
    <WMTException version="1.0.0" error_code="SUCCESS">
    </WMTException>
    </map_image>
    </map_response>

    This information is now listed on the response of version 10.1.3.1.
    <box srsName="default">
    <coordinates></coordinates>
    </box>
    <themes>
    <theme name="COUNTY_TH" />
    </themes>
    ...

  • Anyone having experience with MapViewer

    Because I don't find much topics about MapViewer in this forum or documentation on the whole Oracle-site I wonder if there are people who worked successfully with MapViewer.
    I've got it going. The provided demo are working even with my own spatial data.
    But now I want to extent the demos to meet my demands/requests. But I find it very difficult to find sample code. I'm specially looking for sample code to use MapViewer in a java-applet and code using jsp and the javabean and creating a dynamic legend.
    So my questions are:
    * Are there people who use MapViewer and what are your experiences with it.
    * Where can I find other sample code than the demo code provided by Oracle.
    Thanks in advance.

    Hi Paul
    I am currently doing a project namely "LOCATION BASED SERVICES AND PROXIMITY ANALYSIS". It's basically a GIS through which users can query the desired objects (SCHOOLS,HOTELS,ATMs etc) that are close to there location.The response is in the form of a map.
    I am using mapviewer as a middle tier redering tool.
    Would you plz help me that in which format do we load maps and how do we define spatial data that is to be used by mapviewer.
    regards

Maybe you are looking for

  • I can't install CS 5.5 Production Premium on my new iMac. I no longer have the CD's to reinstall. I

    I can't install CS 5.5 Production Premium on my new iMac. I no longer have the CD's to reinstall. I downloaded the software using this link from Adobe http://helpx.adobe.com/creative-suite/kb/cs5-5-product-downloads.html . When I try to put my Serial

  • Connecting Beige G3 to MacBook Pro???

    Hi Gurus: I packed my old beige G3 desktop (233 MHz; ah, nostalgia...) somewhere around May 2004 and stuffed it in a corner of my attic. Now I would like to access some Really Old Data, and was wondering whether I could somehow hook it up to my MacBo

  • DEFAULT ROLE FOR USER

    I swich to Oracle11g express and create user CREATE USER LEO IDENTIFIED BY xy DEFAULT TABLESPACE USERS TEMPORARY TABLESPACE TEMP PROFILE DEFAULT ACCOUNT UNLOCK; -- 3 Roles for LEO GRANT AUTHENTICATEDUSER TO LEO; GRANT CONNECT TO LEO; GRANT FER_ADMIN

  • Downloading to my new iMac ?

    Hi Just puchased a new iMac (Previously only used Microsoft) and need to install my photoshop program. Problem is my iMac does not have a dvd drive. The box shows Adobe Photoshop Elements11 & Adobe Premiere Elements 11 and also has two serial numbers

  • Scanning Access Points configured with JAPAN channels - 184,188 etc

    Hi, I have configured the below mentioned configuration for my Access Point. These wireless networks are not appearing in windows client network list. I have tried explicit scan also. Still it is not showing networks with 184,188 channels. But it is