Jump to content

virruss

New Members
  • Posts

    6
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

virruss's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Thanks, man! I think this is a great place for me to start designing the structure. I didn't know that using JOIN is more efficient. I've managed to do the job for this simple example. But is it ok to search another table for a photo, separately, for each user (this means about 20 more queries per page), or can I do that in the same query too? I'm not sure how complex can a single query get. Do you have an example so I can study it instead of being abstract? Thanks a lot.
  2. Hi guys, I'm developing a website which allows people to connect and follow each other's activity (like Twitter, for example). To simplify everything, let's say I only have 2 tables: 1. Followers id | follower_id | id_to_follow ------------------------------------ 2. Activity id | member_id | message | time ----------------------------------------- Let's say John is following Jane and Bob. I want to create a "news" page and display the last 20 messages from Bob and Jane, chronologically. For small numbers, I'd do something like this: Select everything from the Activity table, check for every entry if the member is a friend of John's (in the Followers table) and, if so, display the message, ORDER BY `id` DESC. But, this is very inefficient, I guess, for larger numbers (I can't even think about how many queries would take to do this on a site like Twitter...). Any ideas of how to do the same thing more efficiently? Thank you.
  3. Hi, I'm trying to develop a little application similar to copyscape (I guess). I need to automatically check if an article is original or not... in order to avoid publishing it (almost in real time... at publishing time), after pressing the "Publish" button... I need to do this because I allow people to write articles on my website. My idea is to do something like this: when they press the publish button, the script performs a check (like copyscape.com) and, if any results are found, it stops the article from going online. If you know some Copyscape APIs doing this, please let me know (just to save some time and work). I'm trying to do this using Google API... but I'm not sure how to perform the searches... the easiest way would be to perform a search after the whole article, in quotes... but many publishers won't publish the exact same article... and Copyscape does a pretty good job determining what are the stolen parts of an article... Any idea of how does it work? Thank you in advance.
  4. Sorry for all the questions... But, how does the code look like with more than one custom POST variable? I'm very unfamiliar with this stuff... Do I have to add another $post_data? Like... function sendPost($host, $location, $referer, $post_data1, $post_data2,) { ... $done = sendPost("www.benedikt.vamos-inc.at","/test/post.php", "http://benedikt.vamos-inc.at/test/index.php", $post_data1, $post_data2); //Host, Path, Referer, Post-Data Thank you again. P.S.: This was the last question... I promise
  5. Thank you very much! 3 more questions: 1.Do I need to install something in order to use the second method? 2.Do I need to modify anything besides $done = sendPost("www.benedikt.vamos-inc.at","/test/post.php", "http://benedikt.vamos-inc.at/test/index.php", $post_data); //Host, Path, Referer, Post-Data at the end? 3. Can I use more variables? Thank you.
  6. Ok... Basically, what I need is to submit a form twice, to different locations with a single click. Why I need that? I'm running an affiliate program and I need to collect the name and email address of my visitors before I actually send that information to the merchant. I can ask them to confirm their information (and to get the second sumbit manually...) but this will obviously reduce the conversions. I cannot change the variables into GET variables because they won't work on merchant's page anymore. Is there a way to send POST variables after I store them into my database without having to resubmit the form? Thank you.
×
×
  • 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.