Ssociety 124 #1 Posted October 28, 2017 Base from your experience as a programmer, Is it worthy to focus in this language when it comes to web development? for me I find it easy to use, but when I am building more complex systems it creates shitty mess that I really hate, I'm trying to avoid mess when I am coding but I can't when it come to php.. Quote Share this post Link to post Share on other sites
Marchay 0 #2 Posted October 28, 2017 I don't program much but it's easy this lamguage and it shouldn't be a problem. Quote Share this post Link to post Share on other sites
Dboyeric 250 #3 Posted October 28, 2017 i dont really know anything about programming, i wish you all the best Quote Share this post Link to post Share on other sites
Mistletoe 430 #4 Posted October 28, 2017 For me, yes especially if you are doing freelance. Most websites are php based due to CRMs such as Wordpress. Websites using WordPress is the common thing for small and starting businesses or bloggers cuz it's cheap. Tldr, trend wise, it's a yes. But coding wise, it's a no. I prefer other OOP PLs like. Net Quote Share this post Link to post Share on other sites
Ssociety 124 #5 Posted October 29, 2017 18 hours ago, Mistletoe said: For me, yes especially if you are doing freelance. Most websites are php based due to CRMs such as Wordpress. Websites using WordPress is the common thing for small and starting businesses or bloggers cuz it's cheap. Tldr, trend wise, it's a yes. But coding wise, it's a no. I prefer other OOP PLs like. Net Yeah you are right, maybe I will focus first on other programming languages, I am choosing from javascript or java Quote Share this post Link to post Share on other sites
Mistletoe 430 #6 Posted October 29, 2017 Well it also depends on what you want to make. Since you mentioned Javascript, i assume you want to make websites? I gotta warn ya, java coded websites doesn't run without java installed in your computer. Quote Share this post Link to post Share on other sites
Ssociety 124 #7 Posted October 29, 2017 Yeah, I mean I am thinking now if I will focus on Web Dev or enterprise thingy, Those two language are my best pick on there own area hehe, or I am wrong again.. Quote Share this post Link to post Share on other sites
Serlite 576 #8 Posted October 29, 2017 Knowing a bit of PHP isn't a bad thing - it's very commonly-used, and gives you the freedom to fiddle around in the backend if you ever end up having to manage something like a Wordpress site. But if you're trying to build an application from scratch with it, it's really advisable that you learn up on common design patterns beforehand (MVC and its variants are important). You can technically achieve your goals without following a structure, but if you ever have to look back to maintain/extend some functionality...that's where the nightmare begins. (Learning design patterns isn't specific to PHP; any language becomes a tangled mess if you don't follow one in a large enough program. That's why programming is a skill that transcends languages - it's more of a way of thinking than knowing any particular language. Once you have that down, the only real barrier from using another language is learning the syntax.) 1 Ssociety reacted to this Quote Share this post Link to post Share on other sites
Ssociety 124 #9 Posted October 29, 2017 Honestly, I have no experience working in the programming industry, So I want to focus in a language that will be a nice training ground for a newbie like me, I Tried to apply in this small company in our place, they are using php as their main programming language, I guess I will stay their for a year If I get Hired :). I want to learn node.js more though.. Quote Share this post Link to post Share on other sites
Mistletoe 430 #10 Posted October 30, 2017 (edited) 4 hours ago, Ssociety said: Honestly, I have no experience working in the programming industry, So I want to focus in a language that will be a nice training ground for a newbie like me, I Tried to apply in this small company in our place, they are using php as their main programming language, I guess I will stay their for a year If I get Hired :). I want to learn node.js more though.. Php is a nice training ground. To give you an idea of the whole picture, creating a website is composed of 3 section. - Your front end (your website interface) - your back end (where your coding, conditions, actions will be) - your database (where you store your data, images, sounds etc) For front end, you use html, css for the design. To make it dynamic, you use javascript, jquery, node.js and other variations of javascript. This is what also used to communicate from your front end to your back end. For back end, you use whatever programming language you prefer. Be it php, java, c#, vb etc Database, you use whatever fits your program. Depending on the size of your project. Query is what you use to communicate from your back end to database As you can see, this can be so complicated especially if you're not the one who coded it and you have to update it. This is where proper naming of variables, functions, classes and comments comes in. This is what @Serlite is referring to with design patterns. You may wanna search Gang of Four for this. Edited October 30, 2017 by Mistletoe 1 CaptainLorca reacted to this Quote Share this post Link to post Share on other sites
Ssociety 124 #11 Posted October 30, 2017 Even if I am the one coding my own program , when I leave the code for a month , I can't understand it anymore and I am annoyed , maybe I should be more detailed in naming variables and be more organize .. Quote Share this post Link to post Share on other sites
iwant1btc 45 #12 Posted October 30, 2017 i know a little bit Programming but not sooo much Quote Share this post Link to post Share on other sites
Ssociety 124 #13 Posted October 30, 2017 5 minutes ago, iwant1btc said: i know a little bit Programming but not sooo much How long have you been doing programming? and where did you learn? Quote Share this post Link to post Share on other sites
iwant1btc 45 #14 Posted October 30, 2017 3 minutes ago, Ssociety said: How long have you been doing programming? and where did you learn? No more i think 1 or 1.5 years but myself:) Quote Share this post Link to post Share on other sites
Mistletoe 430 #15 Posted October 30, 2017 6 minutes ago, iwant1btc said: No more i think 1 or 1.5 years but myself:) Once you know 1 programming language, it is easy to learn other programming language. The idea is the same, they just differ in syntax. 1 CaptainLorca reacted to this Quote Share this post Link to post Share on other sites
CaptainLorca 903 #16 Posted November 28, 2017 (edited) On 30.10.2017 at 11:21, Mistletoe said: Once you know 1 programming language, it is easy to learn other programming language. The idea is the same, they just differ in syntax. Yep.. its all pretty the same. On 30.10.2017 at 07:22, Ssociety said: Even if I am the one coding my own program , when I leave the code for a month , I can't understand it anymore and I am annoyed , maybe I should be more detailed in naming variables and be more organize .. Think of reading a sentence... // small dicing php function // Variable 'Bet' is describing how much the player wants to throw into the pit of gambling $bet = 0.001; // Varbiable 'chance' is describing the chance to win $chance = 50.00; // Variable 'balance' is describing what amount of money the player has $balance = 5.000; // create a function named 'gamble' and get variables $bet and $chance - $balance is there to be added by $outCome func gamble($bet, $chance, $balance) { // if $rand is smaller than $chance, double the bet and pay out if $rand < $chance { // little math for the win $outCome = 2 * $bet; // Add the outcome to the balance of the player $newBalance = $balance + $outCome // return the new balance return $newBalance; } else { // little math for the win $outCome = 2 * $bet; // substract the outcome to the balance of the player $newBalance = $balance - $outCome // return the new balance return $newBalance; } } // print the function: print(gamle($bet, $chance, $balance)); The // blabla stuff are comments. Thats how I would read the syntax of this basic easy function. Don't use this func.. its to basic and not well done.. just wanted to show you what you need to learn. Make it readdable.. put comments in the right place and it should work out. Variables should always have a name, that make sense and are easy understandable. My code may be wrong.. didn't work with php for a while. Oh and forgot to add a variable that rands up a number between 0.00 and 100.00. not important for the example. Edited November 28, 2017 by CaptainLorca 1 Mistletoe reacted to this Quote Share this post Link to post Share on other sites
Ssociety 124 #17 Posted November 28, 2017 6 hours ago, CaptainLorca said: Yep.. its all pretty the same. Think of reading a sentence... // small dicing php function // Variable 'Bet' is describing how much the player wants to throw into the pit of gambling $bet = 0.001; // Varbiable 'chance' is describing the chance to win $chance = 50.00; // Variable 'balance' is describing what amount of money the player has $balance = 5.000; // create a function named 'gamble' and get variables $bet and $chance - $balance is there to be added by $outCome func gamble($bet, $chance, $balance) { // if $rand is smaller than $chance, double the bet and pay out if $rand < $chance { // little math for the win $outCome = 2 * $bet; // Add the outcome to the balance of the player $newBalance = $balance + $outCome // return the new balance return $newBalance; } else { // little math for the win $outCome = 2 * $bet; // substract the outcome to the balance of the player $newBalance = $balance - $outCome // return the new balance return $newBalance; } } // print the function: print(gamle($bet, $chance, $balance)); The // blabla stuff are comments. Thats how I would read the syntax of this basic easy function. Don't use this func.. its to basic and not well done.. just wanted to show you what you need to learn. Make it readdable.. put comments in the right place and it should work out. Variables should always have a name, that make sense and are easy understandable. My code may be wrong.. didn't work with php for a while. Oh and forgot to add a variable that rands up a number between 0.00 and 100.00. not important for the example. wow, you are a really big ass developer T>T Quote Share this post Link to post Share on other sites
CaptainLorca 903 #18 Posted November 28, 2017 not at all.. but that is easy to understand and every coder is coding this way. make it as easy as possible to read. And always try to use as less lines as neccessary. Quote Share this post Link to post Share on other sites
Mistletoe 430 #19 Posted November 29, 2017 And proper naming of variables for gods sake!! 1 CaptainLorca reacted to this Quote Share this post Link to post Share on other sites
Ssociety 124 #20 Posted November 29, 2017 5 hours ago, CaptainLorca said: not at all.. but that is easy to understand and every coder is coding this way. make it as easy as possible to read. And always try to use as less lines as neccessary. yeah I am trying to be more organize when it come to coding, but i having a hard time doing that hahah.. I am inborn disorganized lol Quote Share this post Link to post Share on other sites
Mistletoe 430 #21 Posted November 29, 2017 15 hours ago, Ssociety said: yeah I am trying to be more organize when it come to coding, but i having a hard time doing that hahah.. I am inborn disorganized lol The basic designing pattern then move to a bit high level designing pattern like GoF(gang of four). Im a very OC person soooo keeping my program neat is my forte Quote Share this post Link to post Share on other sites
Ssociety 124 #22 Posted November 30, 2017 6 hours ago, Mistletoe said: The basic designing pattern then move to a bit high level designing pattern like GoF(gang of four). Im a very OC person soooo keeping my program neat is my forte my forte is creating programs that I am the only one who understands hahahah lol maybe because all of my life I am the only one who codes here so I don't usually care for others to read my codes hahah Quote Share this post Link to post Share on other sites
Mistletoe 430 #23 Posted November 30, 2017 4 hours ago, Ssociety said: my forte is creating programs that I am the only one who understands hahahah lol maybe because all of my life I am the only one who codes here so I don't usually care for others to read my codes hahah The soloist xD. Youll have a problem on this once you will need to update your program or add new features. Not to mention if someone else is going to update your program 1 CaptainLorca reacted to this Quote Share this post Link to post Share on other sites
CaptainLorca 903 #24 Posted November 30, 2017 Maybe somewhen you‘re working with other people on a bigger project. You will not code everything, maybe even not see all the code.. which make it just more important to write a easy understandable code 1 Mistletoe reacted to this Quote Share this post Link to post Share on other sites
Mistletoe 430 #25 Posted November 30, 2017 True that @CaptainLorca @Ssociety youll realize the importance of an organized code when you work in a team. You'll be pissed with "spaghetti codes" trust me 1 CaptainLorca reacted to this Quote Share this post Link to post Share on other sites