Fórum gmap + primecafes #454513
08/09/2013
0
Boa tarde estou com problema no meu gmap, aconte que quando coloco o <p:gmap dentro de um <ui:composition ele não mostra nada.....mas ao returar o <ui:composition ele mostra o gmap porem fica fora do template...segue trecho de codigo em que o gmap nao funciona:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:p="http://primefaces.org/ui">
<f:view contentType="text/html"></f:view>
<h:head>
<script type="text/javascript"
src="http://maps.google.com/maps/api/js?sensor=false"></script>
</h:head>
<h:body>
<ui:composition template="/templates/template.xhtml">
<ui:define name="content">
<p:ajaxStatus
style="width:64px;height:64px;position:fixed;right:5px;bottom:5px">
<f:facet name="start">
<!-- <p:graphicImage value="/images/loading.gif" />-->
<p:graphicImage library="images" name="loading.gif" />
</f:facet>
<f:facet name="complete">
<h:outputText value="" />
</f:facet>
</p:ajaxStatus>
<h:form>
<p:commandButton action="/index.xhtml" ajax="false"
icon="ui-icon-home"
style="font-family: Verdana, Arial; font-weight:bold; padding-left: 5px;" />
<p:gmap center="-28.6404750, -53.0954092" zoom="13"
model="#{mbMap.advancedModel}" type="HYBRID"
style="width:600px;height:400px">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:p="http://primefaces.org/ui">
<f:view contentType="text/html"></f:view>
<h:head>
<script type="text/javascript"
src="http://maps.google.com/maps/api/js?sensor=false"></script>
</h:head>
<h:body>
<ui:composition template="/templates/template.xhtml">
<ui:define name="content">
<p:ajaxStatus
style="width:64px;height:64px;position:fixed;right:5px;bottom:5px">
<f:facet name="start">
<!-- <p:graphicImage value="/images/loading.gif" />-->
<p:graphicImage library="images" name="loading.gif" />
</f:facet>
<f:facet name="complete">
<h:outputText value="" />
</f:facet>
</p:ajaxStatus>
<h:form>
<p:commandButton action="/index.xhtml" ajax="false"
icon="ui-icon-home"
style="font-family: Verdana, Arial; font-weight:bold; padding-left: 5px;" />
<p:gmap center="-28.6404750, -53.0954092" zoom="13"
model="#{mbMap.advancedModel}" type="HYBRID"
style="width:600px;height:400px">
Aurelio Maica
Curtir tópico
+ 0
Responder
Clique aqui para fazer login e interagir na Comunidade :)