If you want to edit by default + New Document of document library then open that library in designer open
the view (Allitem.aspx) in advanced mode, then add below code.
<!-- AJ JS script added to change "Add document" -->
<script type ="text/javascript">
document.getElementById("idHomePageNewItem-WPQ2").innerHTML="Enter your new text here"
</script>
ex:(scroll down at the end of webpart zone add the code)
</xsl:template></xsl:stylesheet></xsl></WebPartPages:XsltListViewWebPart>
</ZoneTemplate></WebPartPages:WebPartZone>
<!-- AJ JS script added to change "Add document" -->
<script type ="text/javascript">
document.getElementById("idHomePageNewItem-WPQ2").innerHTML ="Enter your new text "
</script>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderBodyAreaClass" runat="server">
<style type="text/css">
.ms-bodyareaframe {
padding: 0px;
}
</style>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderPageDescription" runat="server">
<SharePoint:ListProperty CssClass="ms-listdescription" Property="Description" runat="server"/>
</asp:Content>
the view (Allitem.aspx) in advanced mode, then add below code.
<!-- AJ JS script added to change "Add document" -->
<script type ="text/javascript">
document.getElementById("idHomePageNewItem-WPQ2").innerHTML="Enter your new text here"
</script>
ex:(scroll down at the end of webpart zone add the code)
</xsl:template></xsl:stylesheet></xsl></WebPartPages:XsltListViewWebPart>
</ZoneTemplate></WebPartPages:WebPartZone>
<!-- AJ JS script added to change "Add document" -->
<script type ="text/javascript">
document.getElementById("idHomePageNewItem-WPQ2").innerHTML ="Enter your new text "
</script>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderBodyAreaClass" runat="server">
<style type="text/css">
.ms-bodyareaframe {
padding: 0px;
}
</style>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderPageDescription" runat="server">
<SharePoint:ListProperty CssClass="ms-listdescription" Property="Description" runat="server"/>
</asp:Content>
it is worked fine
ReplyDeletethat is great
thank you