Jump to content


Member Since 24 May 2008
Offline Last Active Today, 04:53 PM

#302716 WARNING! Is Windows Restore Point CHANGED your JS files?

Posted by thescientist on 19 April 2016 - 07:51 PM

version control systems can be especially useful for avoiding these kinds of hazards

#301784 hard coded definition

Posted by thescientist on 23 March 2016 - 02:43 AM

All what you did is evaluating and criticizing the little code above which is , absolutely , not what I asked for  . My question was what is the difference between a normal program and a hard coded program? if we take in consideration that even a normal program has a data that is directly embedded in it like the little program above shows . Please confine yourself to the question and answer exactly what I am asking for

I would just add that you should be more mindful of what users on the forum are trying to teach you.  I understand that example may not have been immediately obvious to you, but the point was still fundamental, because in fact the example was a direct answer to your question.  (using values from user input vs fixed / hardcoded / embedded / etc in the code itself).  There was a better way to respond such as, "that reply is not clear to me could you expand further, I don't get xyz..".  In so much that you would like people to continue helping you.

#299918 Angular js

Posted by thescientist on 14 January 2016 - 02:08 PM

did you got the angular site? the home page alone gives a comprehensive overview of what it does and examples for how to use it.



If you need a full MVC framework, for a medium to large scale dynamic site, probably driven by AJAX / backend services, Angular is one option.  There are other non MVC options that still emphasize component based development, but that's a matter of preference and philosophy.

#299091 PHP 7 Is Available

Posted by thescientist on 04 December 2015 - 05:37 PM

This is a very exciting release indeed!  Looking forward to trying out and excited at all the internal development / improvements that comes with it.

#299000 php

Posted by thescientist on 01 December 2015 - 02:17 PM

If you haven't looked into it, PHP7 is near stable release, and should be quite an overhaul of the underlying engine and a pretty good attempt at starting to remove the cruft.  mysql is completly removed, for example.  I think PHP is entering a "renaissance" if you will with this release, similar to how JavaScript is also in an upswing, supported by recent advances in EMCAScript 2015 (ES6) and Node.

#298985 Password in HTML?

Posted by thescientist on 30 November 2015 - 04:04 PM

Why not just share the file via something like Google Drive or Dropbox?

#298620 Adding One Year to a Date Field?

Posted by thescientist on 11 November 2015 - 09:51 PM

It's hard to help you without seeing any code or what you tried and why a given approach isn't working.  


Formatting date / time is extremely common and not that hard, and in particular what moment excels at.  Did you review their docs?  There's a section just on displaying.


#298615 Adding One Year to a Date Field?

Posted by thescientist on 11 November 2015 - 07:35 PM

What have you got so far?  I would start with looking at the JavaScript date object



There's also a really good date / time library called moment that is helpful when working with date / times


#298613 User can Pay Half payment in WooCommerce

Posted by thescientist on 11 November 2015 - 07:31 PM

I would definitely submit this to the WooCommerce forums, if you haven't already and it's not covered in any of their documentation


#296305 Functions in jscript

Posted by thescientist on 27 August 2015 - 02:02 PM

if you give two functions the same name, then the second one will clobber the first one.  The solution to this is to give your functions meaningful names that describe what they do (typically using verbs) and keep them small and scoped to just one responsibility.

#295720 crypt() is NOT an encryption function

Posted by thescientist on 05 August 2015 - 10:21 PM

Fair enough, so either they will or they won't at this point I suppose.  You're post is very educational, so hopefully at least some of the forum members here will be able to make use of it.

#293394 toggle div content via links

Posted by thescientist on 16 May 2015 - 06:21 PM

are you checking for Javascript errors in the console?

#292523 javascript with if inside if

Posted by thescientist on 23 April 2015 - 07:30 PM

You should use your browsers console to look for errors, that would be the first step in debugging any Javascript code.

#290190 Echo specific rows number from a mysql database

Posted by thescientist on 04 March 2015 - 09:23 PM

You could do it in the query using LIMIT


#289674 function parameter

Posted by thescientist on 20 February 2015 - 09:51 PM

no.  functions take arguments / parameters.  (like the references explain)