Hot answers tagged

29

Sorry, with http://www.ViewMaster365.com/#How I have been an avid promotor of the undocumented HTML trick (worked since SP2010, maybe even SP2007) Like you I am amazed Microsoft actually disabled it, then again it already was disabled for Modern Experiences, so it was clear the HTML trick had no future Must be kismet or faith or karma or just plain ...


22

Both the description and the solution of your issue can be found here : Unable to Open PDF Directly from SharePoint 2010 ([Link edited on 11/20/2013]. Basically, it's a security feature (that can be disable, if you accept the implication), that prevent some files to be displayed in the browser directly. Typically, what would prevent someone to put some ...


13

Here is a minimal HTML file that will make use of SP.UI.ModalDialog: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <link rel="stylesheet" type="text/css" href="/_layouts/15/1033/styles/corev15.css"/> &...


9

myQuery.RowLimit = 0 I think if I'm correct: 0 = unlimited Hope this helps. :)


9

I fixed it after wasting frustrating hours on this ! Its quite easy but doesnt make sense. Just add the HTML 4.1 (not HTML 5 - it wont work) char encode tag to the additional pagehaed placeholder, and it works like a charm. Make sure that you've tried the other solutions, may it's the result of a combination. Fact is, that it is already included in the ....


9

You can't change the .master file when it's bound like this, you can only edit the .html file. It will re-generate the .master when you save the .html. This is due to the Design Manager packet in SP2013. Here's the MSDN article on this feature set: http://msdn.microsoft.com/en-us/library/office/jj822363(v=office.15).aspx


9

The issue is that you should copy seattle.html which will auto create a .master page for you, and there is a link between the files. To resolve the issue, create a copy of seattle.html Now you have both a seattle_copy(1).html and seattle_copy(1).master. Next rename seattle_copy(1).html to for example test.html. A pop-up appears asking you to update pages ...


8

Check https://sharepoint.stackexchange.com/a/52877/35604: <script type="text/javascript"> function Custom_Submit(command) { SP.Ribbon.PageState.Handlers.showStateChangeDialog(command, SP.Ribbon.PageState.ImportedNativeData.CommandHandlers[command]); } </script> <input type="button" onclick="javascript:Custom_Submit('...


7

Add an id: <pre id="myId" .... And then hide it with jquery: addNewTest = function() { $('#myId').hide(); }); or without jquery: addNewTest = function() { document.getElementById('myId').style.display = 'none'; });


7

The new way of displaying HTML based on data in list(item) was possible using using JSLink. However the 'new' way to do this is by using SPFx Extensions. It's currently in preview. You should use a FieldCustomizers. As MS states: "it can be used to provide modified views to data for fields within a list.". You could start here for more information.


6

What you are looking for is called "Reusable content". The following links will help you on your journey to wisdom: Use reusable content SharePoint Reusable Content SharePoint 2010 Reusable Content Bear in mind that Reusable Content is only meant for HTML content or other content and can only be used on certain pages - just give it a go and see whether it ...


6

I could not find any good way to do it with IE8 or IE9, so I utilized the OOB AttachFile.aspx form: (I am using SPService to get query string & I am adding input control dynamically with JQuery) function readyCall() { //Get Query String var queryString = $().SPServices.SPGetQueryString(); //Tasks List ID (i.e. 0A347169-CE79-4B7F-B561-...


6

The header and footer (the chrome) of SharePoint and most Asp.Net websites is defined in a master page. For SharePoint 2013 this is by default the seattle.master. My tip is to create your own master page by taking a copy of the Seattle.master, or using a Delegate control to insert your control. Create SharePoint master page : http://msdn.microsoft.com/en-...


6

I'm using this: <script type="text/javascript"> var loginName = ""; var userid = _spPageContextInfo.userId; GetCurrentUser(); function GetCurrentUser() { var requestUri = _spPageContextInfo.webAbsoluteUrl + "/_api/web/getuserbyid(" + userid + ")"; var requestHeaders = { "accept" : "application/json;odata=verbose" }; $.ajax({ url : requestUri, ...


6

In Office 365, I created a new site (not a personal site). I then opened the site in SharePoint Designer and imported the files into Site Pages. I renamed index.htm to index.aspx I right-clicked on index.aspx and set it as the home page. This works for single html page sites. For multi-page websites you will need to rename all html files to an ...


6

.html and .htm are absolutely identical. In terms of apps there is no difference if you are creating .aspx or .html. But you need to consider your requirements carefully. For example, if you need to host on your page some OOB web parts, for example XSLTListViewWebPart: <WebPartPages:WebPartZone runat="server" FrameType="TitleBarOnly" ID="full" ...


6

You can put in a support ticket to request an extension of the feature until 9/10. While it's not a long-term solution, this will hopefully give Microsoft enough time to enable the admin setting that is available for the on-prem version.


6

The short answer on "How to get the same functionality back": Third party products. Client-side rendering via JS Link property of web parts. This only works for Classic mode. If you are using Classic mode, this is likely the 'best' short term answer to broken interfaces until a longer-term solutions is implemented. SPFx Extensions or customization ...


6

You can implement this by creating a Custom New Form and adding the HTML you have already created to this aspx page. This will be bound to the SharePoint List . Each SharePoint List by default has NewForm.aspx,EditForm.aspx and a DisplayForm.aspx. If you open the SharePoint Designer you can view them as below: You can add a new Custom Form and set it as ...


6

I did some tests myself and it should be pretty straight forward. You can use a local jQuery reference instead of a CDN. This hides the Key filter Div and then moves the Div containg the filter to above the pages main content (list, hidden filters etc.). <style type="text/css"> .ms-tv.box { display:none; /* Hide the Key filters until ...


5

I haven't tested this, but I would think you can add it with a javascript maybe. You already have the _spPageContextInfo on your sites. <script type="text/javascript"> document.write('<a href=\"'+_spPageContextInfo.webServerRelativeUrl+'/page.aspx\">link</a>'); </script> That's just an example, probably not the best way to add js ...


5

First of Publish your data for public view you need to enable Anonymous access for this announcement and news lists. Now Go to List -> List setting -> RSS Setting -> checked required columns -> click OK Now open Announcement List RSS Feed Link form List Ribbon. using this link you can get data in to your HTML site. In HTML site you can use third party ...


5

SP.UI lives on another file, that is sp.ui.dialog.js You need to add it to the script references <script type="text/javascript" src="_layouts/15/sp.ui.dialog.js"></script>


5

Bonanza... The code $($("[id^=Log][id$=inplacerte]")[0]).attr("contenteditable","false"); Did the trick. Thanks for the hint!


5

What I did to get around this in SP Online, is to use JSLINK to render the HTML. This is a much more elegant solution, and easier to use than the calculated columns anyway. But I was caught completely off guard by this.


5

There's a great solution which allows you to build a HTML form for SharePoint lists if you're okay using JavaScript and jQuery. Original solution: http://www.markrackley.net/2013/08/29/easy-custom-layouts-for-default-sharepoint-forms/ Updated this year: http://www.markrackley.net/2017/05/04/customize-your-sharepoint-classic-forms-without-infopath/


5

Add type="button" to your <button> tag to stop the reload: <button class="accordion" type="button">


4

This might classify as more of a work-around than a solution, but I used the guid of the view as the webpart id. I decided to look into the content database to see how views are stored. In the stored procedure proc_CreateView I found that views are actually stored in the AllWebParts table with the ViewId inserted into the tp_ID column. So I added the ...


Only top voted, non community-wiki answers of a minimum length are eligible