Comments for The Original Jelani Harris http://jelaniharris.com The one and only Mon, 25 Sep 2017 10:01:25 +0000 hourly 1 https://wordpress.org/?v=4.8.4 Comment on Removing empty elements from an array by test http://jelaniharris.com/2010/removing-empty-elements-from-an-array/comment-page-1/#comment-16490 Mon, 25 Sep 2017 10:01:25 +0000 http://jelaniharris.com/?p=90#comment-16490 function safeQueryParam($candidate = NULL){
$returnStr = NULL;
$pattern = ‘/[^a-zA-Z0-9]/’;
if($candidate)
$tempStr = preg_replace($pattern, ”, $candidate);
if($tempStr != null && $tempStr != “”)
$returnStr = $tempStr;
return $returnStr;
}

]]>
Comment on Remove Anchors from a Url in Javascript by Peter PayteR Gašparík http://jelaniharris.com/2008/remove-anchors-from-a-url-in-javascript/comment-page-1/#comment-16451 Sat, 09 Sep 2017 08:53:33 +0000 http://jelaniharris.com/?p=22#comment-16451 in my opinion is using regex replace on string best and cleanest solution

.replace( /#.*/, “”);

without page reload

history.pushState(“”, document.title, location.href.replace( /#.*/, “”));

example with page reload

location.href = location.href.replace( /#.*/, “”);

]]>
Comment on Fixing Foundation 5’s Unrecognized Expression Syntax Error by Tad Heigel http://jelaniharris.com/2014/fixing-foundation-5s-unrecognized-expression-syntax-error/comment-page-1/#comment-15214 Wed, 20 Jul 2016 17:23:39 +0000 http://jelaniharris.com/?p=348#comment-15214 Legit. So glad I found this. My error was slightly different but this fixed it. Many thanks.

]]>
Comment on Using Jquery to disable the enter key by timbla http://jelaniharris.com/2010/using-jquery-to-disable-the-enter-key/comment-page-1/#comment-14505 Tue, 21 Apr 2015 04:22:44 +0000 http://jelaniharris.com/?p=38#comment-14505 Thanks! I tried a lot of other approaches, but they did not work in Firefox’.
Yours does!

]]>
Comment on Case-insensitive replaceAll in Java by Brett http://jelaniharris.com/2009/case-insensitive-replaceall-in-java/comment-page-1/#comment-14470 Fri, 20 Mar 2015 03:48:43 +0000 http://jelaniharris.com/?p=67#comment-14470 The correct phrase is “the quick brown fox jumps over the lazy dog”. Which contains all 26 letters of the English alphabet.

]]>
Comment on Using Jquery to disable the enter key by shideneyu http://jelaniharris.com/2010/using-jquery-to-disable-the-enter-key/comment-page-1/#comment-3141 Fri, 25 Apr 2014 10:51:28 +0000 http://jelaniharris.com/?p=38#comment-3141 Thanks you very much !

]]>
Comment on Strip Whitespace on save with Aptana by Stripping trailing whitespace on save in Aptana 3.2 | Sun-Decked Desert http://jelaniharris.com/2012/strip-whitespace-on-save-with-aptana/comment-page-1/#comment-3009 Mon, 24 Mar 2014 11:50:14 +0000 http://jelaniharris.com/?p=286#comment-3009 […] checked, it doesn’t seem to work for me. So… I followed the instructions here (http://jelaniharris.com/2012/strip-whitespace-on-save-with-aptana/) and installed the AnyEdit plugin. After a restart, hey presto. It just works. Although Aptana 3.2 […]

]]>
Comment on Using Jquery to disable the enter key by kumar http://jelaniharris.com/2010/using-jquery-to-disable-the-enter-key/comment-page-1/#comment-2976 Sat, 08 Mar 2014 04:30:35 +0000 http://jelaniharris.com/?p=38#comment-2976 thank u, i am looking for this

]]>
Comment on Case-insensitive replaceAll in Java by Andrei http://jelaniharris.com/2009/case-insensitive-replaceall-in-java/comment-page-1/#comment-2188 Mon, 05 Aug 2013 08:37:08 +0000 http://jelaniharris.com/?p=67#comment-2188 “The sly brown Fox jumped over the lazy foX.”.replaceAll(“(?i)(fox)”, “[bold]$1[/bold]”);

]]>
Comment on Using Jquery to disable the enter key by Azra http://jelaniharris.com/2010/using-jquery-to-disable-the-enter-key/comment-page-1/#comment-2019 Wed, 20 Mar 2013 09:01:45 +0000 http://jelaniharris.com/?p=38#comment-2019 @Tanner : maybe there is incorrect on your script , i am using 1.3 Jq and its works

]]>