Details
-
Bug
-
Resolution: Duplicate
-
Medium
-
None
-
4.4.0
-
None
-
eZ Publish Entreprise 4.4
Description
Hello,
There's a bug in the eZPublish PHP API, with different languages using the PHP API.
I want to use the PHP API eZContentObjectTreeNode, to treat the object before/after the publication.
When i'm connected to the Back Office in a language (let's say English), and i edited a node in another language (French for exemple), i tried to access to the url alias of the node using the API below :
/* Access to the node in the required language (Fre) */ $ContentNode = eZContentObjectTreeNode :: fetch( $ContentNodeID , $ContentLanguage ); $ContentNodeURL = $ContentNode->urlAlias(); or $ContentNodeURL = $ContentNode->attribute('url_alias');
I noticed that the url returned by the function is the alias for the current back office language that mean that for the French node i edited, i got an english url alias.
Exemple:
-
- Let's say we are connected into the English Back Office
We edit the object that have :
- Fr Url_Alias : http://localhost/fre/french_node
- Eng Url_Alias : http://localhost/eng/english_node
When i edited the french object, the API returns me "http://localhost/eng/french_node" with the correct siteaccess but the incorrect url alias.
Steps to reproduce
1) Connect to the Back office with a language (English)
2) Edit a node (object) in another language (French)
3) Use PHP API eZContentObjectTreeNode to return the url_alias of the node
Attachments
Issue Links
- duplicates
-
EZP-17632 Wrong language used for URL alias with a non-default language node
- Closed