Jump to content

jsolomon

New Members
  • Posts

    4
  • Joined

  • Last visited

    Never

Posts posted by jsolomon

  1. OK OK, sweet start.  Thanks for the help so far. 

     

    As far as I see it, here are the first few problems I have to solve and some first guesses to solutions:

     

    1. Tracking the user's mouse movements around the page - Can I do this with Javascript?

    2. Create some way to accept text when the user clicks - No idea...Can't do this with regular forms, can I?

    3. Save the text (or img?) in a DB with positional info - PHP/MySQL, easy stuff.

    4. Load the new text entries - PHP/MySQL

    5. Position the entries - CSS? What's the best way to dynamically layout a page like this?

     

    I'll deal with the dragging/zooming thing later - it seems way too hard.  So, how can I deal with each of these problemos?  What languages, what tools, what strategies do you suggest?

     

    Thanks!

     

  2. Hey everyone,

     

    I am looking into this project as a learning experience and in the hope of building something interesting.  I know very little about web design, though have limited experience with HTML, CSS, JavaScript and PHP (very limited).

     

    My idea:  The webpage is a blank, white, infinite canvas.  Users can navigate through the canvas via click/drag and zooming.  Users can click anywhere on the canvas and type to add text.  A submit button will appear to confirm their entry.  Every user can see all entries.  Essentially this would be an interesting way to collect and display human thoughts/experiences.

     

    My understanding: As far as I can tell, I would need PHP/MySQL to capture and store the text entries.  I would need CSS to lay them out properly, and I would need a shit load of Javascript/AJAX to provide the camera controls.

     

    Questions:  This post is my first effort and identifying what exactly this would take.  How would you all structure a website like this?  What languages would I need to learn, what resources could I turn to, etc?

     

    Any advice is highly appreciated.

     

    Thanks,

    Jake

     

     

  3. I suppose "spam" was the wrong word to use.  I'm not really dealing with a forum...and its not really comments...and so far I'm not getting "spam."  I suppose I'll deal with that when I get there.  My issue is that each submission is supposed to be a secret (see http://www.jssolomon.com/secretstest.php).  Most are, some aren't.  Some are attacks, some are jibberish.  Those are the ones I want to be able to filter, and I want users to do it instead of me :).  Sooo.........Look over my code for me? :)

  4. Hello,

     

    I have a website where users submit anonymous messages, which are automatically posted publically on a rolling list. I am trying to implement a community flagging/voting system so users can eliminate spam messages themselves. I would like a flag icon to pop up next to each submission, and for entries to be deleted from the database (or at least not displayed) after 3 user flags.

     

    Here's what I have so far:

     

    First, as I loop through all of the past entries and echo them onto the page, I also echo a form for each entry:

    while(($row2=mysql_fetch_array($result2, MYSQL_ASSOC)) and ($row=mysql_fetch_array($result, MYSQL_ASSOC)))
    	{
    	echo "<p>", htmlspecialchars($row['secret']), "<hr></p>"; //This is the entry
    	echo "<div ID='flag'><form name='spam' method='post'><input type='submit' name='", $row2['time'], "' value='Flag' /></form></div>"; // This is the form for each entry
    	}

     

    Every form has the same name (spam), and each form has a single input whose name is the time value of when the entry was first submitted.  I just used this to create a unique form input for each entry.  This part works fine.  Then when someone clicks on the submit for a given entry, it is supposed to add 1 to the "spam" column of the given row.  Here is my code:

     

    if(isset($_POST[$row2['time']]))
            {
    $query3 = "SELECT spam FROM secret WHERE time = {$row2['time']}";
    $result3 = mysql_query($query3);  
    $new = $result3++;
    $update = "Update secret SET spam=$new";
    mysql_query($update);
    }

     

    This isn't working properly.  When I click one of the submit buttons, the spam column does not increment for any of the rows.  I think this is wrong: (isset($_POST[$row2['time']])).

     

    I'm really new to PHP and I know my coding is pretty sloppy, but I would appreciate any help.  Thanks in advance.

×
×
  • 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.