ASP Code - Tracking football squares (10x10 matrix)

B

binger

Okay,
Superbowl is only a few days away, but I thought it would be cool to
set up an online registration for a football squares pool.

My thoughts are to have people go into anywhere on the 10x10 matrix
and put their name in.
If someone already has put their name in a square, then the text input
box is now static (i.e. cant be overwritten)...

Only problem - I'm not sure how to do this. I'd plan on using an
access database with ASP...but was wondering if anyone has quick
thoughts (or maybe actual working code)...on how to do this???

Would the database be best served with 100 rows of data (1 for each
square), or 1 row with 100 columns of data...??? thoughts?
Thanks!
Go Pats...
 
A

ActionJackson

I named my dog Bunger so when I say your name I had to reply!!

I would never make a 100 columns in your table for this kind of app. If
the position matters just record a value from 1 to 100 for each person.
As you output the columns/rows just use box 1 as the upper left and 10
is upper right. Box 11 would just be the start of the 2nd row and
continue this pattern using a loop.

Access and ASP would be ok for this one. You would simply record the
name and position. 2 columns of data. Very simple.

I do admit I don't even know what a football squares pool is so maybe
there is more to this app than I know :)

Shawn Jackson
Owner and Creator
http://www.actionjackson.com
http://www.devdex.com
 
B

binger

ActionJackson said:
I named my dog Bunger so when I say your name I had to reply!!

I would never make a 100 columns in your table for this kind of app. If
the position matters just record a value from 1 to 100 for each person.
As you output the columns/rows just use box 1 as the upper left and 10
is upper right. Box 11 would just be the start of the 2nd row and
continue this pattern using a loop.

Access and ASP would be ok for this one. You would simply record the
name and position. 2 columns of data. Very simple.

I do admit I don't even know what a football squares pool is so maybe
there is more to this app than I know :)

Shawn Jackson
Owner and Creator
http://www.actionjackson.com
http://www.devdex.com

....some people do call me Bunger for run...
as for a football square pool : think of this:
Start with a 10 x 10 matrix. Have people fill their names in all of
the 100 cells. Then, randomly place the numbers 0 thru 9 across the
horizontal access, then do the same down the vertical axis.
For the football pool, the horizontal axis represents team 1, and the
horizontal axis represents team 2. At the end of each quarter played,
you would look at the "ones digit" for each team, and find out where
this numeric combination meets in the squares. I.e. if team 1 had 17
points, and team 2 had 14 points, you would find the intersection of
team 1(7) and team 2(4) and whoevers name was there would win $$ for
that quarter...

Therefore, I was looking for a routine where people could visually see
a 10X10 matrix on the screen, each cell with an input box to put their
name it. As soon as someone would select a square (and input it),
that cell becomes 'fixed', and only the un-selected squares remaining
are available for text input...

Hope that makes sense...any further ideas???
Thanks,
bUnger...
 
R

Roland Hall

:
: ActionJackson wrote:
: > I would never make a 100 columns in your table for this kind of app. If
: > the position matters just record a value from 1 to 100 for each person.
: > As you output the columns/rows just use box 1 as the upper left and 10
: > is upper right. Box 11 would just be the start of the 2nd row and
: > continue this pattern using a loop.
: >
: > Access and ASP would be ok for this one. You would simply record the
: > name and position. 2 columns of data. Very simple.
:
: Therefore, I was looking for a routine where people could visually see
: a 10X10 matrix on the screen, each cell with an input box to put their
: name it. As soon as someone would select a square (and input it),
: that cell becomes 'fixed', and only the un-selected squares remaining
: are available for text input...

http://www.partysoftware.com/Football_Squares.html
 
J

Jeff Cochran

Superbowl is only a few days away, but I thought it would be cool to
set up an online registration for a football squares pool.

Assuming you're doing this in the Bahamas of course... :)
My thoughts are to have people go into anywhere on the 10x10 matrix
and put their name in.
If someone already has put their name in a square, then the text input
box is now static (i.e. cant be overwritten)...

Better, just print the names and empty squares get a "Click here to
select this square" link.
Only problem - I'm not sure how to do this. I'd plan on using an
access database with ASP...but was wondering if anyone has quick
thoughts (or maybe actual working code)...on how to do this???

Did you Google for any? The code really wouldn't be hard, but you'll
have to learn quick.
Would the database be best served with 100 rows of data (1 for each
square), or 1 row with 100 columns of data...??? thoughts?

Always less columns than rows. Especially since you could have as
little as a single column for this.

Jeff
 
B

binger

Peter - awesome help...i took what you sent and this rocked!!!!!
thanks again for the recommendations...

.....go patriots...


2004 FOOTBALL SQUARES POOL&nbsp; <BR>
<font color="#FF0000">
PATRIOTS SCORE ACROSS THE TOP<BR>
</font><font color="#0000FF">
PANTHERS SCORE DOWN THE SIDE</font>
<p align="center">$50 FOR 2 SQUARES !!!!
</p>
<ul>
<li>
<p align="left">OFFICIAL NUMBERS WILL BE DRAWN PRIOR TO KICKOFF
THIS SUNDAY</li>
<li>
<p align="left">ONCE YOU SUBMIT YOUR SQUARE - YOU CAN NOT UNDO
YOUR
SELECTION - SO BE SURE OF YOUR PICKS...</li>
<li>
<p align="left">PATRIOTS WILL KICK ASS</li>
</ul>
<form method="POST" action="update.asp" >
<div align="center">
<center>
<table border="1" height="400" width="400">
<%
do while Not rs.eof
response.write("<tr>")
for i = 1 to 10
response.write("<td>")
Response.Write "<input name=""square" & RS("ID") & """ type=""text""
maxlength=""50"" size=""7"" value=""" & RS("name") & """"
If Len(RS("name")) > 0 Then
Response.Write " readonly"
End If
Response.Write ">"
RS.MoveNext()
response.write("<td>")
next
response.write("</tr>")
rownumber=rownumber+1
loop

%>

</table>

</center>
</div>
<p align="center"><input type="submit" value="Submit"
name="B1"><input type="reset" value="Reset" name="B2"></p>
</form>
<p align="center">
<img height="94" alt="Patriots.com Home" src="brown800_home.jpg"
width="152" border="0">&nbsp;
VS.&nbsp;<img border="0" src="header-sp.gif">
<p align="center"><a href="http://www.patriots.com/SuperBowl/XXXVIII/"
target="_top"><img height="250" src="img93_000827.jpg" width="250"
border="0"></a></p>

</body>

</html>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,905
Latest member
Kristy_Poole

Latest Threads

Top