League Table From Notepad

This is a discussion on "League Table From Notepad" within the Web Page Design section. This forum, and the thread "League Table From Notepad are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Apr 16th, 2008, 20:49
New Member
Join Date: Jul 2007
Location: Sutton
Age: 48
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
League Table From Notepad

Can anyone please help with uploading League Tables that are sent to me in a Notepad.txt file.

Every week I receive a list of results and league tables in a Notepad file that in Notepad are all in line and easily readable but when pasted in to an html file via Front Page the table looses its format and is all out of line.

I know how to make tables from scratch but as I receive over 24 league tables per weekend it would be much appreciated if someone knows how to enter the Notepad text, to keep the table format.

The table appears as follows via Front Page but looks perfect in Notepad.


Team P W D L F A Pts
Team 1 FC 12 10 1 1 55 12 31
Team 2 FC 10 9 1 0 43 7 28
Team United FC 11 7 1 3 46 12 22
Team RANGERS FC 14 5 5 4 33 24 20
Team City 13 5 2 6 35 36 17
Team TOWN COLTS 12 4 3 5 34 20 15
Team FC 14 4 2 8 25 48 14
Team COLTS. 15 3 2 10 18 67 11
Team WEL TIGERS. 13 1 1 11 11 74 4

Any help would be appreciated.
Reply With Quote

  #2 (permalink)  
Old Apr 16th, 2008, 21:49
unitedcraig's Avatar
SuperMember

SuperMember
Join Date: Oct 2007
Location: Stockport
Age: 17
Posts: 849
Blog Entries: 1
Thanks: 0
Thanked 1 Time in 1 Post
Re: League Table From Notepad

Could you not just use a template and copy and paste them into that?
__________________
Last Blog Entry: A Royal Mistake (Feb 20th, 2008)
Reply With Quote
  #3 (permalink)  
Old Apr 16th, 2008, 23:30
Reputable Member
Join Date: Mar 2008
Location: Chester, UK
Age: 17
Posts: 393
Thanks: 2
Thanked 26 Times in 26 Posts
Re: League Table From Notepad

i didn't think notepad had any formating? i thought it was a wordpad thing.

The easiest thing would be a simple php script for updating, if your server supported that... it'd probably be about tutorial 6ish on any beginners guides to php.

Failing that you just need to do a little bit of extra leg work...

However i have no experience using front page... have you tried doing it manually? i know front page has tons of issues with the code it outputs.

Can you submit the html code generated by front page?

So we can see exactly what it's doing with its code?

You might be better c&p it into word, and format it, i'm pretty sure formatting in word can be copied/pasted.
Reply With Quote
  #4 (permalink)  
Old Apr 17th, 2008, 00:53
Rob's Avatar
Rob Rob is offline
Head Admin & CEO

SuperMember
Join Date: Jul 2003
Location: at my desk
Age: 34
Posts: 2,953
Blog Entries: 7
Thanks: 7
Thanked 4 Times in 4 Posts
Re: League Table From Notepad

the editor is irrelevant. You are sent these weekly in plain text and NOT html....

Therin lies your problem. either convert them to an HTML table yourself or have the person make a table and send you the HTML.
__________________
Rob - SEO Specialist
Owner & Founder of Webforumz.com

I am currently unavailable for private work
Reply With Quote
  #5 (permalink)  
Old Apr 17th, 2008, 17:14
Reputable Member
Join Date: Mar 2008
Location: Chester, UK
Age: 17
Posts: 393
Thanks: 2
Thanked 26 Times in 26 Posts
Re: League Table From Notepad

Some editors adapt the syles tho, for example if you copy text of the internet
into word it keeps the styling, unlike some editors or older versions of word, however it would only work in reverse with a wysiwyg editor, and probably not all of them.
Reply With Quote
  #6 (permalink)  
Old Apr 17th, 2008, 18:43
New Member
Join Date: Jul 2007
Location: Sutton
Age: 48
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Re: League Table From Notepad

Thanks for everyones input.

Unfortunately I have tried copy and pasting in to Word and saving as an html file and several other options, but Notepad does not hold any useful formatting at all.

The tables look good in Notepad but once transferred to an html document all table formatting is lost.

I will look at the php scripts as suggested to see if suitable. Its a shame as what is only a 2 min job with c&p, actually changing into proper tables for 20 leagues would take hours, unless anyone knows different!
Reply With Quote
  #7 (permalink)  
Old Apr 17th, 2008, 20:36
Up'n'Coming Member
Join Date: Apr 2008
Location: Or-Yehuda, Israel
Age: 60
Posts: 92
Thanks: 0
Thanked 0 Times in 0 Posts
Re: League Table From Notepad

It should be quite easy.

One thing maybe will make it a little easier, get an editor like Note Tab Light that shows end of line too.

Then follow these steps:
1. Copy your text into Note Tab Light as is.
Code: Select all
Team P W D L F A Pts
Team 1 FC 12 10 1 1 55 12 31
Team 2 FC 10 9 1 0 43 7 28
Team United FC 11 7 1 3 46 12 22
Team RANGERS FC 14 5 5 4 33 24 20
Team City 13 5 2 6 35 36 17
Team TOWN COLTS 12 4 3 5 34 20 15
Team FC 14 4 2 8 25 48 14
Team COLTS. 15 3 2 10 18 67 11
Team WEL TIGERS. 13 1 1 11 11 74 4
2. Make the Teams into a single string by connecting the separate words with an _ (there is method in my madness)
Code: Select all
Team P W D L F A Pts
Team_1_FC 12 10 1 1 55 12 31
Team_2_FC 10 9 1 0 43 7 28
Team_United_FC 11 7 1 3 46 12 22
Team_RANGERS_FC 14 5 5 4 33 24 20
Team_City 13 5 2 6 35 36 17
Team_TOWN_COLTS 12 4 3 5 34 20 15
Team_FC 14 4 2 8 25 48 14
Team_COLTS. 15 3 2 10 18 67 11
Team_WEL_TIGERS. 13 1 1 11 11 74 4
3. With the REPLACE TEXT function replace " " (empty space) with "</td><td>"
Code: Select all
Team</td><td>P</td><td>W</td><td>D</td><td>L</td><td>F</td><td>A</td><td>Pts
Team_1_FC</td><td>12</td><td>10</td><td>1</td><td>1</td><td>55</td><td>12</td><td>31
Team_2_FC</td><td>10</td><td>9</td><td>1</td><td>0</td><td>43</td><td>7</td><td>28
Team_United_FC</td><td>11</td><td>7</td><td>1</td><td>3</td><td>46</td><td>12</td><td>22
Team_RANGERS_FC</td><td>14</td><td>5</td><td>5</td><td>4</td><td>33</td><td>24</td><td>20
Team_City</td><td>13</td><td>5</td><td>2</td><td>6</td><td>35</td><td>36</td><td>17
Team_TOWN_COLTS</td><td>12</td><td>4</td><td>3</td><td>5</td><td>34</td><td>20</td><td>15
Team_FC</td><td>14</td><td>4</td><td>2</td><td>8</td><td>25</td><td>48</td><td>14
Team_COLTS.</td><td>15</td><td>3</td><td>2</td><td>10</td><td>18</td><td>67</td><td>11
Team_WEL_TIGERS.</td><td>13</td><td>1</td><td>1</td><td>11</td><td>11</td><td>74</td><td>4
4. With the REPLACE TEXT function replace "^P" (line feed/end of line) with "</td></tr><tr>^P"
Code: Select all
Team</td><td>P</td><td>W</td><td>D</td><td>L</td><td>F</td><td>A</td><td>Pts</td></tr><tr>
Team_1_FC</td><td>12</td><td>10</td><td>1</td><td>1</td><td>55</td><td>12</td><td>31</td></tr><tr>
Team_2_FC</td><td>10</td><td>9</td><td>1</td><td>0</td><td>43</td><td>7</td><td>28</td></tr><tr>
Team_United_FC</td><td>11</td><td>7</td><td>1</td><td>3</td><td>46</td><td>12</td><td>22</td></tr><tr>
Team_RANGERS_FC</td><td>14</td><td>5</td><td>5</td><td>4</td><td>33</td><td>24</td><td>20</td></tr><tr>
Team_City</td><td>13</td><td>5</td><td>2</td><td>6</td><td>35</td><td>36</td><td>17</td></tr><tr>
Team_TOWN_COLTS</td><td>12</td><td>4</td><td>3</td><td>5</td><td>34</td><td>20</td><td>15</td></tr><tr>
Team_FC</td><td>14</td><td>4</td><td>2</td><td>8</td><td>25</td><td>48</td><td>14</td></tr><tr>
Team_COLTS.</td><td>15</td><td>3</td><td>2</td><td>10</td><td>18</td><td>67</td><td>11</td></tr><tr>
Team_WEL_TIGERS.</td><td>13</td><td>1</td><td>1</td><td>11</td><td>11</td><td>74</td><td>4</td></tr><tr>
5. Now delete the last <tr>

6. Add
Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="content-type">
  <title></title>
</head>
<body>
<table style="text-align: left; width: 75%;" border="1"
 cellpadding="2" cellspacing="2">
  <tbody>
<tr>
to the top

7. Add
Code: Select all
  </tbody>
</table>
<html>
to the bottom

8. Get rid if the underlines placed in Step 2. and put back the " " spaces (replace again)
Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="content-type">
  <title></title>
</head>
<body>
<table style="text-align: left; width: 75%;" border="1"
 cellpadding="2" cellspacing="2">
  <tbody>
<tr>

Team</td><td>P</td><td>W</td><td>D</td><td>L</td><td>F</td><td>A</td><td>Pts</td></tr><tr>
Team 1 FC</td><td>12</td><td>10</td><td>1</td><td>1</td><td>55</td><td>12</td><td>31</td></tr><tr>
Team 2 FC</td><td>10</td><td>9</td><td>1</td><td>0</td><td>43</td><td>7</td><td>28</td></tr><tr>
Team United FC</td><td>11</td><td>7</td><td>1</td><td>3</td><td>46</td><td>12</td><td>22</td></tr><tr>
Team RANGERS FC</td><td>14</td><td>5</td><td>5</td><td>4</td><td>33</td><td>24</td><td>20</td></tr><tr>
Team City</td><td>13</td><td>5</td><td>2</td><td>6</td><td>35</td><td>36</td><td>17</td></tr><tr>
Team TOWN COLTS</td><td>12</td><td>4</td><td>3</td><td>5</td><td>34</td><td>20</td><td>15</td></tr><tr>
Team FC</td><td>14</td><td>4</td><td>2</td><td>8</td><td>25</td><td>48</td><td>14</td></tr><tr>
Team COLTS.</td><td>15</td><td>3</td><td>2</td><td>10</td><td>18</td><td>67</td><td>11</td></tr><tr>
Team WEL TIGERS.</td><td>13</td><td>1</td><td>1</td><td>11</td><td>11</td><td>74</td><td>4</td></tr>

  </tbody>
</table>
<html>
Now you have perfectly valid table in HTML

9. Save as whatever.html
Reply With Quote
  #8 (permalink)  
Old Apr 17th, 2008, 20:54
New Member
Join Date: Jul 2007
Location: Sutton
Age: 48
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Re: League Table From Notepad

Thanks for the suggestion.

It looks as though there is a step missing, as everything except the 'Teams' are included in the table, the teams are listed above the table, whilst all the points etc are listed nicely in the correct Table format, but it looks promising.
Reply With Quote
  #9 (permalink)  
Old Apr 18th, 2008, 10:37
Up'n'Coming Member
Join Date: Apr 2008
Location: Or-Yehuda, Israel
Age: 60
Posts: 92
Thanks: 0
Thanked 0 Times in 0 Posts
Re: League Table From Notepad

OK

Step 4 a
Replace "Team_" with "" (null string)
Code: Select all
Team</td><td>P</td><td>W</td><td>D</td><td>L</td><td>F</td><td>A</td><td>Pts</td></tr><tr>
1_FC</td><td>12</td><td>10</td><td>1</td><td>1</td><td>55</td><td>12</td><td>31</td></tr><tr>
2_FC</td><td>10</td><td>9</td><td>1</td><td>0</td><td>43</td><td>7</td><td>28</td></tr><tr>
United_FC</td><td>11</td><td>7</td><td>1</td><td>3</td><td>46</td><td>12</td><td>22</td></tr><tr>
RANGERS_FC</td><td>14</td><td>5</td><td>5</td><td>4</td><td>33</td><td>24</td><td>20</td></tr><tr>
City</td><td>13</td><td>5</td><td>2</td><td>6</td><td>35</td><td>36</td><td>17</td></tr><tr>
TOWN_COLTS</td><td>12</td><td>4</td><td>3</td><td>5</td><td>34</td><td>20</td><td>15</td></tr><tr>
FC</td><td>14</td><td>4</td><td>2</td><td>8</td><td>25</td><td>48</td><td>14</td></tr><tr>
COLTS.</td><td>15</td><td>3</td><td>2</td><td>10</td><td>18</td><td>67</td><td>11</td></tr><tr>
WEL_TIGERS.</td><td>13</td><td>1</td><td>1</td><td>11</td><td>11</td><td>74</td><td>4</td></tr><tr>
Then continue with Step 5 etc...

and 4 should read: With the REPLACE TEXT function replace "^P" (line feed/end of line) with "</td></tr><tr>^P"<td>


Final result after formating:

Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
 http-equiv="content-type">
<title></title>
</head>
<body> 
<table style="text-align: left; width: 75%;" border="1"
 cellpadding="2" cellspacing="2"> 
  <tbody> 
    <tr> 
      <td>Team</td> 
      <td>P</td> 
      <td>W</td> 
      <td>D</td> 
      <td>L</td> 
      <td>F</td> 
      <td>A</td> 
      <td>Pts</td> 
    </tr> 
    <tr> 
      <td> 1 FC</td> 
      <td>12</td> 
      <td>10</td> 
      <td>1</td> 
      <td>1</td> 
      <td>55</td> 
      <td>12</td> 
      <td>31</td> 
    </tr> 
    <tr> 
      <td> 2 FC</td> 
      <td>10</td> 
      <td>9</td> 
      <td>1</td> 
      <td>0</td> 
      <td>43</td> 
      <td>7</td> 
      <td>28</td> 
    </tr> 
    <tr> 
      <td> United FC</td> 
      <td>11</td> 
      <td>7</td> 
      <td>1</td> 
      <td>3</td> 
      <td>46</td> 
      <td>12</td> 
      <td>22</td> 
    </tr> 
    <tr> 
      <td> RANGERS FC</td> 
      <td>14</td> 
      <td>5</td> 
      <td>5</td> 
      <td>4</td> 
      <td>33</td> 
      <td>24</td> 
      <td>20</td> 
    </tr> 
    <tr> 
      <td> City</td> 
      <td>13</td> 
      <td>5</td> 
      <td>2</td> 
      <td>6</td> 
      <td>35</td> 
      <td>36</td> 
      <td>17</td> 
    </tr> 
    <tr> 
      <td> TOWN COLTS</td> 
      <td>12</td> 
      <td>4</td> 
      <td>3</td> 
      <td>5</td> 
      <td>34</td> 
      <td>20</td> 
      <td>15</td> 
    </tr> 
    <tr> 
      <td> FC</td> 
      <td>14</td> 
      <td>4</td> 
      <td>2</td> 
      <td>8</td> 
      <td>25</td> 
      <td>48</td> 
      <td>14</td> 
    </tr> 
    <tr> 
      <td> COLTS.</td> 
      <td>15</td> 
      <td>3</td> 
      <td>2</td> 
      <td>10</td> 
      <td>18</td> 
      <td>67</td> 
      <td>11</td> 
    </tr> 
    <tr> 
      <td> WEL TIGERS.</td> 
      <td>13</td> 
      <td>1</td> 
      <td>1</td> 
      <td>11</td> 
      <td>11</td> 
      <td>74</td> 
      <td>4</td> 
    </tr> 
  </tbody> 
</table> 
<html>





Last edited by shalom_m; Apr 18th, 2008 at 10:48.
Reply With Quote
  #10 (permalink)  
Old Apr 18th, 2008, 18:07
New Member
Join Date: Jul 2007
Location: Sutton
Age: 48
Posts: 8
Thanks: 0
Thanked 0 Times in 0 Posts
Thumbs up Re: League Table From Notepad

Thanks for the amendment, which now appears to give a good formatted League Table and the programme is Free!

All now left is to find out how to use it.

Thanks for your help.
Reply With Quote
  #11 (permalink)  
Old Apr 18th, 2008, 19:45
Up'n'Coming Member
Join Date: Apr 2008
Location: Or-Yehuda, Israel
Age: 60
Posts: 92
Thanks: 0
Thanked 0 Times in 0 Posts
Re: League Table From Notepad

There is more than one way to skin a ........ (insert whatever is culturally, politically and morally correct for you)!

Alternatively

You could write a routine in VB or C# to do the above.

or

Use Excel to do the same.
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Another NotePad++ question dhall Starting Out 0 Aug 21st, 2007 16:57
Notepad++ question dhall Starting Out 3 Aug 19th, 2007 20:29
Notepad Is annoying me Accurax Webforumz Cafe 21 Mar 12th, 2007 12:18
how to use notepad in flash reeta.vadgama Flash & Multimedia Forum 4 Jul 31st, 2006 15:21
Fantasy League db design tycoon Databases 1 May 7th, 2004 18:47


All times are GMT. The time now is 05:35.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43