- Display theme scope for selected text:
- ctrl+shift+p and type in "scope", the fuzzy search should find you the command "Developer: Inspect TM Scopes" (from stackoverflow)
Sunday, July 29, 2018
VSCode notes
Saturday, July 29, 2017
SP2013: Restoring a site collection backup
Got a site collection backup from a server, and needed to restore it to a dev virtual machine.
Initial attempts at running restore-spsite got errors like this:
restore-spsite :0x80070003 ...
+ CategoryInfo : InvalidData: (Microsoft.Share...dletRestoreSite:SPCmdletRestoreSite) [Restore-SPSite], DirectoryNotFoundException
Eventually found the reason being a mismatch in versions between the source server and the dev VM. Went to Central Admin on both servers and checked the versions listed under Upgrade and Migration -> Check product and patch installation status. Found that the dev VM needed these installed:
Note: Remember to disable and stop the IIS Admin service before installing updates, otherwise it takes up so much CPU that the update takes forever. (See Why SharePoint 2013 Cumulative Update takes 5 hours to install?) And remember to set it back to automatic after the updates.
Initial attempts at running restore-spsite got errors like this:
restore-spsite :
+ CategoryInfo : InvalidData: (Microsoft.Share...dletRestoreSite:SPCmdletRestoreSite) [Restore-SPSite], DirectoryNotFoundException
Eventually found the reason being a mismatch in versions between the source server and the dev VM. Went to Central Admin on both servers and checked the versions listed under Upgrade and Migration -> Check product and patch installation status. Found that the dev VM needed these installed:
- CU KB3101373 15.0.4771.1000 (prerequisite for this was installing SP1)
- Security Update KB3115169 15.0.4859.1000
Note: Remember to disable and stop the IIS Admin service before installing updates, otherwise it takes up so much CPU that the update takes forever. (See Why SharePoint 2013 Cumulative Update takes 5 hours to install?) And remember to set it back to automatic after the updates.
Then to restore the site collection backup:
- Create new web app, say http://mywebapp.
- Created new site collection (Publishing Portal) under the new web app.
- set mydomain\mylogin as primary admin
- On SQL Server, (see https://technet.microsoft.com/en-us/library/ee748655.aspx)
- set securityadmin role for mydomain\mylogin
- set mydomain\mylogin as db_owner of the content DB for the new web app
- Using SP powershell, do these commands (see https://sharepoint.stackexchange.com/a/125228). Without this step, you'll get this error: "restore-spsite : Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))".
- $w = get-spwebapplication http://mywebapp
- $w.GrantAccessToProcessIdentity("mydomain\mylogin")
- Restore the site collection backup with SP powershell command:
- restore-spsite -identity http://mysitecollection -path C:\pathtobackup\mysitecollectionbackup.bak -force
Monday, July 10, 2017
Tuesday, June 27, 2017
Flexbox notes
A must-read whether you think you know flexbox or not:
11 things I learned reading the flexbox spec – Hacker Noon
11 things I learned reading the flexbox spec – Hacker Noon
Monday, February 27, 2017
Script plugin to wait for images loaded
Checking for $(window).load() wasn't working for images in slideshows that were dynamically populated. Found a plugin for imagesLoaded while reading this thread: http://stackoverflow.com/a/26930871. Seems to work, so here it is:
http://imagesloaded.desandro.com/
http://imagesloaded.desandro.com/
Sunday, January 15, 2017
MDN: Demos of open web technologies
Mozilla supports a wide variety of exciting open web technologies, and we encourage their use. This page offers links to interesting demonstrations of these technologies, including some that were popular in the Demo Studio, which has since been retired.
Subscribe to:
Posts (Atom)