Jump to content
MakeWebGames

dwandswforlife

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by dwandswforlife

  1. Well I checked and re-checked, even followed the guide once again and did it from scratch; to no avail. Also I am still experience the BotBattle issue I posted on the first post.
  2. So I got my public and secret keys, entered all the forms both on my captcha.php page and form on the index where the registration page is, but yet the image does not load.
  3. http://lmgtfy.com/?q=reCaptcha I appreciate the assistance nonetheless.
  4. Okay, could you provide a link to the code and tutorial for reCaptcha?
  5. Just so you all know where I am at with the game development; I have successfully configured it to my host and I am able to log in and play, but that is only because I am the admin. Unfortunately, the first issue I am having is that when attempting to register, such as a new member/guest, the captcha image is not loading. Here is the captcha page code in case it helps;   <?php define('IN_EZRPG', true); require_once('init.php'); //$code_length = rand(5,6); $code_length = 4; $rand_start = mt_rand(0, 250); $font = 'static/fonts/Capture_it.ttf'; $fontSize = 30; $padding = 10; $l1 = strtoupper(createKey(1, 1)); $l2 = strtoupper(createKey(1, 1)); $l3 = strtoupper(createKey(1, 1)); $l4 = strtoupper(createKey(1, 1)); $verify_string = $l1 . ' ' . $l2 . ' ' . $l3 . ' ' . $l4; $real_string = $l1 . $l2 . $l3 . $l4; $verify_code = sha1(strtoupper($real_string) . SECRET_KEY); $_SESSION['verify_code'] = $verify_code; function makeRBGColor($color, $image) { $color = str_replace("#", "", $color); $red = hexdec(substr($color, 0, 2)); $green = hexdec(substr($color, 2, 2)); $blue = hexdec(substr($color, 4, 2)); $out = ImageColorAllocate($image, $red, $green, $blue); return $out; } $wordBox = imageftbbox($fontSize, 0, $font, $verify_string); $wordBoxWidth = $wordBox[2]; $wordBoxHeight = $wordBox[1] + abs($wordBox[7]); $containerWidth = $wordBoxWidth + ($padding * 2); $containerHeight = $wordBoxHeight + ($padding * 2); $textX = $padding; $textY = $containerHeight - $padding; $captchaImage = imagecreate($containerWidth, $containerHeight); $red = randColor(); $green = randColor(); $blue = randColor(); $backgroundColor = ImageColorAllocate($captchaImage, $red, $green, $blue); $rred = 255-$red; $rgreen = 255-$green; $rblue = 255-$blue; $textColor = ImageColorAllocate($captchaImage, $rred, $rgreen, $rblue); imagefttext($captchaImage, $fontSize, 0, $textX, $textY, $textColor, $font, $verify_string); $angle = mt_rand(-3, 3); $captchaImage = imagerotate($captchaImage, $angle, $backgroundColor); $line = ImageColorAllocate($captchaImage, $rred, $rgreen, $rblue); for($i = 0; $i < 10; $i++) { $xStart = mt_rand(0, $containerWidth); $yStart = mt_rand(0, $containerHeight); $xEnd = mt_rand(0, $containerWidth); $yEnd = mt_rand(0, $containerHeight); imageline($captchaImage, $xStart, $yStart, $xEnd, $yEnd, $line); } imagefilter($captchaImage, IMG_FILTER_CONTRAST, 1); //imagefilter($captchaImage, IMG_FILTER_BRIGHTNESS, 10); //imagefilter($captchaImage, IMG_FILTER_EDGEDETECT); imagefilter($captchaImage, IMG_FILTER_GAUSSIAN_BLUR); header('Content-Type:image/png'); ImagePNG($captchaImage); ?>   The second issue I am having is with the BotBattle module. I have placed it into the 'modules' directory. I've attempted to go to the http://www.yoursitehere.com/index.php?mod=BotBattle&act=install link to install the BotBattle module and it doesn't bring up anything; it only seems to bring me back to the index page. Of course I change the 'yoursitehere.com' part to my own address. The link to the code is here; http://ezrpg.uaktech.net/archives/showthread.php?tid=3
×
×
  • Create New...