Click here to Skip to main content
11,933,253 members (63,334 online)
Rate this:
Please Sign up or sign in to vote.
See more: ASP.NET PHP
echo "<hr>";
$tableau=preg_split("/( )+/",$texte);
echo $texte."<br>";
foreach($tableau as $e){
echo "<Table border=1>";
echo "<tr><th>Mot</th><th>nbr occurences</th><th>distribution</th></tr>";
foreach(array_keys($T) as $e){
echo "<tr><td>$e</td><td>".round($T[$e]*100/$total,2)." %</td><td>".sqrt($T2[$e])."</td></tr>";
echo "</table>";
Posted 22-Mar-13 14:12pm
ThePhantomUpvoter 22-Mar-13 19:59pm
Learning ASP.NET would be a good place to start. CodeProject is not a code translation service. You could go to and hire someone to do this for you.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

I recently ran into the same situation. I know very little php, but I had to convert an entire website. White much of the php code is easy to read, there is no easy solution for direct conversion. This is because php is a scripting language while .NET is not.

From what I see in your code, you are programatically creating an HTML table and loading it with values. You can do the same thing in ASP.NET using DataGrids, DataReaders, etc. If you are trying to manually create the HTML table and populate it in .NET, you can always use Literals.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web04 | 2.8.151126.1 | Last Updated 22 Mar 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100