Select Page

Web Map Service (WMS) Vs Web Map Feature (WFS)

OpenScales Flex API handles both WMS and WFS. Its one of the really nice things about the API. The difference confused me when I first came across these terms years ago. Simply; WMS is a REST based request which returns a image. In contrast WFS returns feature attributes. Allowing the client (Flex) to build feature objects based on feature geometry. More client intensive, but WFS allows feature interactivity. Thus click on a polygon feature (WFS object) causes it to be highlighted and the feature attributes displayed. With WMS, this same functionality would require an additional server call, and image generation (more about request/response and WFS in another blog entry).

So lets talk styling. Let’s suppose we are using Geoserver for our WMS and WFS geospatial requests. Geoserver allows for easy custom styling of WMS layers, producing more attractive, intuitive maps. Now OpenScales styles the WFS features, but is limited. So we have in one case beautifully styled layers, and in the other feature interactivity. Suppose we want both?

Openscales wms

Certainly there are ways to use one or other of WMS or WFS alone to provide styling and interactivity. But from my experience the results were less than optimum. How about using both services; so render a layer using both WMS the WFS? Two problem; first, both layers will appear in the TOC, or layer list. Second, the styling of the WFS layer will still obscure some of the WMS styling. We can get round the first problem by simply checking, in the code, the layers being added to the layer list, and avoid layer duplication. In my case I only display the WMS layer in the TOC.

Openscales layer list

The second problem is more challenging. We could set the WFS layer to a 0 transparency. But then if a user selects a feature, the yellow highlighting will also be at a 0 transparency, and thus not visible. After mulling over this for a while, I came up with a solution. In Flex add an additional empty layer on top of the map, and set its transparency to 1. Set the WFS layer to a transparency of 0. When a user clicks on a feature in the WFS layer, copy this feature to the top layer. Voila, the feature is highlighted yellow, plus we maintain the beautiful WMS styling.

Openscales feature selected

This may be overkill for many applications. But the combination of WMS and WFS for a single feature layer provides the strength of both; custom styling with feature interactivity.

Related Resources

WebMapSolutions
Schedule Free ArcGIS Consultation
Our goal is to help you successfully apply ArcGIS to solve your business problems. Conducted by an ArcGIS expert, our free 30 min consultation will help move you forward.
Thank You. We will contact you as soon as possible.
SUBSCRIBE TO OUR BLOG
Our blog is filled with lively discussion, news, ideas. We take a fresh perspective on the rapidly changing world of GIS. Don't miss a post ... join over 1000 of your peers.
Do you want massive traffic?
Dignissim enim porta aliquam nisi pellentesque. Pulvinar rhoncus magnis turpis sit odio pid pulvinar mattis integer aliquam!
  • Goblinus globalus fantumo tubus dia montes
  • Scelerisque cursus dignissim lopatico vutario
  • Montes vutario lacus quis preambul den lacus
  • Leftomato denitro oculus softam lorum quis
  • Spiratio dodenus christmas gulleria tix digit
  • Dualo fitemus lacus quis preambul pat turtulis
* we never share your e-mail with third parties.
WebMapSolutions
CONTACT US
Are you looking for advice or help with ArcGIS? We are happy to share with you our thoughts and expertise to move you forward. Fill out the form below and we will be in contact soon.
Thank You. We will contact you as soon as possible.
WebMapSolutions
WORKSHOP SIGN UP
Our goal is to help get started and maximize GIS ROI. Conducted by on of our GIS experts, our free 1 hr Discovery Workshop will provide you a GIS road-map.
Thank You. We will contact you as soon as possible.
WebMapSolutions
Schedule a GeoAppSmart Demo
GeoAppSmart for ArcGIS we have designed with flexibility in mind. Let us show you how the app works. Fill out the form below, and we will contact you to set up a demo.
Thank You. We will contact you as soon as possible.
Request a Demo
Learn more about GeoAppSmart for ArcGIS. Schedule a demo. We can show you the features of this is a new breed on super flexible ArcGIS apps..
SUBSCRIBE TO OUR BLOG
Our blog is filled with lively discussion, news, ideas. We take a fresh perspective on the rapidly changing world of GIS. Don't miss a post ... join over 1000 of your peers.
Discounts!
Subscribe now to our free daily newsletter and get special offers and 20% discount.
More than just MOBILE .. All device ArcGIS apps are finally HERE!
GeoAppSmart for ArcGIS is one of a new breed of web based ArcGIS apps which:

  • Runs on any device - PC, laptop, smartphone, tablet
  • Can be used anywhere - Online or offline
  • Infinitely flexible - Built using plug-in tools
  • Easy to set up, configure and use

Download our new eBook, and learn more about these new super flexible web apps.
* we never share your e-mail with third parties.
New to ArcGIS Online and wondering how to GET STARTED?
Our free eBook 'Success with ArcGIS: Your Roadmap' will walk you through the critical success elements:

  • Defining the problem
  • Evolving the story
  • Building the runway
  • Solution implementation

If you are looking to JUMPSTART your deployment and use of ArcGIS Online this eBook is for you.
* we never share your e-mail with third parties.
S
Subscribe to Our Newsletter
Our newsletter is filled with news, tips, tutorials and lively discussion focused on the exciting, rapidly evolving world of GIS. Join over 2000 of your peers.
     
Wondering about Mobile GIS?
Our free eBook 'Your Guide to Mobile GIS' will help you get started and move forward with this exciting technology. We cover:

  • Your mobile GIS options
  • Provide case studies
  • Discuss best choices
  • Look ahead

If you are looking to improve how your mobile staff get their work done. This free eBook is for you.
* we never share your e-mail with third parties.
Want to get the most out of ArcGIS Online?
Our free eBook 'Success with ArcGIS Online' will walk you through the critical success elements including:

  • The Why
  • The Who
  • The How
  • The Where

If you are looking to get started or maximize your ArcGIS Online ROI, this eBook is for you.
* we never share your e-mail with third parties.
IoT on Map - Real-Time Reporting, Tracking and Monitoring Made Simple
Download our free Internet of Things eBook. Learn how to easily track moving assets, monitor fixed assets and report problems in real-time. Simple, flexible and affordable.
Want to get the most out of ArcGIS Online?
Download our free eBook 'Success with ArcGIS Online'. The eBook walks you through the key success elements: the why, who, how and where. Get started or maximize your ArcGIS Online ROI.
Sign up for our free GIS Discovery Workshop
Wondering how to get started or maximize your GIS ROI? Our free 1 hour workshop is designed to provide you a road-map to success with GIS. Sign up for it today.