You know Digg has changed its style and layout and now I think it looks awesome. This time on 99Points, I create Digg Style follow/unfollow application. Which I tried to create same as original Digg look. Many users like my facebook style tutorials So this is a continues series of Digg style tutorials. I hope You will like it. I have used user IP to check followed or un-followed. But you can do this in your required way. Please share this if you like and don’t forget to subscribe by email.
Note: No spams and newsletters will be send to subscribers. Thanks !
Database Structure
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
CREATE TABLE IF NOT EXISTS `digg_follow` ( `id` int(11) NOT NULL AUTO_INCREMENT, `fullname` varchar(120) NOT NULL, `username` varchar(80) NOT NULL, `image` varchar(100) NOT NULL, `bio` text NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=7 ; -- -- Dumping data for table `digg_follow` -- INSERT INTO `digg_follow` (`id`, `fullname`, `username`, `image`, `bio`) VALUES (1, 'Zeeshan Rasool', '99Points', 'zee', '[ www.99Points.info ] \r\nWeb Developer, Blogger, Freelancer and Technology Lover.\r\nDIGG MY STORIES AND I WILL DIGG YOURS'), (2, 'Designr Fix', 'designrfix', 'designrfix', 'Daily Inspiration and useful online Resources for Web Designers and Graphic Artists'), (3, 'Smashing Magazine ', 'smashingmag', 'smash', 'Smashing Magazine (www.smashingmagazine.com) is an online magazine dedicated to designers and developers. Curated by editor-in-chief Vitaly Friedman.\r\n'), (4, 'Designs Magazine (Designs Mag) ', 'designsmag', 'designmag', 'Digg my submitted stories and i will digg your stories and also Share stuff with me on IM.Drop links for diggs, reddit, twitter, stumbleupon, dZone etc !!\r\n'), (5, 'Speckyboy Design Magazine ', 'speckyboy', 'specky', 'Speckyboy Design Magazine offers insightful tutorials, time-saving techniques, fresh and useful resources and inspirational art, covering web design and development, graphic design, advertising, mobile applications and even, the occasional Lego post.\r\n'), (6, '10Steps.SG', 'johnsonkoh', '10step', 'Blog focusing mainly on Photoshop Tutorials. Apart from passing on some useful tricks and techniques, we will be providing interesting design news and great freebies.\r\n'); |
1 2 3 4 5 |
CREATE TABLE IF NOT EXISTS `digg_follower_ip` ( `userip` varchar(200) NOT NULL, `digg_id` int(11) NOT NULL, PRIMARY KEY (`userip`) ) |
JQuery Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
$(document).ready(function() { $('.buttons > a').livequery("click",function(e){ var parent = $(this).parent(); var getID = parent.attr('id').replace('button_',''); $.post("follow.php?id="+getID, { }, function(response){ $('#button_'+getID).html($(response).fadeIn('slow')); }); }); }); |
Download all the files and use this stylish tutorial. Thanks !
hhhhhhhhhhh