Changes between Version 49 and Version 50 of MigrationGuide5.x
- Timestamp:
- 2022-01-28T14:36:48-04:00 (3 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
MigrationGuide5.x
v49 v50 28 28 * setOpacity() example: [[SWIGMapScriptOpacity|MS4W 5.x]] 29 29 * ''quickmap.php'' has also been updated (see locally at ''/ms4w/Apache/htdocs/quickmap.php'') 30 * be aware that with the !MapServer 8 release, many '''deprecated''' things have been removed and will now throw an error. For example, there is no longer a ''setMetaData()'' function for a Layer , in [[https://mapserver.org/mapscript/mapscript.html|SWIG MapScript]]. Instead we must access the 'metadata' hashTableObj keys and values directly, here is a working example:30 * be aware that with the !MapServer 8 release, many '''deprecated''' things have been removed and will now throw an error. For example, there is no longer a ''setMetaData()'' function for a Layer (or ''getMetaData()''), in [[https://mapserver.org/mapscript/mapscript.html|SWIG MapScript]]. Instead we must access the 'metadata' hashTableObj keys and values directly, here is a working example: 31 31 {{{ 32 32 #!php 33 33 <?php 34 //set metadata using the new 'metadata' hashTableObj keys and value directly 34 35 $oWMSLayer->metadata->set("wms_name", "popplace"); 36 $oWMSLayer->metadata->set("wms_title", "Cities"); 35 37 $oWMSLayer->metadata->set("wms_srs", "EPSG:3978"); 36 38 $oWMSLayer->metadata->set("wms_server_version", "1.1.1"); 37 39 $oWMSLayer->metadata->set("wms_format", "image/png"); 40 //get metadata using the new 'metadata' hashTableObj keys directly 41 echo $oWMSLayer->metadata->get("wms_title"); 38 42 ?> 39 43 }}}