• 0

Which language would you chose between C# and PHP


Question

I'm interested in changing career paths from computer repair and troubleshooting to programming. The two languages I'm looking at are C# and PHP. I understand the two are apples and oranges in comparison because they are for two entirely different things. However, I would like to learn a language that is in high demand and could give me a good level of job security. So based on your knowledge and experience, which of these two would you think could provide that? I appreciate any feed back you can provide.

Thanks! :D

Recommended Posts

  • 0

C# is more general-purpose, it's used on a wide variety of platforms (pretty much all) to do a wide variety of things, be it games, mobile apps, traditional GUI-based applications, web servers, etc. Syntax-wise, C# has a deep Java and C++ heritage; it's also only one of a family of diverse languages running on the .NET platform, including VB, F#, IronPython, IronRuby and many more. It's also a well-designed language and a pleasure to work with in general.

I haven't learned PHP, but from what I heard, I perceive it as hackish and quirky, and it's certainly much more limited in its application domain, that is, server-side code. I even wonder if it's not going to be entirely replaced by Javascript now that Javascript is used on the server as well, but that's pure theorizing on my part.

Both are in high demand but, again, it's a question of application domain. IMO C# opens many more doors than PHP.

  • 0

Definitely C#. You can do so much more with it. You can use it with ASP.NET for server-side stuff that you would use PHP for. Then there is the added benefit of everywhere else you can use C# - desktop apps, mobile apps...

I haven't learned PHP, but from what I heard, I perceive it as hackish and quirky

That's certainly how I would describe it.

  • 0

I haven't learned PHP, but from what I heard, I perceive it as hackish and quirky

I think this article, albeit long, sums up PHP pretty nicely.

http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/

  • 0

C/C#/C++/PHP/etc. all have relatively similar syntax, the main issues come down to the bindings or APIs provided. If you're looking at web programming look into things like Ruby or Python, for desktop programming C# would be fine.

I think this article, albeit long, sums up PHP pretty nicely.

http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/

That amazed me, I knew PHP was pretty meh, but I didn't realise it was that bad.

  • 0

As someone who has used both C# and PHP, I can't express enough how much better C# is. PHP is certainly a capable language, but you do notice quite quickly some very quirky design decisions. If you have the option, pick C#.

In terms of valuability as a career choice, there's not much in it in my experience. Web developers will tend to favour PHP (or Ruby or Python) since historically its cheaper to run as it didn't require a Windows Server, it was also one of the first languages tailored to web development.

On the other hand, business programming and desktop development is usually oriented around .net languages. C# being the favourite. As a C# developer, I'm regularly being approached with offers of C# developer jobs, so you'll certainly carry value knowing C#.

TL;DR pick C#

  • 0

Between the two choices, C# easily. Not just because it's a better language, but you can use the same language and tools for near everything.. web, desktop, mobile, gaming, etc, plus it's available for multiple operating systems. (Granted, as long as you can work with the deficiencies of Mono.)

I think this article, albeit long, sums up PHP pretty nicely.

http://me.veekun.com...-of-bad-design/

Good reading, really points out some of the absurd design choices in the language.

  • 0

C#. There are a lot of jobs out there on the .NET stack from mobile apps, back end web services, asp.net web sites to desktop apps and so on. It's a far more widely used language, whereas PHP pigeonholes you into web stuff.

Its also pretty easy to go to Java which is equally in demand, or to C++. PHP is starting to go out of fashion a bit. If programming languages ever were in fashion, anyway.

  • 0

I think this article, albeit long, sums up PHP pretty nicely.

http://me.veekun.com...-of-bad-design/

Oh my God. That seems worse than C++ somehow. I think I'm going to keep not learning PHP for a while. :laugh:

[Just for the record, there's a similar, even longer rant about C++ on the internet: http://yosefk.com/c++fqa/ ]

  • 0

Oh my God. That seems worse than C++ somehow. I think I'm going to keep not learning PHP for a while. :laugh:

That article summed up my experience with PHP nicely. I hate it, but I have to live with it (albeit only occasionally, thank the maker). Unless you specifically have to, don't learn PHP. It's an ugly language that tries to look like C (and now C++ since it's adding stuff like classes and, one day, namespaces), but never quite works how you'd expect it to. The level of inconsistency is pretty staggering too, which is only multiplying now that classes are being added into the mix. Besides, if you have to, it's pretty easy to pick up if you know C/C++, as it's a C-based syntax (with extra dollar signs). If you're looking to do web development, ASP.NET, Ruby, Python, are always there, and you can't really miss with any of them, they're all far superior to PHP.

  • 0

However, I would like to learn a language that is in high demand and could give me a good level of job security.

If this is what matters to you the most, then you should also consider Java. I'm not crazy about the language, but it wins hands down in the job market.

Still, out of the two you provided, I'd go with C# - but the languages are not only different in such silly terms as syntax - they serve different purposes.

With PHP you'll end up writing web-oriented systems, whereas C# is kind of a juggernaut for anything that you can run on Windows (in some cases, also Linux and Mac OS, but I've never used MonoDevelop myself, so take it with a grain of salt).

Then again, C# and Java are fairly similar (as far as the basic concepts go, of course), except that the other one is not platform-specific.

  • 0

IMO C# opens many more doors than PHP.

I disagree. Because PHP runs on any platform, it's much more flexible. It's the old proprietary vs FOSS argument again. Personally, I'd go with the FOSS tool every time. It's free, fully supported across all platforms, and it powers a great deal of the web.

I suppose it comes down to whether you're doing web development or general development. If it's more general you're after, I'd go for something like Java, Python, C, C++, Javascript. All very much in demand.

  • 0

Microsoft implementations run on Microsoft devices, and Mono runs everywhere else. So, C# runs, and is widely used, everywhere: in the mobile space, on the server, on the desktop client, on console. I don't think the same can be said of PHP.

  • 0

Microsoft implementations run on Microsoft devices, and Mono runs everywhere else.

Exactly. So it's not Microsoft's C#. It's another implementation that's poorly supported and does not have the same capabilities. I wouldn't recommend that to anyone. If you're only developing on Microsoft platforms, fair enough, but elsewhere, you're going to run into problems.

So, C# runs, and is widely used, everywhere: in the mobile space, on the server, on the desktop client, on console. I don't think the same can be said of PHP.

1. Mono isn't free on mobile. In fact it's quite costly.

2. Mono in general isn't as feature complete as Microsoft's implementation.

3. Mono's future is uncertain. SuSE fired most of their mono development team, and the new company formed to continue it is heavily involved in trying to monetise it. I wouldn't bet on Mono surviving for much longer.

4. Microsoft could choose to assert its patents against other implementations (like Mono) if it so wished in the future.

With so many problems concerning dotnet and C#'s crossplatform support, I would never recommend it.

Richard Stallman said it best

Debian's decision to include Mono in its principal way of installing GNOME, for the sake of Tomboy which is an application written in C#, leads the community in a risky direction. It is dangerous to depend on C#, so we need to discourage its use.

The problem is not unique to Mono; any free implementation of C# would raise the same issue. The danger is that Microsoft is probably planning to force all free C# implementations underground some day using software patents. (See http://swpat.org and http://progfree.org.) This is a serious danger, and only fools would ignore it until the day it actually happens. We need to take precautions now to protect ourselves from this future danger.

This is not to say that implementing C# is a bad thing. Free C# implementations permit users to run their C# programs on free platforms, which is good. (The GNU Project has an implementation of C# also, called Portable.NET.) Ideally we want to provide free implementations for all languages that programmers have used.

The problem is not in the C# implementations, but rather in Tomboy and other applications written in C#. If we lose the use of C#, we will lose them too. That doesn't make them unethical, but it means that writing them and using them is taking a gratuitous risk.

We should systematically arrange to depend on the free C# implementations as little as possible. In other words, we should discourage people from writing programs in C#. Therefore, we should not include C# implementations in the default installation of GNU/Linux distributions or in their principal ways of installing GNOME, and we should distribute and recommend non-C# applications rather than comparable C# applications whenever possible.

  • 0

Exactly. So it's not Microsoft's C#. It's another implementation that's poorly supported and does not have the same capabilities. I wouldn't recommend that to anyone. If you're only developing on Microsoft platforms, fair enough, but elsewhere, you're going to run into problems.

1. Mono isn't free on mobile. In fact it's quite costly.

2. Mono in general isn't as feature complete as Microsoft's implementation.

3. Mono's future is uncertain. SuSE fired most of their mono development team, and the new company formed to continue it is heavily involved in trying to monetise it. I wouldn't bet on Mono surviving for much longer.

4. Microsoft could choose to assert its patents against other implementations (like Mono) if it so wished in the future.

Myths and fear-mongering.

1) Mono sees frequent updates and development has not slowed or showed signs of immobility. New features in .NET are quickly implemented in Mono, often released before Microsoft.

2) Mono does not support certain Windows-specific .NET libraries such as WPF, because they are Windows-specific (so no one cares). Otherwise, the feature set is essentially the same. Mono also offers capabilities not present in Microsoft's .NET, such as SIMD support.

3) That MonoDroid and MonoTouch cost money doesn't make them any less available and supported. Besides, most people making a living of writing software are ready to invest 400$ in their tools.

4) People have been predicting the ruin of Mono since its inception. In reality, Mono has been a successful business venue for more than a decade now. MonoDroid and MonoTouch are popular tools that sell well and make a lot of money. Most of Mono is covered by ECMA standards, most of the remainder is under Microsoft Community Promise, and the little that isn't could be worked around, and there are little grounds to suspect concrete hostility by Microsoft. For all the fear-mongering, there hasn't been a single patent claim by Microsoft in Mono's 10 years of existence. Your Richard Stallman quote was answered by Ubuntu and Fedora thus:

"It is common practice in the software industry to register patents as protection against litigation, rather than as an intent to litigate. Thus mere existence of a patent, without a claim of infringement, is not sufficient reason to warrant exclusion from the Ubuntu Project."
"We haven't come to a legal conclusion that is pat enough for us to make the decision to take mono out."
[source]
  • 0

PHP is a good language ! (obviously people talking negative about it have not used it or find it hard to even begin to understand the power php and use has) but it is server side so you would be looking more at web development.. rather then C# I would look at java as it is the language of tomorrow its growing so much and is multi platform

  • 0

I think this article, albeit long, sums up PHP pretty nicely.

http://me.veekun.com...-of-bad-design/

the person who wrote that "article" has about as much credibility as a cats anus. PHP is a good web development language I know more then just PHP (which that BS article suggests) I Have been using PHP since I was 15 and now at university getting top grades in computer programming and web programming aswell as owning a web development company along with being a developing professional so Please next time you post something which insults my line of work please understand just because you dont like it and cant comprehend it does not mean others are the same way.

  • 0

the person who wrote that "article" has about as much credibility as a cats anus. PHP is a good web development language I know more then just PHP (which that BS article suggests) I Have been using PHP since I was 15 and now at university getting top grades in computer programming and web programming aswell as owning a web development company along with being a developing professional so Please next time you post something which insults my line of work please understand just because you dont like it and cant comprehend it does not mean others are the same way.

You took that way too personally. If you disagree, that's fine. But I won't stop posting things like this just because it might offend you (or others). Next time, might I suggest pointing out what's wrong with the article rather than going on a rant? You don't have to debunk the entire article, just pointing out a few false facts or inaccuracies will do plenty to diminish the credibility of the article and help others to think differently about it.

  • 0

You took that way too personally. If you disagree, that's fine. But I won't stop posting things like this just because it might offend you (or others). Next time, might I suggest pointing out what's wrong with the article rather than going on a rant? You don't have to debunk the entire article, just pointing out a few false facts or inaccuracies will do plenty to diminish the credibility of the article and help others to think differently about it.

it wasnt so much the article and you posting it more you agreeing with everything but yes you are right I am sorry. I pointed out the key insulting thing where the article basically says anyone who learns and goes forward with PHP does not know anything else...

he also says that PHP does not have advanced error checking, this is false there is a way to get it but its add on to your libary.. while there is still alot of php I do not know with the amount I do know I can do almost anything the language is capable of doing...

is it bad there is 100 ways to do one thing in php? and 100 ways to write the same code with the same end result? no it allows a more people with different mind sets and thought patterns to use the code rather then there be one way only to do something..

he also complains about settings if this and that is turned off it wont work... he needs a clap and a half thats the point of being able to turn it off!

this guy obviously knows about PHP but does not understand it at all he read the documentation it made him rage and he hates any body smarter then him (so anyone who can do php) I dont care if someone hates PHP loads of people i learn and get taught by hate it but his article is not a side of a story and opinion he fills it with false facts or tries to make true things sound like they are one sided..

  • 0

this guy obviously knows about PHP but does not understand it at all he read the documentation it made him rage and

The article is very long and quite extensive. I don't see how you can write it off so easily.

he hates any body smarter then him

Given that the author seems to know a lot about the subject, and you're just flying off the handle for absolutely no reason...

PHP isn't perfect, although it sounds like this is news to you. Take a look at Django (Python) or ASP.NET (C#) to see why PHP is so awful. I love me some Django.

  • 0

The article is very long and quite extensive. I don't see how you can write it off so easily.

Given that the author seems to know a lot about the subject, and you're just flying off the handle for absolutely no reason...

PHP isn't perfect, although it sounds like this is news to you. Take a look at Django (Python) or ASP.NET (C#) to see why PHP is so awful. I love me some Django.

I read the whole thing.. and I know it is not the best and needs some updating I know what I am talking about I may not be grande master PHP wizard but I clearly know alot more about the benefits then him ... and just because he can read documentation does not mean he knows what he is talking about he used some code which is viable code and some which is just a different way of writing one thing ... and I am happy with my php and java thanks (not that I have not looked at them I have looked at every one but preferred these) you are entitled to your opinion about php and if you think its crap then cool but that guy who wrote the article knows nothing and he then gave loads of arguments which he tried to justify why PHP is not needed or is used and It was just a load of hog

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Vivaldi 8.0.4033.48 by Razvan Serea Vivaldi is a cross-platform web browser built for – and with – the web. A browser based on the Blink engine (same in Chrome and Chromium) that is fast, but also a browser that is rich in functionality, highly flexible and puts the user first. A browser that is made for you. Vivaldi is produced with love by a founding team of browser pioneers, including former CEO Jon Stephenson von Tetzchner, who co-founded and led Opera Software. Vivaldi’s interface is very customizable. Vivaldi combines simplicity and fashion to create a basic, highly customizable interface that provides everything a internet user could need. The browser allows users to customize the appearance of UI elements such as background color, overall theme, address bar and tab positioning, and start pages. Vivaldi features the ability to "stack" and "tile" tabs, annotate web pages, add notes to bookmarks and much more. Vivaldi 8.0.4033.48 changes: [Chromium] Update to 148.0.7778.267 ESR (includes security fixes from 149.0.7827.114/115) [Crash] When closing devtools with input caret in a CSS property field (VB-128998) [Linux][Media] Fetch an updated proprietary media support file (VB-129132) [Permissions] Global Permissions counter shows all permissions (64) as overridden (VB-127713) Download: Vivaldi 64-bit | 139.0 MB (Freeware) Download: Vivaldi 32-bit | ARM64 View: Vivaldi Home Page | Screenshot Get alerted to all of our Software updates on Twitter at @NeowinSoftware
    • Two variants of the KAMRUI H2 mini PC receive deeper discounts on Amazon by Steven Parker KAMRUI (sister company of AceMagic) reached out to us, letting us know that they are applying further discounts to two of their H2 mini PC variants, and in times like these, every little helps. First off, it's the Core i5 14450HX 32GB+1TB variant, which already received a discount from $699 to $567.99 on Amazon, so you may be asking what you get for that. Its most important features are listed below. 32GB Memory Configuration, Exceptional Value. Driven by rising AI demand, the DDR memory supply is tightening, making high-capacity memory more valuable. KAMRUI maintains high-quality standards while offering strong value with a 32GB RAM + 1TB SSD configuration, which delivers excellent performance and storage. Intel i5-14450HX, HX-Class Performance Powered by the Intel Core i5-14450HX (10 cores/16 threads, up to 4.8GHz, 54W TDP)-HX series delivers desktop-class performance. Enjoy up to 120% higher multi-core performance vs. i7-1185G7 and stronger sustained performance than Ryzen 9 6900HX under heavy workloads. With 14450HX performance, it handles coding, compiling, Docker with ease, runs 10+ apps simultaneously—Excel, Chrome, Zoom, video editing—with smooth multitasking and fast load times. 32GB RAM & 1TB NVMe SSD - expandable up to 4TB Mini pc W-11 Pro equipped with 32GB (16GB×2) DDR4 dual-channel memory and a 1TB NVMe PCIe 4.0×4 SSD, mini pc delivers fast system response and efficient data access for demanding workloads. Dual M.2 slots support storage expansion up to 4TB. Large memory support running multiple virtual machines simultaneously, enabling fast deployment and isolated sandbox testing, significantly improving development efficiency and multitasking performance. HX-Class Heat Dissipation, Higher Productivity 14450HX Mini computers W-11 pro equipped with upgraded silent centrifugal fans, dual copper heat pipes, dual fin-stack cooling modules, and an optimized dual-airflow design, the processor can maintain ≥95% of multi-core performance even under long-duration heavy workloads. The HX platform is specifically designed for multitasking, rendering, and content creation, and multitasking, delivering desktop-class stability and powerful performance. Triple 4K Productivity Power Supports triple 4K displays and handles complex workflows like coding, data processing, and multitasking with ease. WiFi 6 delivers fast, reliable connectivity for video, conferencing, and transfers. Bluetooth 5.2 ensures stable, low-latency wireless connections. Versatile Connectivity This mini computer comes with 1x Type-C(10Gbps data transfer), 1x RJ45 Ethernet, 2x USB3.2 Gen2 (10Gbps), 4x USB3.2 Gen1 Type-A (5Gbps), PD output, 1x HDMI 2.0, 1x DP 1.4, and 1x 3.5mm audio jack. It offers versatile connectivity to connect multiple devices effortlessly, reducing the need for frequent plugging and unplugging. Small Size, Big Performance Mini PC measures just 5.04 × 5.04 × 1.63 inches, over 80% smaller than a traditional desktop, yet equipped with the high-performance 14450HX processor for near-desktop-level power. With VESA mounting support, it transforms cluttered desks into clean, organized setups. Normally costing $699, but now down to $ 535.79, which includes an additional 6% off the Amazon listed price. That equals a total of 24% off the MSRP. KAMRUI Hyper H2 (Core i5 14450HX 32GB+1TB) for $ 535.79 (was $699) Use code 2UD2IW7D for the above price during checkout (expires on June 30) Editors note: This appears to be listed as a "frequently returned item" on Amazon, but you should take into account the reviews on the page that discuss a completely different PC, it would seem that this is yet another recycled sales page that is now listing this newer item, possibly to retain the positive 4.5 star rating on the page. Next up, we have the Core i9 14900HX/32GB+1TB variant, which normally costs $799.99 but is already discounted to $759.99 on Amazon. Again, the most important highlights for this variant are listed below. Upgrade 14th Intel Core i9-14900HX Processor KAMRUI Mini Computers features the 14th Gen Intel Core i9-14900HX processor (up to 5.8GHz, TDP 55W, 36MB cache, 24C/32T), delivering 25%–40% higher performance than the i5-14450HX (24C/32T) and i7-1280P in multitasking, creative work, and high-load applications. Manufactured using Intel 7 (10 nm) process technology, Mini Computer efficiently allocates workloads to deliver faster response times, smoother operation, and heightened productivity. 32GB DDR4 & 1TB SSD - Expandable to 4TB KAMRUI Intel Core i9-14900HX mini PC features dual-channel 32GB DDR memory (expandable to 64GB) and 1TB NVMe PCIe 4.0×4 SSD, delivering speeds 40% faster than PCIe Gen3. The KAMRUI Micro PC features two M.2 2280 SSD slots, each expandable up to 2TB, effortlessly accommodating a high-capacity system drive and an ultra-fast cache drive. This achieves a perfect balance of speed, capacity, and flexibility, effortlessly handling large projects and high-speed workflows. 4K UHD Triple Display KAMRUI 14900HX Mini PC features a 4K@60Hz UHD graphics card (Intel UHD Graphics), supporting 4K@60Hz high-definition video playback for a premium visual experience. Mini Gaming PC incorporates an HDMI 2.0 port + DP 1.4 port + USB3.2 Gen2 Type-C port, supporting 4K triple display output. Mini PC can connect to three monitors to fulfil your multi-screen collaboration requirements. Ultra-high-definition visuals and ultra-fast connectivity significantly enhance your productivity. RJ45 LAN Port+WiFi6E+BT5.2 KAMRUI Mini PC features a 1.0Gbps LAN port, suitable for high-speed broadband environments in homes, offices, and large enterprises. Bluetooth 5.2 enables connection to peripherals such as headphones, mice, and keyboards. Dual-band WiFi 6E and BT 5.2 deliver enhanced interference resistance and more stable wireless signals. Regardless of your network environment's complexity, the KAMRUI H2 mini computer delivers a relatively stable and smooth network experience. Professional-Grade Cooling System KAMRUI Mini gaming PC features an upgraded silent centrifugal fan, dual copper heat pipes, and a dual-fin module. Its all-copper structure enhances thermal conductivity, boosting airflow efficiency by 35% and overall heat dissipation by 40%, ensuring the CPU can stably deliver up to 55W performance under full load. Upgraded aluminum heatsink keeps the SSD cool to maintain read/write speeds, ensuring desktop-level stability and power for demanding workloads. Compact Size, Infinite Possibilities KAMRUI H2 mini computers measure just 5.04 x 5.04 x 1.63 inches, a fraction of the size of a traditional desktop, yet deliver powerful performance for demanding workloads. With the included VESA mount, you can easily attach a small pc behind a monitor or place it in your TV cabinet, turning your display into a sleek mini PC while saving valuable desk space. Versatile Connectivity This KAMRUI mini gaming computer comes with 1*USB3.2 Gen2 Type-C(up to 10Gbps data transfer), 1*RJ45 Ethernet, 2*USB3.2 Gen2 (10Gbps), 4*USB3.2 Gen1 Type-A (5Gbps), 1*HDMI 2.0, 1*DC, 1*DP 1.4, and 1*3.5mm audio jack. It offers versatile connectivity to connect multiple devices effortlessly, reducing the need for frequent plugging and unplugging. Normally costing $799, but now down to $721.99, which includes an additional 5% off the Amazon listed price. That equals a total of 10% off the MSRP. KAMRUI Hyper H2 (Core i9 14900HX/32GB+1TB) for $ 721.99 (was $799) Use code AQ5Z6A47 for the above price during checkout (expires on June 30) KAMRUI claims that they offer lifetime technical support along with a 12-month warranty. For either of these mini PCs, should you encounter any issues during use, KAMRUI claims it will do its utmost to assist customers. As an Amazon Associate, we earn from qualifying purchases.
    • Good. I hope more people sue them for focusing on this worthless junk.
    • How about fire the guy who approved all the bad decisions? The guy who bought these studios in the first place? Oh wait, Satya is safe with his billions while the workers pay the price.
  • Recent Achievements

    • One Year In
      Console General earned a badge
      One Year In
    • One Year In
      Twozo Technologies earned a badge
      One Year In
    • One Month Later
      Twozo Technologies earned a badge
      One Month Later
    • Week One Done
      Twozo Technologies earned a badge
      Week One Done
    • Veteran
      branfont went up a rank
      Veteran
  • Popular Contributors

    1. 1
      +primortal
      514
    2. 2
      +Edouard
      200
    3. 3
      PsYcHoKiLLa
      108
    4. 4
      Steven P.
      89
    5. 5
      Nick H.
      71
  • Tell a friend

    Love Neowin? Tell a friend!