Javascript is a dynamic computer programming language, most commonly used as part of web browsers, whose implementations allow client-side scripts to interact with the user, control the browser, communicate asynchronously, and alter the document content that is displayed.

learn more… | top users | synonyms (2)

1
vote
5answers
249 views

How to get People Picker ID using Javascript

Hi is there any way to get the People Picker value using Jquery / JavaScript? Currently we use title tag to get the id of our input fields values but people picker has only one generic title field ...
1
vote
3answers
115 views

How do I format a Date for my local region in a customised SharePoint Display Template

How do I format a date in a customised search Display Template to show the date in my Region rather than UTC. I use the following XSL in Content Query Web Parts to present the date in my timezone, ...
2
votes
1answer
61 views

Customizing item_CommonHoverPanel_Actions display template

I customized the item_CommonHoverPanel_Actions display template and added custom link to it. Whenever user clicks on the link he/she is redirected to another page. What i am trying to do now is to ...
0
votes
0answers
31 views

Node.js - SignIn to Sharepoint

After installation of Node.js on my SharePoint 2013 Enterprise Server, I get following error, when I want to connect to SP: I am using following code (main.js): var SP = require('sharepoint'), ...
1
vote
0answers
37 views

Get the Checkbox checked status on submit button click in SP 2010 list form

Am using checkbox multichoice field in my newform.aspx and in presaveaction call am doing the below code: function PreSaveAction() { var dt3; var dt4; ...
1
vote
3answers
90 views

JSOM 2013 Get Item from List containing all fields

I'm trying to get a specific list item (by id) using JSOM and want to get all fields in this item. Though, for some of my fields I get the error that I need to request the field (which would be done @ ...
1
vote
0answers
45 views

how to add a link to a document using rest api

Please help me in adding a "Link to a document" using rest api to document library
1
vote
2answers
26 views

how to specify the content type while creating an item in sharepint list using rest api or javascript

I have to upload a link to document library using rest api by specifying the content type.
1
vote
1answer
41 views

Caml query for date range not working in ecma

Not able to get item collection by my CAML in date range, while able to get in simple CAML query. Please any body let me know what is the correct format of passing date string. function ...
0
votes
1answer
37 views

Add a CEWP WebPart to a New/Edit/Disp form using JavaScript

Is it possible to use JavaScript to add a CEWP to a [New/Edit/Disp]Form.aspx? The CEWP would point to an HTML file that is in a document library. I've got a normal SP list in SP 2010 that has a ...
2
votes
0answers
67 views

Sort ListView via Postback in JSLink file

I found out, that you can filter a list view in a JSLink File very easy by a postback: function filterList(ctx, filterField, filterValue){ __doPostBack(controlId, 'NotUTF8;__filter={' + ...
1
vote
1answer
135 views

editDocumentWithProgID2 in CSOM

I need to Open/Download Word or PowerPoint Document directly from Provider Hosted SharePoint App. We can perform easily in on-premise using editDocumentWithProgID2 Tried with getting CORE.js, SP.js ...
2
votes
0answers
40 views

Sharepoint Authentication via REST API

I would like to connect to Sharepoint via REST API and Javascript. Based on readings I've done, first you need to have Security Token, then you use this Security Token to get FedAuth cookies, ...
0
votes
0answers
33 views

Pull Data Into Individual Web Part

I know what I would like to do, but I do not know how to search to find the best solution. I have a list of URLs on a list that link to stories. I do not want the user to see the entire list of ...
1
vote
1answer
42 views

Create an app from JavaScript file and Item List

I have a javaScript file that pulls info from a custom SharePoint list. I would like to use this setup on some of my other sites as well. How can I make a sharepoint app so that I can click and drop ...
0
votes
0answers
30 views

Activating SharePointPlus

OK, I have inserted your SharepointPlus as well as jquery.SPServices-2014.02. here is my simple code- but what activates it? <html xmlns="http://www.w3.org/1999/xhtml" ...
0
votes
1answer
54 views

Using knockout in SharePoint for reading list items

I have used the below code for reading list items. But when I try to debug this code, the functions are not getting called.. 'use strict'; var hostweburl; var appweburl; function ...
0
votes
1answer
82 views

Create list item by restful

Code: function createListItem() { var item = { "__metadata": { "type": "SP.Data.listnameListItem" }, "Title": "testsetsetset", ...
2
votes
4answers
373 views

Load JavaScript from external file in a web part

In order to hide the title of the page, I have placed JavaScript in a Script Editor presently. I want to add this functionality to few other pages. Is it possible to save this JavaScript in an ...
0
votes
0answers
36 views

Date parsing from JavaScript works for Firefox, not for IE

I am trying to parse a date in my java-script code, which is working fine in Firefox browser but not returning correct results in IE. below is my sample code: var shiftDate=recordArrayItem[i][0]; ...
0
votes
1answer
84 views

Get site url from list item sharepoint 2010 javascript

I have the following code and need to obtain the site url to form a hyperlink. How can this be achieved? Code prints out title but I cant get to the web url . I want the url of the site that the list ...
0
votes
1answer
79 views

Validating DatetimeFields in SharePoint 2010 List Form PreSaveAction Call

I want to perform a validation for today's date and user entered date in my custom list form's multiple datetime fields ReqstRecvdDate Field DueByDate field ReqstRecvdDate can not be greater ...
4
votes
1answer
96 views

Context menu not showing on right click

I don't understand how in SharePoint you can activate a right-click context menu on the rows of a list web part. I have two different pages. In each page I have 4 views. For some reasons (?) in page ...
1
vote
1answer
68 views

ISO DateTime to Local DateTime using javascript

I have a ISO DateTime string "2015-10-05T08:30:00" getting through REST request. Now I need to convert it into my local DateTime. The way I am trying var isoDateTime = new ...
0
votes
0answers
36 views

Allow anonymous users to run a PURE Javascript that uses REST API 2010

I wanna run a query via REST Api 2010 on a Sharepoint 2013 Server, which returns the data in JSON format. The results should be displayed on a anonymous site after beeing processed via Javascript. I ...
0
votes
1answer
36 views

sharepoint user profile properties Client Web Part

im trying to get user profile picture in my Cilent Web Part but I get a error massage (_spPageContextInfo is undefined). I'm useing REST API jQuery(document).ready(function () { ...
0
votes
1answer
106 views

List Web Part CSR issues when sorting/filtering

I'm experiencing an odd behavior using the Client Side Rendering (CSR) functionality of SharePoint 2013, with a standard List Web Part (LWP). Here the js code (referenced using the JSLink property of ...
0
votes
1answer
76 views

Create Tabs for SharePoint 2010 ListForms - newform and editform

I have one SP 2010 List having 77 columns and created the customnewform.aspx and editform.aspx using SP Designer.But its not user friendly,as user has to scroll down every time for reaching the 70+ ...
0
votes
0answers
22 views

SharePoint Java Image Slider Script Fails in Newer Browsers

I have a Java script given to me that probably is 8 years old or more. It displays photos and text on a SharePoint 2013 home page, fading out to the next photo and text. It's similar to the SharePoint ...
0
votes
0answers
26 views

sharepoint user profie picture

I have created an app part that collects the current user profile picture function GetCurrentUser() { $.ajax({ url: _spPageContextInfo.siteAbsoluteUrl + ...
1
vote
1answer
24 views

SPService - GetItemList - How can I populate custom ListItems?

I have a custom SharePoint list and want to get all items (title, kpi, delta) populate in a html site - I am using SPService with getitemlist. For Title its working fine, but for kpi and delta the ...
0
votes
1answer
33 views

is it wrong to use “min-Width:105%” & “max-Width:105%” to expand my list views on small sized screens

I'm working on a Team site inside SharePoint 2013, and I've defined many issue tracking lists. and for all these lists I'm showing the Description field (which is of type Enhanced Rich Text) inside ...
0
votes
1answer
111 views

Clear multi-value lookup via Jquery SP 2013

I am trying to clear a multi value lookup field using javascript when an item is re-edited. I have tried all the following combinations without success $("input[id^='Test'").removeAttr(); ...
0
votes
1answer
46 views

How can I check if a [recurring] event is occurring *right now* using JavaScript?

I have a site with a calendar. In the calendar I have a mix of recurring and non-recurring events. On a WebPart page I have a CEWP that uses WebServices (_vti_bin/Lists.asmx?op=GetListItems) through ...
-1
votes
1answer
108 views

Fetch the SharePoint field values using SPServices in a EditForm.aspx in SP 2010 Listform

I need to fetch the SharePoint field values using SPServices in a EditForm.aspx in my SP 2010 Listform. As far as I know, some examples, one of them - I tried below - used to fetch the current logged ...
1
vote
1answer
60 views

Personalizing Add In Parts with javascript in Sharepoint 2013

We have a customer that wishes to make it easier for the user to customize their webpart pages. We are therefor using javascript to build a simple grid where users can add, remove and move Add In ...
0
votes
1answer
60 views

Validate enhanced Rich Text Field on PreSaveAction call on newform in SP 2010 List Form

How to validate Enhanced Rich Text Field on PreSaveAction call in my SP 2010 list form's newform.aspx. I tried with JavaScript but it didn't work. I followed Marc's blog here But the issue is, ...
7
votes
4answers
397 views

Changing date format using javascript

I am getting date in 2015-10-30T05:00:00Z format from a SharePoint list using rest. Please help me to get the date in 2015-10-30 format using JavaScript.
0
votes
1answer
44 views

How to show the first N characters of my Description field inside the list views? [duplicate]

I am working on a Team site inside SharePoint server 2013. And on the list views I am showing the Description field, which is of type enhanced rich text. Currently we are facing these problems:- If ...
0
votes
0answers
155 views

ULS logs filling up with Error: Failed to get document content data

Our Sharepoint farm's homepage constantly generates these "High" log items, making other debugging difficult. As far as I can tell, it doesn't acutally cause any problems. Error: High - Database ...
0
votes
1answer
67 views

Client Context SharePoint and Javascript

I need some understanding on using clientcontext and scope. I want to run code in sitecollection page that fetches information from a particular list column (status) that exists in all sub-sites and ...
0
votes
1answer
76 views

jQuery Checkbox with UnChecked Event Handler in SharePoint 2010 List Form

I need to write a javascript/jquery code that make the checkbox if unchecked do not put a validation of a textbox and if checked the text box is validated for null or empty in my SP 2010 list form. I ...
0
votes
0answers
46 views

Lookup columns with JavaScript

I have two lists with one column that is a lookup column. How can i bind the two lists together with JavaScript or can i retrieve the data from both lists with the lookup column and JavaScript? Or ...
0
votes
1answer
22 views

set client context in sharepoint javascript

I have the following code which iterates for subsites: while (enumSubSites.moveNext()) { var Site = enumSubSites.get_current(); I want to get the associates list items from ...
2
votes
1answer
27 views

Top visited entries on site collection blogs

I want to develop a web part which shows the ranking of entries of a site collection. By now, I think a way to do this is to use a Javascript code added on the master page which adds a row to the ...
1
vote
1answer
95 views

Retrieve list status from sub sites using SharePoint Javascript

I'm creating a status page in the site collection that needs to display List Status of all the subs below site collection. All the sub-sites have the same list 'Projects'. So the idea is to iterate ...
2
votes
2answers
148 views

Recent documents for currently logged in user (Client side)

I want to achieve something like shown in Image below. I want to display Recent Document visited by logged in user. I have tried it using Content Search Web-Part. I also tried to achieve it using ...
2
votes
0answers
41 views

Display image(preloaders) before content is loaded WebPart - SharePoint 2013

I'm using a plugin called lighslider and I notice it doesn't display the whole content on first load until I refresh. I have tried using 1. windows.load, 2. ExecuteOrDelayUntilScriptLoaded, 3. ...
2
votes
1answer
130 views

Make a Choice Field-dropdown- as ReadOnly

Is there a way to change the EditForm in my SP 2010 site to display a dropdown column but as Read Only, so the user can not edit that column after the item has been created.I added the below code, ...
2
votes
1answer
262 views

JSOM How to get User Id

When trying to resolve a user with the ensureUser() call, the object is always returned as undefined even though the user exists as a Domain and SharePoint user. //Calling code. var currentCtx = ...