Opened 17 years ago

Closed 15 years ago

#427 closed defect (fixed)

mapviewerphp-error in legend.phpfile(BuildClientSideTree)

Reported by: max Owned by:
Priority: low Milestone:
Component: AJAX Viewer Version: 2.1.0
Severity: trivial Keywords:
Cc: External ID: 1307712

Description

I think there is error in the legend.php file inside the mapviewerphp Folder--

http://trac.osgeo.org/mapguide/browser/trunk/MgDev/Web/src/mapviewerphp/legend.php#L89

if($summary)

{

$updateType = 0; return only the layer structure, that is mainly groups/layers/layer-ids. Do not parse layer definitions.

BuildClientSideTree($tree, null, "null", false, "layerData", null);

}


function BuildClientSideTree($tree, $parent, $parentName, $fulldata, $container, $resSrvc, $layerMap)

As BuildClientSideTree function is defined in the legend.php file and required to pass 7 parameters ,so when we use to call function under the $updateType=0, and use only 6 parameters it use to throw error in the Apache Web Server error.log file. The Above error can be resolved by using-->

BuildClientSideTree($tree, null, "null", false, "layerData",$resourceSrvc, null);

or

$layerMap=null; BuildClientSideTree($tree, null, "null", false, "layerData",$resourceSrvc, $layerMap);

Attachments (1)

legend.php.diff (500 bytes ) - added by gabrimonfa 15 years ago.
trivial fix, that add a null parameters as 7th one

Download all attachments as: .zip

Change History (6)

comment:1 by jbirch, 17 years ago

I wonder if this is related to #167?

comment:2 by jbirch, 15 years ago

Resolution: wontfix
Status: newclosed

Old ticket; closing. If still a concern, please retest at version 2.1 and re-open. I also believe this may be same as or fixed by #167

comment:3 by gabrimonfa, 15 years ago

Component: GeneralAJAX Viewer
Priority: mediumlow
Resolution: wontfix
Severity: majortrivial
Status: closedreopened
Version: 1.2.02.1.0

It is not related to #167.

It is simply calling a function passing it 6 parameters instead of the expected 7 parameters

FastCGI: server "/usr/local/mapguideopensource/webserverextensions/php/bin/php" stderr: PHP Warning: Missing argument 7 for BuildClientSideTree(), called in /usr/local/mapguideopensource/webserverextensions/www/mapviewerphp/legend.php on line 89 and defined in /usr/local/mapguideopensource/webserverextensions/www/mapviewerphp/legend.php on line 181

by gabrimonfa, 15 years ago

Attachment: legend.php.diff added

trivial fix, that add a null parameters as 7th one

comment:4 by tomfukushima, 15 years ago

External ID: 1307712

comment:5 by liuar, 15 years ago

Resolution: fixed
Status: reopenedclosed

Fixed by Changeset [4628]

Note: See TracTickets for help on using tickets.