Last modified: 2010-08-30 13:32:02 UTC
Hi Someone forgot to add the caracter ":" in the function decodeURI. SMWExporter::encodeURI ("Attribut:Test") => Attribut-3ATest but SMWExporter::decodeURI ("Attribut-3ATest") => Attribut-3ATest !! ERROR The good result is "Attribut:Test". bye karima BEFORE MY FIX ------------------------------ static public function decodeURI( $uri ) { $uri = str_replace( array( '-22', '-23', '-26', '-27', '-2B', '-21', '-' ), array( '"', '#', '&', "'", '+', '!', '%' ), $uri ); $uri = str_replace( '-2D', '-', $uri ); return $uri; } AFTER FIX ---------------------------------------------------- static public function decodeURI( $uri ) { $uri = str_replace( array('-3A', '-22', '-23', '-26', '-27', '-2B', '-21', '-' ), array( ':', '"', '#', '&', "'", '+', '!', '%' ), $uri ); $uri = str_replace( '-2D', '-', $uri ); return $uri; }
Resolved in SVN (and soon in SMW 1.5.2). The problem has not been noticed since all uses of decodeURI() apply urldecode() to the result, and %3A gets replaced by : in this step.