se1zure Posted January 21, 2007 Share Posted January 21, 2007 I am learning PHP, and I learn through programming, by solving problems. THe only downside to this, is that what I result with may be inefficient, and insecure.I use Digg.com alot, and was wandering, what would be the best method of making a "Digg this" style applicatoin, which will do the following (I know how to do most of this, but am not sure I am doing it efficiently, or the best way possible).-- I would liek to do this without the use of mysql, for now at least, as my knowledge of mysql is incredibly limited--I will create a form, witha submit button, to be attached to each story. There will be a $title variable which will be set to the name of the story. When the user clicks digg, it creates a txt file named the title of the story (unless it has already been made by the original digger), to keep track of it's diggs. It will cookie the user, and not allow them to digg it again. 9alothough, they can delete the cookie... oh well). I want then, to have the number of diggs displayed byt eh digg button. I realize to do updating inside the page, I would need to use ajax, correct?Anyways, Here is where I could also use help. I would liek to create a separate page, where any story with more than 10 diggs is displayed. i realize that with mysql, this would be fairly simple, but is there anyway for a php script to read all the txt files in a folder, then get he name of the txt file, and extract the title of the story? Quote Link to comment Share on other sites More sharing options...
Jessica Posted January 21, 2007 Share Posted January 21, 2007 This already exists, from digg.com. It's in their tools section. Quote Link to comment Share on other sites More sharing options...
Nameless12 Posted January 21, 2007 Share Posted January 21, 2007 Don't touch ajax until you are comfy using basic sql and php as it requires learning a new language (javascript) Quote Link to comment Share on other sites More sharing options...
Jessica Posted January 21, 2007 Share Posted January 21, 2007 Ah I misread, I thought you meant you wanted to add a digg this button to your content - for the actual digg.comDigg was created in PHP, so it's obviously very possible - but you'd also have to get into mysql or another database, and ajax. 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.