$('.login-box-form input').keypress(function (e) {
if (e.which == 13) {
__doPostBack('ctl00$ctl50$lnklogin', '');
}
});
Friday, 12 October 2012
Enter Key for Login Form
Monday, 1 October 2012
how to copy a dll file from gac?
start Command Prompt
write "cd :\Windows\assembly\GAC_MSIL\Microsoft.SharePoint.IdentityModel\14.0.0.0__71e9bce111e9429c\"
write "copy Microsoft.SharePoint.IdentityModel.dll c:\"
now you can access the dll freely (e.g. copy to TFS, open with reflector or any other action)
Saturday, 15 September 2012
Jquery Everytime function
$(document).everyTime(5000, function () {
UpdateNews();
});
http://jquery.offput.ca/timers/
or
window.setInterval(function() {
UpdateNews();}, 50000);
Friday, 14 September 2012
Reset form values with Javascript
$(this).closest('.form-container-table').find('input,textarea').val('')
Example: <a onclick="$(this).closest('.form-container-table').find('input,textarea').val('')" href="javascript:;">RESET</a>
Thursday, 13 September 2012
Fast search connector setup
PS C:\> .\securefastsearchconnector.ps1 -certPath .\FASTSearchCert.pfx -ssaName
"FASTContent" -userName "domain\MOSSDEV"
Thursday, 6 September 2012
Problem with httpContext.RewritePath on IIS 7
<configuration>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true">
</system.webServer></configuration>http://stackoverflow.com/questions/4976893/problem-with-httpcontext-rewritepath-on-iis-7
Tuesday, 4 September 2012
How to remove illegal characters from a string?
public static string RemoveIllegalCharacters(string stringValue)
{
string pattern = @"[^\w\s\-\+]";
string replacement = " ";
string noResultText = "noresult";
Regex regEx = new Regex(pattern);
string sanitized = regEx.Replace(stringValue, replacement);
if (!string.IsNullOrEmpty(sanitized.Trim()))
return sanitized;
else
return noResultText;
}