Re: Re: [PHP] need an idea, please help
| From: | Matthew Mundy | Date: | Fri, 20 Oct 2000 17:38:32 +0000 |
| Subject: | Re: Re: [PHP] need an idea, please help | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-21443@lists.php.net to get a copy of this message | ||
Excellent. Thanks to all who responded. Man I love community support :)
Have a great day :)
---(A very happy) Matt
On Fri, 20 Oct 2000, Chris Carbaugh wrote:
>
> For 'real-time' interaction, you are going to have to use javascript
> IMHO.
>
> On several projects I have used a hidden <iframe> that loads a page
> with a meta refresh tage in it. This page is a simple script that
> querries a database, reads a file, or does what ever, and then
> transfers that info to javascript variables in a parent page, and then
> calls a javascript function to update the screen. Mind you most of
> these projects are intranet based, so I have a controlled browser
> enviroment: IE5 on Windows.
>
> Now to avoid using javascript, you could have the meta refresh tag in
> the main page, but that induces a terrible flicker even if your doing
> as little as echo-ing out a single charactor. Not to mention when you
> get into Netscape (espessially on linux) that doesn't seem to properly
> cache images.
>
> I really don't see what the big deal about javascript is anyway. If
> you want a browser based chess game, turn on javascript! Javascript
> allows me to right full blown applications, many of which are faster
> then if they had been written in C++ (much faster development anyhow).
>
> Also you can refresh a page with javascript by using
> frameID.location.replace($url) in IE, netscape should be similar.
>
> Check out faqts.com for some good reading on javascript (and PHP).
>
> Chris
>
> On Fri, 20 Oct 2000, Matthew Mundy wrote:
> > Date: Fri, 20 Oct 2000 13:11:40 -0400
> > To: "Michael J. Seely" <mseely@cimworld.com>
> > From: Matthew Mundy <mmundy1@gl.umbc.edu>
> > Subject: Re: [PHP] need an idea, please help
> >
> > Neat idea, except if the players use something besides a mail queue
> > (pop3) then they would have to know when to check their mail for the
> > new
> > mail and we are back where we started. But that would work in some
> > situations. Thanks for the idea.
> > ---Matt
> >
> > On Fri, 20 Oct 2000, Michael J. Seely wrote:
> >
> > > HI Matt
> > > I've started to do this on a few occasions but have never had
> > > the time to finish. The approach I was going to use is simple.
> > > Use the Mail function to send the next person an e-mail with
> > > a link to a web page. This is a php page and takes 64 field/value
> > > arguments. i.e.,
> > >
> > > http://theserver.com/thepage.php3?a1=br&a2=bb&a3=bk and so
> > > on.
> > > When the person clicks on the link, the page builds the board
> > > for them and waits for them to hit a <FORM> send button that has
> > > their move info.
> > > Using a naming convention for images, you need to make a
> > > black and white image for each piece, i.e., black king=bk, white
> > > pawn=wp, ... . Use a table with BGCOLOR set for each <TD> This will
> >
> > > make the checkerboard pattern for the board. You could use a fill
> > > image, i.e., <TD BACKGROUND="wood.jpg">to make the board look like
> > > wood, marble,...
> > >
> > > Part of the process could write a text file that keeps a log of all
> >
> > > moves. If you don't want to pass the board layout in the url, you
> > can
> > > write the same info to a tab-delimited file that is replaced each
> > > time. Use the EXPLODE function to parse out a1,a2,a3,a4,... values.
> > > You could add a replay button if you want to get fancy.
> > > I would suggest building the board html and images first.
> > > After you get the "look" that you want then make the php to build
> > it.
> > >
> > > Good Luck - Mike
> > >
> > > >I am trying to writing a php online chess game as a way to learn
> > PHP(hey,
> > > >might as well enjoy the testing process :) ). Does anyone know
> > how to get
> > > >the server to send a refresh command to 1 client after the other
> > has made
> > > >a move. my only other option that I can see really is to have a
> > java
> > > >chat-type applet that when 1 player moves, sends a message to the
> > other
> > > >client to hit the refresh button. Any suggestions would be
> > appreciated.
> > > >Thanks in advance.
> > > >---Matt
> > > >PS. Sorry if this rather an obvious thing to ask. I have much to
> > learn
> > > >but I am trying.
> > > >
> > > >
> > > >--
> > > >PHP General Mailing List (http://www.php.net/)
> > > >To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > > >For additional commands, e-mail: php-general-help@lists.php.net
> > > >To contact the list administrators, e-mail:
> > php-list-admin@lists.php.net
> > >
> > > --
> > >
> > >
> >
> > >>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>'>
> > > Michael Seely mseely@cimworld.com 408-777-9949
> > >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> > For additional commands, e-mail: php-general-help@lists.php.net
> > To contact the list administrators, e-mail:
> > php-list-admin@lists.php.net
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>