views:

191

answers:

4
+1  Q: 

.php to .aspx

Hello all, I had a project for developing a website for a NGO. I had a doubt: The website is already working with lot of flaws and had very few pages. This website is made in Php and They want me to make it more secure. So i want to make this website using Microsoft .NET Framework. If i make this website from scratch and then want to host it on the same url which is currently they had,will it be possible as in i am changing the whole website and making it in a different platform.

Please help. Thanks

+9  A: 

Using the same URL is easy. That's nothing more than a DNS-issue. You may run into problems with links on the web that go to .php pages, which will no longer exist. That being said, the more important issue follows:

You should explain to them that .NET is not necessarily "more secure" simply because it's .NET. The competency of the application will only reflect that of the developer. If you want a secure PHP app, you can achieve that easily (as long as you take your time, and do thoughtful work). If you aren't well-qualified, or too hasty, you can just as easily create an terrible .NET application.

PHP is secure enough for Google, Yahoo, and many other large corporations to use it.

Jonathan Sampson
Ok, but if we are totally migrating all .php pages into .aspx then there will be no problem to redirecting to links.For above question should i have to change database also?
Nipun
Again, if you have links that are pointing to .php, you will have a problem. You'll have to setup your site to redirect all of these old links to the new .aspx pages. Yes, you may need to update your database from MySQL (which I'm assuming you are using) to SQLServer.
Jonathan Sampson
One little addition: You can re-use the .php urls through either rewrite rules, or by mapping .php to the .net runtime and modifying the web.config accordingly. The latter can get really confusing, but i've seen sites employ such techniques when switching platforms to make sure they don't break all bookmarks.
Michael Stum
+1  A: 

You can certainly reuse the URL. Simply point the name servers to your new IIS server. You can even intercept requests for .PHP URLS and redirect them to corresponding .ASPX URLs - though this should be a temporary/migration solution; you don't really want to stick with PHP URLs for the longer term if you are actually using IIS/.NET. Are you only interested in keeping the domain or are specific URLs important?

It would be a good idea to redirect (HTTP 301) some or all requests to the original (PHP) pages to the new pages.

However, .NET is not necessarily any more secure than PHP anyway. It depends on the developers implementation; either platform can be made equally secure. Clearly, if the current site is badly designed, and you have been chosen to write a replacement and .NET is your preferred platform, then go ahead - just make sure you don't repeat the same mistakes in .NET.

What do you mean by secure anyway? Is the site an secured application or portal. That is, is it the security of the application you are concerned about, or the security of the underlying web server (apache)? Again the same argument applies - both Apache and IIS can be made equally secure if configured correctly.

CJM
+1  A: 

This website is made in Php and They want me to make it more secure. So i want to make this website using Microsoft .NET Framework.

I liked this... Well, better do a proper code/applicaiton review and fix the so called flaws. Both PHP and .NET (and anything) are 'Good' and 'Bad' depends on how it is programmed.

NinethSense
+1  A: 

As noted, redoing the site in ASP.NET does not necessarily make it more secure.

As for re-using the same urls, it is indeed possible to remap the .php extension to be handled by asp.net, and have your asp.net files have .php extensions rather than .asp extensions, thus preserving any links that may be already present.

You can also use URL rewriting to accomplish the same thing, depending on the version of IIS you have in place.

Conrad