Jump to content

SharkBait

Members
  • Posts

    845
  • Joined

  • Last visited

    Never

About SharkBait

  • Birthday 12/27/1979

Contact Methods

  • Website URL
    http://www.tyleringram.com

Profile Information

  • Gender
    Male
  • Location
    Metro Vancouver, BC

SharkBait's Achievements

Advanced Member

Advanced Member (4/5)

0

Reputation

  1. I've used CAPTCHAs which seem to work for the most part though people (bots too) are getting smarter about getting past them. Though never display your email address in the form, or hidden. If you need to try and obscure it. You could use an image to display your email address but I know people who have programs that scan images for text etc pretty neat actually. If you use a server-side language such as PHP you can do some pretty cool validation and parsing of the information being sent, including checking to see if someone is trying to hack or force new email headers and since you can store you email address server-side in a variable they can't retrieve it and use it to spam the crap out of you. I've used forms with CAPTCHAs for multiple projects and the only spam they would receive would be form someone actually taking the time to fill it out which is really rare. I think one of the forms I have on a website has only received 2 spam emails since it has been in place for about 3 years.
  2. you could also use readonly="readonly" which would allow them to highlight if needed
  3. How do you know you are not getting an error? You're not echo'ing your $error variable anywhere that I can see in the code.
  4. Try using just \n \r\n is for windows based environments I believe where \n is for *nix environments.
  5. Wishing all the American's a happy and safe July 4th! From your neighbours in the chilly North!
  6. I've done a couple online shopping forms and the current one I am working with is with Moneris. They have you create the form and pass the creditcard information via a PHP class using cURL to their servers that gets processed etc. You would probably have to do the customer's contact information validation, but Moneris and other companies will probably do the validation of the card. There are also classes out there that check to see if the creditcard number is valid via a partiular log algorithim.
  7. Hi, Looking for advice when it comes to connections with MySQL. Currently I go the easy way and use mysql_connect() but I noticed that one of my windows apps has an issue with closing connections and I kept getting error about there were no connections available. Now I can look through the code and fix that, but is it better to use persistant connections? I have more web based apps that use MySQL and is it more efficient to to use mysql_pconnect() and leave the connection open? Currently all my scripts call mysql_connect() at the top and mysql_close() at the bottom. I have 3 databases that multiple sites and 3 winapps use to read/write data too. I could change the my.cnf file to allow more connections but that's more of a bandaid fix isnt it? My web queries are all under 0.5 secs when executed. The server is a dual xeon setup running on a gigabit backbone (all web apps and win aps are run within our network). So yea, just looking on advice. Yes I'll be fixing that winApp that doesn't seem to properly close its MySQL Connections Thanks
  8. Mine of course is from Finding Nemo! WHoo Haha!
  9. When I use a table to do this with images and I want to break at the end of 4 images I keep a counter and then check the Modulus to make sure there is no remainder and then break on that. [code] <?php // Images in an array or database whatever) $images = aray("pic1", "pic2", "pic3", "pic4", "pic5"); echo "<table border=\"1\">"; $i = 1; // Loop through the array for images foreach($images as $filename) {   // If i did this right, then if there is not a remainer then add the TR tags to drop to a new row.   if($i % 4 <> 0) echo "</tr><tr>\n";   // Display the image in a table cell   echo "<td><img sr=\"{$filename}\" /></td>";   // Increment counter   $i++; } ?> [/code] Now I might have it a bit wrong, but the idea is there :)
  10. Ah thats what I thought. But I've never seen it before until today. Thank you
  11. [code] <?php while (!feof($handle)) { # Checks the File pointer integer returned by fopen.               $buf = fgets($handle, 1096); # Returns a String from config, 1098 bytes long.               list($k,$v)=split('=', $buf); # Create a list of variables and assign string values by splittin$               $v = trim($v); #Remove Whitespace from $V             if ( $k ) {                       $config{$k} = "$v";             }     #      echo "#" .$k .$v ."<br>";     #      echo $config } ?> [/code] Well the part I have not seen before is the line [code=php:0] $config{$k} = "$v";[/code]  I've never seen curley braces used on a variable. What is it for? The rest of it I do understand. Thanks.
  12. What is the difference between: [code=php:0] str_replace("'", "\'", $mystring); [/code] and [code=php:0] mysql_real_escape_string($mystring); [/code] ??
  13. Are you using hotmail?  Hotmail Live?  If so I know I had to add the domain the mail was coming from into the trusted recipients list.
×
×
  • 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.