Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-11 Thread thomas bonfort
You could use a regex in your database query. With '^%nom%$' in your
expression, and .* as your default_nom
On Mar 11, 2016 4:00 PM, "milad nidal"  wrote:

>
> But this example is using the same layer twice which I do not want.. Even
> in this example if we do not use value  we get nothing and only one layer
> will be visualised..
>
> Maybe I was not clear enough in my question.. I want to visualise all the
> municipalities then I want to apply the filter to visualize only one. I
> thought maybe there is something like ‘default_value’ ‘all’ J.
>
>
>
> thanks
>
> On Fri, Mar 11, 2016 at 9:38 AM,  wrote:
>
>> Here is a full example with a default value also:
>>
>>
>> http://linfiniti.com/2011/09/making-the-most-of-umn-mapserver-runtime-variable-substitution/
>>
>> /Lars S.
>>
>> --
>> -Originalmeddelande-
>> Från: "milad nidal" 
>> Till: "Richard Greenwood" , "MapserverList
>> OSGEO" 
>> Datum: 2016-03-11 14:31
>> Ämne: Re: [mapserver-users] Runtime variable Substitution Filter
>>
>> Could you please explain more about how to do it (the first time which
>> I'm using this variable)..
>>
>> Do you mean that I use 'default_nom' ' aaa' in the layer metadata (it
>> does not work).. where I should put the default value?
>>
>> Thanks
>>
>> On Thu, Mar 10, 2016 at 11:06 PM, Richard Greenwood <
>> richard.greenw...@gmail.com> wrote:
>>
>>> Michael's suggestion is very good. Another method would be to define the
>>> later twice with two different names and no filter in one of the
>>> definitions. That would also allow you to style the layer differently which
>>> might be desirable.
>>>
>>> Rich
>>>
>>> On Thu, Mar 10, 2016 at 6:44 PM, Michael Smith <
>>> michael.smith.e...@gmail.com> wrote:
>>>
>>>> You can set a default value for your layer when no value is set. What I
>>>> do is set it to something like 1=1 and then all values will display.
>>>> http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url
>>>>
>>>>
>>>>
>>>> Michael Smith
>>>> Remote Sensing/GIS Center
>>>> US Army Corps of Engineers
>>>>
>>>> On Mar 10, 2016, at 8:36 PM, milad nidal < miladnidal2...@gmail.com>
>>>> wrote:
>>>>
>>>> Hi,
>>>>
>>>> I'm using Runtime variable Substitution (FILTER "nom in (
>>>> %municipalitylist% )") to chose one municipality from a list and it is
>>>> going good. But how I can visualize all the municipalities in the layer?
>>>> Is-it possible to ignore the filter?
>>>>
>>>>
>>>>
>>>> Thanks
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>>
>>>> ___
>>>> mapserver-users mailing list
>>>> mapserver-users@lists.osgeo.org
>>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>>
>>>
>>>
>>>
>>> --
>>> Richard W. Greenwood, PLS
>>> www.greenwoodmap.com
>>>
>>
>> --
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>>
>> --
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-11 Thread milad nidal
But this example is using the same layer twice which I do not want.. Even
in this example if we do not use value  we get nothing and only one layer
will be visualised..

Maybe I was not clear enough in my question.. I want to visualise all the
municipalities then I want to apply the filter to visualize only one. I
thought maybe there is something like ‘default_value’ ‘all’ J.



thanks

On Fri, Mar 11, 2016 at 9:38 AM,  wrote:

> Here is a full example with a default value also:
>
>
> http://linfiniti.com/2011/09/making-the-most-of-umn-mapserver-runtime-variable-substitution/
>
> /Lars S.
>
> --
> -Originalmeddelande-
> Från: "milad nidal" 
> Till: "Richard Greenwood" , "MapserverList
> OSGEO" 
> Datum: 2016-03-11 14:31
> Ämne: Re: [mapserver-users] Runtime variable Substitution Filter
>
> Could you please explain more about how to do it (the first time which I'm
> using this variable)..
>
> Do you mean that I use 'default_nom' ' aaa' in the layer metadata (it does
> not work).. where I should put the default value?
>
> Thanks
>
> On Thu, Mar 10, 2016 at 11:06 PM, Richard Greenwood <
> richard.greenw...@gmail.com> wrote:
>
>> Michael's suggestion is very good. Another method would be to define the
>> later twice with two different names and no filter in one of the
>> definitions. That would also allow you to style the layer differently which
>> might be desirable.
>>
>> Rich
>>
>> On Thu, Mar 10, 2016 at 6:44 PM, Michael Smith <
>> michael.smith.e...@gmail.com> wrote:
>>
>>> You can set a default value for your layer when no value is set. What I
>>> do is set it to something like 1=1 and then all values will display.
>>> http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url
>>>
>>>
>>>
>>> Michael Smith
>>> Remote Sensing/GIS Center
>>> US Army Corps of Engineers
>>>
>>> On Mar 10, 2016, at 8:36 PM, milad nidal < miladnidal2...@gmail.com>
>>> wrote:
>>>
>>> Hi,
>>>
>>> I'm using Runtime variable Substitution (FILTER "nom in (
>>> %municipalitylist% )") to chose one municipality from a list and it is
>>> going good. But how I can visualize all the municipalities in the layer?
>>> Is-it possible to ignore the filter?
>>>
>>>
>>>
>>> Thanks
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>>
>>> ___
>>> mapserver-users mailing list
>>> mapserver-users@lists.osgeo.org
>>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>>
>>
>>
>>
>> --
>> Richard W. Greenwood, PLS
>> www.greenwoodmap.com
>>
>
> --
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
>
> --
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-11 Thread lars . schylberg
Here is a full example with a default value also:

http://linfiniti.com/2011/09/making-the-most-of-umn-mapserver-runtime-variable-substitution/

/Lars S.


-Originalmeddelande-
Från: "milad nidal" 
Till: "Richard Greenwood" , "MapserverList OSGEO" 

Datum: 2016-03-11 14:31
Ämne: Re: [mapserver-users] Runtime variable Substitution Filter


Could you please explain more about how to do it (the first time which I'm 
using this variable)..

Do you mean that I use 'default_nom'   ' aaa' in the layer metadata (it does 
not work).. where I should put the default value?

 

Thanks


On Thu, Mar 10, 2016 at 11:06 PM, Richard Greenwood < 
richard.greenw...@gmail.com> wrote: 
Michael's suggestion is very good. Another method would be to define the later 
twice with two different names and no filter in one of the definitions. That 
would also allow you to style the layer differently which might be desirable.



Rich


On Thu, Mar 10, 2016 at 6:44 PM, Michael Smith < michael.smith.e...@gmail.com> 
wrote: 

You can set a default value for your layer when no value is set. What I do is 
set it to something like 1=1 and then all values will display. 
http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url




Michael Smith 
Remote Sensing/GIS Center
US Army Corps of Engineers

On Mar 10, 2016, at 8:36 PM, milad nidal < miladnidal2...@gmail.com> wrote: 




Hi,

I'm using Runtime variable Substitution (FILTER "nom in ( %municipalitylist% 
)") to chose one municipality from a list and it is going good. But how I can 
visualize all the municipalities in the layer? Is-it possible to ignore the 
filter?  







Thanks



___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

___ 
mapserver-users mailing list 
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users




-- 

Richard W. Greenwood, PLS 
www.greenwoodmap.com


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

-- 

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-11 Thread milad nidal
Could you please explain more about how to do it (the first time which I'm
using this variable)..

Do you mean that I use ‘default_nom’   ‘ aaa’ in the layer metadata (it
does not work).. where I should put the default value?



Thanks

On Thu, Mar 10, 2016 at 11:06 PM, Richard Greenwood <
richard.greenw...@gmail.com> wrote:

> Michael's suggestion is very good. Another method would be to define the
> later twice with two different names and no filter in one of the
> definitions. That would also allow you to style the layer differently which
> might be desirable.
>
> Rich
>
> On Thu, Mar 10, 2016 at 6:44 PM, Michael Smith <
> michael.smith.e...@gmail.com> wrote:
>
>> You can set a default value for your layer when no value is set. What I
>> do is set it to something like 1=1 and then all values will display.
>> http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url
>>
>>
>>
>> Michael Smith
>> Remote Sensing/GIS Center
>> US Army Corps of Engineers
>>
>> On Mar 10, 2016, at 8:36 PM, milad nidal 
>> wrote:
>>
>> Hi,
>>
>> I'm using Runtime variable Substitution (FILTER "nom in (
>> %municipalitylist% )") to chose one municipality from a list and it is
>> going good. But how I can visualize all the municipalities in the layer?
>> Is-it possible to ignore the filter?
>>
>>
>>
>> Thanks
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>>
>> ___
>> mapserver-users mailing list
>> mapserver-users@lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>>
>
>
>
> --
> Richard W. Greenwood, PLS
> www.greenwoodmap.com
>
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-10 Thread Richard Greenwood
Michael's suggestion is very good. Another method would be to define the
later twice with two different names and no filter in one of the
definitions. That would also allow you to style the layer differently which
might be desirable.

Rich

On Thu, Mar 10, 2016 at 6:44 PM, Michael Smith  wrote:

> You can set a default value for your layer when no value is set. What I do
> is set it to something like 1=1 and then all values will display.
> http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url
>
>
>
> Michael Smith
> Remote Sensing/GIS Center
> US Army Corps of Engineers
>
> On Mar 10, 2016, at 8:36 PM, milad nidal  wrote:
>
> Hi,
>
> I'm using Runtime variable Substitution (FILTER "nom in (
> %municipalitylist% )") to chose one municipality from a list and it is
> going good. But how I can visualize all the municipalities in the layer?
> Is-it possible to ignore the filter?
>
>
>
> Thanks
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>



-- 
Richard W. Greenwood, PLS
www.greenwoodmap.com
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] Runtime variable Substitution Filter

2016-03-10 Thread Michael Smith
You can set a default value for your layer when no value is set. What I do is 
set it to something like 1=1 and then all values will display. 
http://mapserver.org/cgi/runsub.html#default-values-if-not-provided-in-the-url



Michael Smith
Remote Sensing/GIS Center
US Army Corps of Engineers

> On Mar 10, 2016, at 8:36 PM, milad nidal  wrote:
> 
> Hi,
> I'm using Runtime variable Substitution (FILTER "nom in ( %municipalitylist% 
> )") to chose one municipality from a list and it is going good. But how I can 
> visualize all the municipalities in the layer? Is-it possible to ignore the 
> filter?  
> 
> 
> Thanks
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

[mapserver-users] Runtime variable Substitution Filter

2016-03-10 Thread milad nidal
Hi,

I'm using Runtime variable Substitution (FILTER "nom in (
%municipalitylist% )") to chose one municipality from a list and it is
going good. But how I can visualize all the municipalities in the layer?
Is-it possible to ignore the filter?



Thanks
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Re: [mapserver-users] runtime variable substitution in layer class expression

2014-02-11 Thread gorank
I follow your suggestion and I put in the map file your proposal and in my
.aspx webform with open layers javascript I added dropdownlist with ID
"YEAR" and Values 2010 and 2011. The open layer in the browser doesn't show
the map. 

Should I put in the open layer javascript some additional code to recognise
the aspx control selected value?

Goran



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/runtime-variable-substitution-in-layer-class-expression-tp5101318p5103269.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] runtime variable substitution in layer class expression

2014-02-11 Thread thomas bonfort
try something like:

layer
 validation
  "YEAR" "^[12][09][0-9][0-9]$"
 end
 class
  expression ([%YEAR%]<100)

--
thomas

On 11 February 2014 20:15, gorank  wrote:
> Is there is somebody to help me?
>
>
>
> --
> View this message in context: 
> http://osgeo-org.1560.x6.nabble.com/runtime-variable-substitution-in-layer-class-expression-tp5101318p5103222.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] runtime variable substitution in layer class expression

2014-02-11 Thread gorank
Is there is somebody to help me?



--
View this message in context: 
http://osgeo-org.1560.x6.nabble.com/runtime-variable-substitution-in-layer-class-expression-tp5101318p5103222.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [MAPSERVER-USERS] runtime variable substitution

2008-06-11 Thread Hans Castorp
Thanks for your reply,

Well, this is my problem. I am using ka-map so, I think, I am not able to use a 
URL like the one you show. I was thinking about making the substitution using 
mapscript, but I haven't found any example...

Thankis in advance.



-Mensaje original-
De: Yewondwossen Assefa [mailto:[EMAIL PROTECTED] 
Enviado el: martes, 10 de junio de 2008 20:45
Para: Hans Castorp
CC: mapserver-users@lists.osgeo.org
Asunto: Re: [MAPSERVER-USERS] runtime variable substitution
 
Hi There,
 
There are a couple of examples at the end of 
http://mapserver.gis.umn.edu/docs/reference/mapfile/variable_sub/
 
You should be able in your case to use a URL like 
&id=value_of_the_id . Have you tried this and It
did not work?
 
Hope it helps.
 
Y.A.
 
Hans Castorp wrote:
> Hi to all,
> 
> Any of you have an example about how to do a
parameter substitution???
> 
> What I want is to change the FILTER statement in one
of my mapfile 
> layers, but I don't know how to do it.
> 
> This is my layer's data and filter definition:
> 
> DATA "the_geom FROM temp"
> FILTER "id_session=%id%"
> 
> What I want is to change the id valuedepending on
some circunstances in 
> my application.
> 
> Thanks in advance.
> 
> 
> 
> 
> Hans Castorp
> 
>

> 
> Enviado desde Correo Yahoo! 
>
<http://us.rd.yahoo.com/mailuk/taglines/isp/control/*http://us.rd.yahoo.com/evt=52431/*http://es.docs.yahoo.com/mail/overview/index.html>
> La bandeja de entrada más inteligente.
> 
> 
>

> 
> ___
> mapserver-users mailing list
> mapserver-users@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
-- 

Assefa Yewondwossen
Software Analyst
 
Email: [EMAIL PROTECTED]
http://www.dmsolutions.ca/
 
Phone: (613) 565-5056 (ext 14)
Fax:   (613)
565-0925

 
No virus found in this incoming message.
Checked by AVG. 
Version: 7.5.524 / Virus Database: 270.2.0/1495 - Release
Date: 10/06/2008 17:11


  __ 
Enviado desde Correo Yahoo! La bandeja de entrada más inteligente.___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [MAPSERVER-USERS] runtime variable substitution

2008-06-10 Thread Yewondwossen Assefa

Hi There,

There are a couple of examples at the end of 
http://mapserver.gis.umn.edu/docs/reference/mapfile/variable_sub/


You should be able in your case to use a URL like 
&id=value_of_the_id . Have you tried this and It did not work?


Hope it helps.

Y.A.

Hans Castorp wrote:

Hi to all,

Any of you have an example about how to do a parameter substitution???

What I want is to change the FILTER statement in one of my mapfile 
layers, but I don't know how to do it.


This is my layer's data and filter definition:

DATA "the_geom FROM temp"
FILTER "id_session=%id%"

What I want is to change the id valuedepending on some circunstances in 
my application.


Thanks in advance.




Hans Castorp



Enviado desde Correo Yahoo! 


La bandeja de entrada más inteligente.




___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



--

Assefa Yewondwossen
Software Analyst

Email: [EMAIL PROTECTED]
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925


___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


[MAPSERVER-USERS] runtime variable substitution

2008-06-10 Thread Hans Castorp
Hi to all,

Any of you have an example about how to do a parameter substitution???

What I want is to change the FILTER statement in one of my mapfile layers, but 
I don't know how to do it.

This is my layer's data and filter definition:

DATA "the_geom FROM temp"
FILTER "id_session=%id%"

What I want is to change the id valuedepending on some circunstances in my 
application.

Thanks in advance.




Hans Castorp



  __ 
Enviado desde Correo Yahoo! La bandeja de entrada más inteligente.___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users