Jump to content

felipeebs

Members
  • Posts

    58
  • Joined

  • Last visited

    Never

About felipeebs

  • Birthday 06/18/1990

Contact Methods

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

Profile Information

  • Gender
    Male

felipeebs's Achievements

Member

Member (2/5)

0

Reputation

  1. I'm running Wordpress 3.1 multi site enabled and I need help to configure it to work this way: I have this 'site' in localhost/blogs, and I've created a localhost/blogs/felipeebs that works and has a lot [test-]posts in it. I NEED it to be accessable via localhost/blogs/FelipeEBS or localhost/blogs/Felipeebs or even localhost/blogs/FELIPEEBS, the same site. can it be done? how? thanks
  2. mod_rewrite is a apache server built in it catches the requested url and, with some regex, change it the user will still see http://www.example.com/news but php will be requested for http://www.example.com/index.php?page=news
  3. mod_rewrite in a .htaccess file may do it
  4. my code is something like this: $value = "10-2008"; mysql_query("insert into editions(edition) values ($value)"); But it's not inserting "10-2008" in the table, is inserting "-1998" the "editions" table is id int(9) auto_increment, edition varchar(7) not null why is this happening? how to avoid? thank's
  5. Hello. Can I use a function like htmlentities($str, ENT_NOQUOTES) inside an array_map function? How wouk]ld it look like? Thank's.
  6. I'll put offline for maintence and fix the bugs thank's, i'll reopen and post here!
  7. hey! this is my first big php 5 script, a forum script. is nothing like the bulletin boards you see arround the internet, but works. Now I want you to test it, to see what is missing (trust me, averything is missing) I need help to improve security and fix bugs first, so if you can help, thanks! u can access it at http://theeyeproject.com/forum/ my own domain, hosted on a free webhosting plan. T_T Best wishes: The Eye P.S.: If I left something in portuguese, I'm sorry! my english is very poor and I don't had much time to make it english. I'm working on it right now
  8. did you try just mysql_query("UPDATE accounts SET WeeklyCharge = '".$deTotal."' WHERE CustomerID='2'"); maybe without some stuff it goes on... the simple way of the same error continues, check your mysql table and send me the mysql_error returned
  9. what is the exact line that returns an error? (post it, please)
  10. try mysql_query("UPDATE accounts SET WeeklyCharge = '".$deTotal."' WHERE CustomerID='2'", $con) or die('Error: '.mysql_error()); if the error is the query, here goes some solution between " and ", any insert of variable must be declared closing ", adding a dot . putting the $variable, another dot. and reopen " i.e.: $name = "felipeebs"; "this is ".$name."!" returns: this is felipeebs
  11. I tried this code, but it don't work fine. if I try to transform an image from 1000x5000 or 5000x1000 (i.e.) ,it will not work to resize to the maximum 800x600 proportionally my code: function gravaImg($img, $folder, $max_x=800, $max_y=600, $quality=100) { list($width,$height) = getimagesize($img['tmp_name']); if ($width > $max_x or $height > $max_y) { if ($height > $width) { $tax = $width/$max_x; $x = $max_x; $y = $height/$tax; } elseif ($width > $height) { $tax = $height/$max_y; $x = $width/$tax; $y = $max_y; } // elseif ($width == $height) else { $tax = $width/$max_x; $x = $width/$tax; $tax = $height/$max_y; $y = $height/$tax; } } else { $x = $width; $y = $height; } $redim = imagecreatetruecolor($x,$y); if($img['type']=='image/png' or $img['type']=='image/x-png') { $original = @imagecreatefrompng($img['tmp_name']); } elseif($img['type']=='image/gif') { $original = @imagecreatefromgif($img['tmp_name']); } else{ $original = @imagecreatefromjpeg($img['tmp_name']); } chdir($folder); $nome = md5(time()).'.jpg'; imagecopyresized($redim, $original, 0, 0, 0, 0, $x, $y, $width, $height); imagejpeg($redim,$nome,$quality); imagedestroy($redim); } what's wrong??? thanks
  12. I'm sorry for reviving this topic, but I found the query simpler way with this $results = mysql_fetch_assoc(mysql_query("SELECT date_format(date, '%M %d %Y %H:%i') as date FROM table")); print_r($results); will return Array ( [date] => June 14 2008 14:08 ) conclusion: SQL code "SELECT date_format(column, format)" can receive the keyword "as var", so it do not returns $results[date_format(date, '%M %d %Y %H:%i')] = ... but returns $results[var] = ... I'm sorry again, but this may be usefull for someone else.
×
×
  • 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.