Sign in to your account



This field is required


forgot your password?


New to the site? Create an account →

CamelCase vs. lower case

tcr! · Oct 27, 2017 at 10:25 am

In C/C++, method names should be capitalized and use CamelCase. (source)

…and…

In JavaScript, functions should use camelCase but should not capitalize the first letter. (source)

I will only use lower case and the underscore for word boundaries. And 4 stop tabs. For all code. JavaScript, PHP, MySQL, HTML, CSS, whatever. Consistency, folks.

In other news…

if ($view_data['icd_code_1_86001'] == '') {
  $view_data['icd_code_1_86001'] = '';
}

if ($view_data['icd_code_2_86001'] == '') {
  $view_data['icd_code_2_86001'] = '';
}

if ($view_data['icd_code_3_86001'] == '') {
  $view_data['icd_code_3_86001'] = '';
}

if ($view_data['icd_code_1_86003'] == '') {
  $view_data['icd_code_1_86003'] = '';
}

if ($view_data['icd_code_2_86003'] == '') {
  $view_data['icd_code_2_86003'] = '';
}

if ($view_data['icd_code_3_86003'] == '') {
  $view_data['icd_code_3_86003'] = '';
}

Good thing that all the icd_code variables are checked for empty and then set to empty. If they’re empty.

#devhell

keamoose keamoose · Oct 27, 2017 at 11:48 am

By their own rules, should it not be spelled javaScript?

Reply

It’d be better if you signed in before commenting


Post

tcr! tcr! · Oct 27, 2017 at 1:22 pm

YES! I will be sure to mention that if it ever comes up.

In related news, I went to edit their page to correct the JavaScript spelling (similar to how I correct articles on Wikipedia) but I was stopped at the front door. 🙄

MDN requires a sign in to edit pages

Reply

It’d be better if you signed in before commenting


Post

keamoose keamoose · Oct 27, 2017 at 1:54 pm

Aww. I was also gonna make a case for gitHub, wikiPedia and faceBook.

Reply

It’d be better if you signed in before commenting


Post

tcr! tcr! · Oct 27, 2017 at 3:00 pm

How about moZilla, too?

Reply

It’d be better if you signed in before commenting


Post

keamoose keamoose · Oct 27, 2017 at 3:13 pm

Yes! moZilla fireFox.

Reply

It’d be better if you signed in before commenting


Post

tcr! tcr! · Oct 28, 2017 at 11:38 am

Perfect! 😁👍

Reply

It’d be better if you signed in before commenting


Post

Add a comment

It’d be better if you signed in before commenting


Post



Latest articles for #devhell

Jun 6th, 2019 at 11:47:17 am

Jun 6th, 2019 at 11:47:17 am

Jun 6, 2019 at 11:47 am

The function/method MUST return the number of bytes written.Why? I’m…

Developer laments, a Cobain quote, and more!

Developer laments, a Cobain quote, and more!

Jan 10, 2019 at 12:46 pm

Being a dork web developer who: loves code is forced to use WordPress…

Phone number optionally required

Phone number optionally required

Dec 1, 2018 at 12:05 pm

Good one Google. 🙄 #devhell #google

Aug 20th, 2018 at 3:16:17 pm

Aug 20th, 2018 at 3:16:17 pm

Aug 20, 2018 at 3:16 pm

Writing a valid, functional, and strict MySQL regular expression for…