Get Alias Path In Drupal
- June 17th, 2010
- Posted in Drupal
- Write comment
I’ve added this to the module (also to template.php) and its working well
function get_url_alias( $src ){
if ( $query = db_query( "SELECT * FROM {url_alias}
WHERE src='%s'", $src ) ){
if ( $rs = db_fetch_object( $query ) ){
return $rs->dst;
}
else {
return $src;
}
}
else {
return $src;
}
}
No comments yet.