SharePoint randomly replacing file names in web parts?
Posted
by nvuono
on Stack Overflow
See other posts from Stack Overflow
or by nvuono
Published on 2009-11-10T19:32:52Z
Indexed on
2010/04/10
12:23 UTC
Read the original article
Hit count: 289
sharepoint
|bugs
Ok SharePoint is driving me crazy and I need to see if anyone has encountered a similar problem or knows of a solution:
I have a content editor webpart with some HTML including links to PDF files that I've modified slightly to append an employee number querystring ie:
<a href="http://moss.company.com/group/home/EPermits
/Blank%20Form%20Templates/_blank_breach_permit.pdf?empNum=">New Breach Permit</a>
And SharePoint seems to randomly replace the filename with aab04168 or some other similar characters:
<a href="http://moss.company.com/group/home/EPermits
/Blank%20Form%20Templates/aab04168?empNum=">New Breach Permit</a>
After this happened a few times with no explanation I tried changing the content editor webpart to look directly at a documentLinks.html file located in the Shared Documents folder of the SharePoint site and guess what... SharePoint edited that document and replaced my filenames with random characters in there too!
Figuring that filenames beginning with an underscore could be triggering some internal SharePoint procedures I've renamed all the files to remove the starting underscore--unfortunately the problem isn't immediately reproducible and I'm waiting right now to see if I run into any more trouble.
edit: the underscore in the filename didn't help... my documentLinks.html wound up getting modified and all the hrefs were replaced with random characters again. Now I'm setting the hrefs in javascript with the filename text concatenated together from multiple strings.
linkEle.href = ".../EPermits/Blank%20Form%20Templates/blank" + "_Chemical_Usage.pdf?empNum=" + empNumber;
© Stack Overflow or respective owner