[mapguide-users] You don't have permission to access /mapviewerphp/ajaxviewer.php on this server.

erictsn at cadbeyond.com erictsn at cadbeyond.com
Mon Jun 16 11:06:23 EDT 2008


Hi All

I try to amend the mapguide.conf from Apache conf folder, the amendment
part is as following:

# MapViewer to MapViewerPhp aliases                                        
                                                                           
                                                                           
                                                
ScriptAlias /mapguide2009/mapagent/mapagent
"/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/mapagent/mapagent"
                                                                           
                                                                           
AliasMatch ^/mapviewerphp/([^?])(.*)$
"/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/mapviewerphp/$1$2"
                                                                           
                                                                           
     
AliasMatch ^/mapviewerphp/(.*)$
"/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/mapviewerphp/ajaxviewer.php$1"
   

Alias /mg
"/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/App/"        
                                                                           
                                                                           
                               
                                                                           
                                                                           
                                                                           
                                                
<Directory
"/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/App/">       
                                                                           
                                                                           
                              
  AllowOverride All                                                        
                                                                           
                                                                           
                                                
  Options All                                                              
                                                                           
                                                                           
                                                
  Order allow,deny                                                         
                                                                           
                                                                           
                                                
  Allow from all                                                           
                                                                           
                                                                           
                                                
                                                                           
                                                                           
                                                                           
                                                
AddHandler php5-script .php                                                
                                                                           
                                                                           
                                                
AddHandler mgmapagent_handler fcgi                                         
                                                                           
                                                                           
                                                
                                                                           
                                                                           
                                                                           
                                                
  RewriteEngine on                                                         
                                                                           
                                                                           
                                                
  RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization},L]                 
                                                                           
                                                                           
                                                
</Directory>  

Eventually the map frame shows "You don't have permission to access
/mapviewerphp/ajaxviewer.php on this server.".

The part of index.php is as following:

<frameset rows="100,*" frameborder="NO" border="0" framespacing="0">       
                                                                           
                                                                           
                                                
    <frame src="title.html?AppName=AJAX" name="TitleFrame" scrolling="NO"
noresize>                                                                  
                                                                           
                                                  
    <frame src="../mapviewerphp/ajaxviewer.php?SESSION=<?php echo
$sessionId; ?>&WEBLAYOUT=<?php echo $webLayout; ?>" name="ViewerFrame">    
                                                                           
                                                          
</frameset>   

BUT if the mapguide.conf is amended as following:
Alias /mg "/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/"  
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
         
<Directory "/opt/Autodesk/mapguideenterprise2009/webserverextensions/www/">
  
It is work!! but I don't want the user can access another folder in www
root directory. How I can do it?


Regards,
Eric 



More information about the mapguide-users mailing list