PDA

View Full Version : [RELEASE] AJAX-PHP-MYSQL Shoutbox.



Florx
29-11-2007, 05:21 PM
Hey there!

As promised I have released my Ajaxy shoutbox.

Demo: http://jake-hall.co.uk/ajax

Download: http://jake-hall.co.uk/phptutorials/clicks/click.php?id=3

If there are any security issues (i'm aware of one) let me know - i'm sure you will slate me for them but it's only a demo!

The SQL is included in the pack. You need to edit a2.php and put your MySQL details in at the top.

Instructions

To change the "refresh" rate of the shoutbox change this line:



//Display the message every 2000 milliseconds = 2 seconds :)
setInterval("getmsg()", 2000);


Seconds x 1000 = the number at the end.
(milliseconds)

__________

If you have any problems feel free to PM me or post below.

Have fun.

Thanks,
Jake.

rh4u
29-11-2007, 05:27 PM
Danke!

MrCraig
29-11-2007, 05:35 PM
Ooohh cool :P

Looks a bit like simons tho :)

And the bottom image thing on the text bubbles is up too far.

Nice for giving free tho :)

Invent
29-11-2007, 05:49 PM
You could've asked to use my images ):

Florx
29-11-2007, 05:49 PM
I sorry. Want me to take them off?

Invent
29-11-2007, 05:50 PM
Of course not :P I was only joking.

Florx
29-11-2007, 05:54 PM
YAY. Thanks :)

If anybody makes it look really good and doesn't mind me nicking it send me your links please :)

Have fun :)

Implosion
29-11-2007, 06:17 PM
Should add HTML.
Like [b] [i]

Florx
29-11-2007, 06:19 PM
Will do for V2 :)

Any other ideas?

Thanks,
Jake

Verrou
29-11-2007, 11:17 PM
Diff colour speech bubbles like typing /yellow Text would put your text in a yellow speech bubble etc. /red /green /#FFFFFF

Forge
30-11-2007, 10:11 PM
Ooo ill have a play with it and see what i can come up with! :)
+Rep!

Florx
30-11-2007, 11:35 PM
Thanks for the rep :) (even though you have 0 rep power)

+rep back :)

UPDATE TIME:

Added smileys, stopped more than 5 smileys in a shout anddd and planning a login / register feature for reserving usernames BUT also a guest feature.

V1.3 is online and may be unstable as im editing all the time.

V1.2 is also online and should be stable unless im editing the database.

EDIT:

In V1.3 I have merged both files a2.php (the post and get page) into index.php so it is easier to edit :)

Thanks,
Jake

Florx
01-12-2007, 03:10 AM
UPDATES:

Ive been working hard tonight cause I can't sleep PAH!
http://jake-hall.co.uk/ajax/v1.3-BETA/ (http://jake-hall.co.uk/ajax/v1.3-BETA/#)

Anyway here are V1.3's features:

Login, register, /prune, /lock, delete a shout + add a reason for that deletion.

Users that are not logged in will have (Guest) at the end of their name and users that are logged in have a green name so its easy to see who is real. Also, admins are blue with (ADMIN) on the end.

A few people said "Who is the real Jake" so that's why the admin bit has been added on.

In the permissions it goes: 1 - Normal user, 2 - Mod or vip whatever, 3 - ADMIN! So atm 2 is unused.

I won't release V1.3 yet because it has only been tested on Ubuntu + Firefox not IE (shivers). To be honest it should work in both.

Thanks for your interest,
Jake.

VistaBoy
01-12-2007, 03:38 AM
cool but when you login with the wrong user name or pass it just stays as Checking details... ??

Florx
01-12-2007, 03:40 AM
It doesn't because it returns the form and invalid password + username. Let me check :)

Edit: I just tried it and it says

Invalid username or password.
Username:

Password:

or Cancel (http://jake-hall.co.uk/ajax/v1.3-BETA/#)

Like it should!

VistaBoy
01-12-2007, 03:43 AM
do not know then maybe its tacking for ever as it justs says Checking details... and its been on that for about 3 mins now.

Florx
01-12-2007, 03:48 AM
What browser and OS?

Edit:

I found the error -
uncaught exception: [Exception... "Component returned failure code: 0xc1f30001 (NS_ERROR_NOT_INITIALIZED) [nsIXMLHttpRequest.send]" nsresult: "0xc1f30001 (NS_ERROR_NOT_INITIALIZED)" location: "JS frame :: javascript: eval(__firebugTemp__); :: anonymous :: line 1" data: no]

Dunno what it means :S

Beau
01-12-2007, 10:27 AM
Unstable is right... Crashed firefox when I tried loading it then.

d17c
01-12-2007, 12:02 PM
Add a timestamp thing :)
oh and good work so far

Florx
01-12-2007, 02:52 PM
The timestamp is in the database so il add it to the page :)

Thanks d17c.

And Beau it crashes mine sometimes. Im working on it :p

Want to hide these adverts? Register an account for free!