Jump to content

MadTechie

Staff Alumni
  • Posts

    9,409
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by MadTechie

  1. Erm.. Well Done.. i think lol ???
  2. change the $filename = "http://tzfiles.com/users/$user/$img_id.jpg"; to $filename = "users/$user/$img_id.jpg"; for your one i needed the "http://tzfiles.com/" as its running from my server.
  3. flashchat http://www.tufat.com/script2.htm was the chat room heres the webcam addon http://www.virtualjam.net/addons/
  4. Remember Click Solved! Bottom Left of this page
  5. Sorting fields is based on the field type so if the field type is a int type (ie medium) the sort should be fine, if your field type is a string ie char then sorting number will look kinda messy ie
  6. oh boy.. you know i'll ask again were you supplied a SQL file ?
  7. hows this <?php $sentance1 = "the black cat crossed the street"; $s = explode(" ",$sentance1); shuffle($s); $new_sentance1 = implode(" ", $s); echo $sentance1; echo "<br />is now<br />"; echo $new_sentance1; ?>
  8. ok you have a problem in the db.php then, only works with jpg's but its only a test as well.. here's my link www.madtechiesupport.com/test3.php?user=ryan&image_id=img_23&percent=.75 heres the code <?php function getext() { return ".jpg"; } // The file session_start(); $img_id = $_GET['image_id']; $user = $_GET['user']; /*include"db.php"; $img = mysql_query("SELECT * FROM files where file_id='$img_id'")or die(mysql_error()); $imgs = mysql_fetch_array($img); $filename = "users/".$_SESSION['user']."/".$imgs['file_name'];*/ $filename = "http://tzfiles.com/users/$user/$img_id.jpg"; $percent = $_GET['percent']; switch($percent){ case ".25"; $percent = .25; break; case ".50"; $percent = .50; break; case ".75"; $percent = .75; break; case "1"; $percent = 1; break; default: $size = GetImageSize($filename); $width = $size[0]; if($width < 200){ $percent = 1; }else{ $percent = .5; } break; } // Content type if(getext($filename)=='.jpg'){ header('Content-type: image/jpeg'); }elseif(getext($filename)=='.gif'){ header('Content-type: image/gif'); }elseif(getext($filename)=='.png'){ header('Content-type: image/png'); } // Get new sizes list($width, $height) = getimagesize($filename); $newwidth = $width * $percent; $newheight = $height * $percent; // Load $thumb = imagecreatetruecolor($newwidth, $newheight); if(getext($filename)=='.jpg'){ $source = imagecreatefromjpeg($filename); }elseif(getext($filename)=='.gif'){ $source = imagecreatefromgif($filename); }elseif(getext($filename)=='.png'){ $source = imagecreatefrompng($filename); $alpha = imagealphablending($source, true); imagesavealpha($alpha, true); } // Resize imagecopyresized($thumb, $source, 0, 0, 0, 0, $newwidth, $newheight, $width, $height); // Output if(getext($filename)=='.jpg'){ imagejpeg($thumb); }elseif(getext($filename)=='.gif'){ imagegif($thumb); }elseif(getext($filename)=='.png'){ imagepng($thumb); } ?>
  9. use a form then my suggection works with a form using the "GET" request, i assumed you knew how to create a form !
  10. need to add the field "id" in codes
  11. <?php $get_information = mysql_query("SELECT * FROM information WHERE category = '1'") or die(mysql_error()); while($information = @mysql_fetch_assoc($get_information)) { $information_title = $information['title']; $information_content = substr($information['content'], 0, 500) ; echo "<b>" . $information_title . "</b><br />" . $information_content . "<hr>" ; } ?> will do the 500 characters
  12. Hummmmmm OK hate me but still please try this add this <?php function getext() { return ".jpg"; } ?> and test a jpg file from my server (linking to yours without the database of course) http://www.madtechiesupport.com/test3.php?user=ryan&image_id=img_23&percent=.75
  13. as a guess i would say line 73 $query = "SELECT * FROM user_ids WHERE username='$username'"; is this SQL statment valid ?
  14. ok well i think you have a GD problem, try <?php // Load $thumb = @imagecreatetruecolor($newwidth, $newheight) or die("Cannot Initialize new GD image stream") //<---changed ?> do a phpinfo(); and check it
  15. lol, love it thats one way i'll have a play see how deep my hole currently is (not sure how much needs updating) thanx kenrbnsn
  16. OK if you are changing the banner images then you need to edit this part 67 lines down <table cellspacing="0" width="95%"> <tr> <td height="100" colspan="5" align="left" valign="top"><div align="left"><img src="http://www.cometosandiego.com/eric/application/graphics/header-left.jpg" width="453" height="105"><img src="http://www.tookout.com/eric/application/graphics/header-img.jpg" width="453" height="105"></div></td> added a banner above (22.jpg) <table cellspacing="0" width="95%"> <tr> <td height="100" colspan="5" align="left" valign="top"><div align="left"><img src="22.jpg"<br> <img src="http://www.cometosandiego.com/eric/application/graphics/header-left.jpg" width="453" height="105"><img src="http://www.tookout.com/eric/application/graphics/header-img.jpg" width="453" height="105"></div></td></tr>
  17. changing the <?php $filename = "users/".$_SESSION['user']."/".$imgs['file_name']; ?> so is the full path to the image or even add a $filename below it with a full known path just to force it to a image.
  18. Correction kenrbnsn missed a " <?php $q = "INSERT INTO vbb_members(username,password,email,reg_date,mem_no,perm) values('$username', '$password', '$email', '$reg_date', '$mem_no', '$perm')"; $rs = mysql_query($q) or die ("Error in query:<pre>$q</pre><br>".mysql_error()); ?>
  19. i am not sure but you can do it in flash, i had a live chat created in flash and had a webcam mod added to it, will dig out the link if you want!
  20. thats just some basic HTML, got something for us to see ? (maybe one of your attempts)
  21. Whats $filename returning? <?php $filename = "users/".$_SESSION['user']."/".$imgs['file_name']; echo $filename; //<--Add die; //<--Add ?>
  22. Problem is only the my_foo[] would be returned.. when i'll be expecting my.foo[]
  23. urlencode doesn't solve the dot (.) problem, anyone have another idea ?
  24. store the offline var their then.. just add a field
  25. Quick Simple cheap idea just say your file is called index.php make this change <?php $ZIP= $_GET['ZIP']; //<--Add $result = mysql_query("SELECT * FROM usefuldata WHERE Zipcode=$ZIP",$link); //<--Change to ?> and load it up like this index.php?ZIP=33566
×
×
  • 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.