Hi all,

Not sure if this is something that is possible or not but what i'm looking for is as follows.......

I have an excel sheet of football league tables. The sheet automatically updates when I enter in results
I'm looking for a way (prefibally in HTML as i'm fairly familiar with it) of transfering the table to a web page?

Is there someway of uploading the excel sheet and then linking the contents of each cell in HTML to the corresponding cell in Excel?

There's a few reasons I don't want to just put up the excel sheet up for download.
I'd rather not have it public
It's very big so it would be hassle for people to have to download it everytime they want to do look at it!

I'm sure there must be a way of linking cell A1 in Excel to a corresponding cell in a HTML table, but my searches on-line haven't found anything yet! Maybe (hopefully) i'm just searching under the wrong keywords!

Hopefully someone here can help though!

I hope that all makes sense,

Thanks in advance for your help,

N

Dani AI

Generated

you won’t be able to “bind” an HTML <td> to Excel’s A1 directly in the browser. You need a publish step that turns your workbook into something the page can load. is right that this is display-only.

Three reliable ways people ship live league tables:

  • No-code embed (fastest): Put the workbook on OneDrive/SharePoint and embed it read-only. Edits you make in Excel update the embed automatically. You can even show a named range or table only (so you are not exposing the whole sheet) by using the Item parameter in the embed URL. See Microsoft’s embed guidance for OneDrive and for SharePoint/OneDrive for Business. (support.microsoft.com)

  • API pull (cleanest control): Keep the workbook in OneDrive/SharePoint and have your site read a named range as JSON via Microsoft Graph, then render an HTML table. Example endpoint: …/workbook/worksheets/{name}/range(address='A1:G20'). This keeps the source private while your site reads only the slice it needs. (learn.microsoft.com)

  • Simple CSV pipeline (cheap and sturdy): After you enter scores, export just the standings range to a CSV that your site reads.

Excel macro (exports a range to CSV):

Sub PublishLeague()
  Dim tmp As Workbook
  With ThisWorkbook.Worksheets("Standings").Range("A1:G20")
    .Copy
    Set tmp = Workbooks.Add
    tmp.Sheets(1).Range("A1").PasteSpecial xlPasteValues
  End With
  Application.DisplayAlerts = False
  tmp.SaveAs "C:\inetpub\wwwroot\league.csv", xlCSVUTF8
  tmp.Close False
  Application.DisplayAlerts = True
End Sub

On the web server (PHP) to display it:

<?php
if (($h = fopen(__DIR__."/league.csv","r"))!==false) {
  echo "<table class=\"league\">";
  while (($row = fgetcsv($h))!==false) {
    echo "<tr>";
    foreach ($row as $c) echo "<td>".htmlspecialchars($c,ENT_QUOTES,"UTF-8")."</td>";
    echo "</tr>";
  }
  echo "</table>";
  fclose($h);
}
?>

Notes: prefer named ranges so you never leak extra sheets; keep sharing read-only; and cache the page lightly so updates appear quickly. ’s converter link is great for one-offs, but for auto-updates use one of the above.

Recommended Answers

All 5 Replies

When you say link the HTML cell with the excel cell, it's sounds to me that each change at the HTML will reflect in the excel, and vice-versa.

But what I understood is that you just want to show your excel as an HTML table. Am I right?

Yea thats right.
The Excel sheet is the one that will update when I put in results etc. I want these changes to show on a HTML league table!

Cool,

This seems to be a good way of doing it alright!

Will take a good look at it later on,

Thanks very much

Please, if you got your anwser mark as solved.

Thanks.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.