deepson2 Posted September 8, 2009 Share Posted September 8, 2009 Hello, Can we do that face book like notification with php. I mean for website, once user logs in he/she can probably get the toolbar which will give him/her small recap kind of thing that. he/she is got new friend request, or got new comment. I have searched a lot. i thing face book have done that with API or something else?? Can anyone have worked on something like this? or any suggestion? :confused: Thanks in advance. Quote Link to comment Share on other sites More sharing options...
Simon Mayer Posted September 8, 2009 Share Posted September 8, 2009 I'm sure you can do what you need to with PHP, but could you be more specific? When the user logs in, what exactly is it looking for? i.e. what data does it need to check against? The more specific you are, the more help we can offer. You would do something like this pseudo-code: <? if($logged_in == true) { $notification_bar = "Whatever you need to appear here"; } ?> <html> <body> <? echo $notification_bar; ?> Your normal page contents here </body> </html> Quote Link to comment Share on other sites More sharing options...
ignace Posted September 8, 2009 Share Posted September 8, 2009 This is easy enough to create. I can think of a few ways, here's one: CREATE TABLE comment_notification ( id INTEGER NOT NULL AUTO_INCREMENT, user_id INTEGER NOT NULL, comment TEXT, KEY fk_user_id (user_id), PRIMARY KEY (id) ); CREATE TABLE friend_notification ( id INTEGER NOT NULL AUTO_INCREMENT, user_id INTEGER NOT NULL, accept_link VARCHAR(255), deny_link VARCHAR(255), KEY fk_user_id (user_id), PRIMARY KEY (id) ); This is just one but there are other ways you can do this but this depends on what you want to display and your program flow. Quote Link to comment Share on other sites More sharing options...
deepson2 Posted September 8, 2009 Author Share Posted September 8, 2009 Thanks for the reply to both of you. I was thinking something similar. but thing is i just wanted to see some site which has this kind of facilities. and secondly how can i get that toolbar? i don't want to use iframe here. Do you have any live example of this kinda of stuff? Quote Link to comment Share on other sites More sharing options...
ignace Posted September 8, 2009 Share Posted September 8, 2009 Do you have any live example of this kinda of stuff? Try either ExtJS or YUI http://www.extjs.com/ http://developer.yahoo.com/yui/ Quote Link to comment Share on other sites More sharing options...
deepson2 Posted September 8, 2009 Author Share Posted September 8, 2009 I don't think i will use both the interfaces. using fixed toolbar i can get the toolbar. and on that i can fetch whatever data(total comment, new shout) i would like to fetch( i hope this is what i am thinking right now..let see ) What would be your suggestion? Quote Link to comment Share on other sites More sharing options...
capabmx Posted September 8, 2009 Share Posted September 8, 2009 Would something like this be easily integratable into drupal and smf? Quote Link to comment Share on other sites More sharing options...
ignace Posted September 8, 2009 Share Posted September 8, 2009 I don't think i will use both the interfaces. using fixed toolbar i can get the toolbar. and on that i can fetch whatever data(total comment, new shout) i would like to fetch( i hope this is what i am thinking right now..let see ) What would be your suggestion? Not sure I entirely understand what you are asking but maybe you want to a look at ExtJS then it allows you put any kind of data onto the toolbar. Would something like this be easily integratable into drupal and smf? Yes. Quote Link to comment Share on other sites More sharing options...
deepson2 Posted September 9, 2009 Author Share Posted September 9, 2009 Not sure I entirely understand what you are asking but maybe you want to a look at ExtJS then it allows you put any kind of data onto the toolbar. I just want to look my toolbar like facebook has. so can anyone have live example of something like this? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.