I encounter a strange behaviour in a sharepoint 2013 farm. I have developed some webparts that build html tags that use SPListItem.Url, but the Url property returns a malformed url :
for example :
http://[websiteURL]/Pages/Lists/MyList/... instead of http://[websiteURL]/Lists/MyList/...
http://[websiteURL]/Pages/Pages/Default.aspx instead of http://[websiteURL]/Pages/Default.aspx
=> weburl always followed by /Pages then the correct url.
in the code behind, I have something like this :
string html = "<a href=\"" + item.Url + "\">";
This web is the root web of the site collection and is a publishing portal web.
Any idea on what could cause this ?
Thank you.
Aucun commentaire:
Enregistrer un commentaire