Jump to content

Php Chat Help


skroks609

Recommended Posts

Ok so i only started Php last week and i barely get the basics. But I really want to make a php chat the way i need it to be. Its going to be a chat for my new game, so i would like it to have avatars, admin features(stuff like banning, different avatars, special warnings) and i really need auto-delete. I know I am asking for alot, but if you can do it, please show me how.

Thankyou, Curtis989  ;D ;D ;D
Link to comment
Share on other sites

I think u need to know the basics before taking on a task like that

Also

PHP is a server side language, It send its information and posts back

To build a chat you have several options
Refresh the page every second
Use Flash and PHP
Use Javascript and PHP
Link to comment
Share on other sites

Here is what I use. A basic idea


[b]The real page.[/b]

[b]--index.html[/b]

1. Has a banner
2. Has two <iframes> the top one stretchin 100% w and 60% h the one below 100% w and 20% h
3. First iframes=dis.php
4. Second iframe=add.php


[b]Display page[/b]

[b]--dis.php[/b]

1. Refreshes every 5 secs
2. Reads a file chat.txt
3. Formats it and displayss the contents


[b]Add page[/b]

[b]--add.php[/b]

1. Has a name feild on top, which has the contents of the cookie name.
2. Has a message box.
3. Once submitted it sets a cookie name with the value of name.
4. writes to file chat.txt, the name and message.


This helps a lot for one can write while still being able to see whats going on.
If you had the same page having to refresh which has the display and add thing, it would not work good.
You can also add smily support which is not @ all difficult

[b]Note: This is an example of a PHP chat.[/b]
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.