Jump to content

prodigy2k7

New Members
  • Posts

    9
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

prodigy2k7's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Actually, for kicks i modified my php.ini to change the max, still didnt work... I dont even know what that does, does that go in or outside of my while loop?
  2. Bump! I tried adding into the code after imagejpg imagedestroy($tmp_img); imagedestroy($img); It seems this would be my problem, yet it still stops! I dont know what to do. Once again! $10 through paypal to anyone to helps me and fixes it.
  3. Really? I never have problems with this. I just tried it to play around, mine works fine :S test.php <? $var = "hello there"; echo $var; ?> ^works fine I also used single quotes...still worked fine Edit: Oooh, people r responding, kewl, ill shutup now cuz im a noob
  4. This is what I like to do... <? $page = $_GET['page']; ?> <? if ($page == "") { include "home.php"; } else { if (file_exists($page . ".php")) { include $page . ".php"; } else { echo "<center>The page <b>$page</b> does not exist.<br>Check back soon!</center>"; } } ?> Basically a URL with http://domain.com/index.php?page=modules "modules.php" will be included if it exists. If not, it echos a does not exist... I like it cuz its simple...
  5. I am a novice but try not using $_GET['y'] all the time... Set a variable at the top like $get_y = $_GET['y']; then use $get_y in ur scripts. See if that helps, if not sorry Edit: I mean immedieatly when the script starts.... IE: <?php $vary = $_GET['x']; if (isset($vary)) {
  6. well how I like to code is have whichever way will have the MAIN stuff at the top and the error trapping below. IE: (Only wanting prodigy2k7 to visit) if ($name == prodigy2k7) { do this; also this; and this; and this; more of this; and this; } else { echo "You are not allowed." } OR (Wanting anyone EXCEPT prodigy2k7 to visit) if ($name != prodigy2k7) { do this; also this; and this; and this; more of this; and this; } else { echo "You are not allowed." } See what I mean? It really depends on what your doing. I like to have most of the code at the top, so therefore I do whatever is necesarry at the top using == or != so it really depends on the person and what your doing. No there is no difference. It is a language that you are coding for yourself. Look at Shakespeare, he writes how he wants to. You can code how you want to, how you best understand it. Enjoy
  7. Bump Edit: I will give $10 via paypal for whoever to fix this problem. I need it fixed fast! No responses yet!
  8. Hello, I am a novice PHP scripter. I mostly create small things or adjust php scripts i find online slightly and use them. This time I am having a problem. This script takes images in a directory, makes thumbnails of the images 1 by 1 in it and puts it in "thumbs" directory. It works fine, but if I have a lot of images, once it gets to about 30 seconds in... it just stops, with no errors, the browser says "Done" (firefox). set_time_limit(0); function createThumbs( $pathToImages, $pathToThumbs, $thumbWidth ) { $dir = opendir( $pathToImages ); while (false !== ($fname = readdir( $dir ))) { $info = pathinfo($pathToImages . $fname); if ( strtolower($info['extension']) == 'jpg' ) { echo "Creating thumbnail for {$fname} <br>"; $img = imagecreatefromjpeg( "{$pathToImages}{$fname}" ); $width = imagesx( $img ); $height = imagesy( $img ); $new_width = $thumbWidth; $new_height = floor( $height * ( $thumbWidth / $width ) ); $tmp_img = imagecreatetruecolor( $new_width, $new_height ); imagecopyresized( $tmp_img, $img, 0, 0, 0, 0, $new_width, $new_height, $width, $height ); imagejpeg( $tmp_img, "{$pathToThumbs}{$fname}" ); } } echo "done1"; closedir( $dir ); echo "done2"; } I tried for fun the two "echo"s at the end, it never reaches that. I also tried "set_time_limit(0);" at the top, I dont know if I used that correctly, but ya.. Anyone have any ideas? Thanks, Kenny
  9. before I get into any details (I want my code hidden as much as possible as it deals with databases) I am trying to create a page where you can recover your password. i am basically getting trash on the output... I cant copy n paste so ill take a ss and brush out the secret parts... ;\ lol... [img src=\"http://img131.imageshack.us/img131/2765/wtf6fm.png\" border=\"0\" alt=\"IPB Image\" /]
×
×
  • 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.