Jump to content

exally

Members
  • Posts

    38
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

exally's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I believe there is a problem with you SQL query - The column names are enclosed with the character ' and really should be with the character `. Also while calling mysql_query within mysql_num_rows or mysql_fetch_assoc looks more efficient it makes it harder for Debugging. I suggest something to the following. $sql = "SELECT * FROM `users` WHERE `site_name` LIKE 'berland' AND `card_id` LIKE '290093C84E' LIMIT 0 , 30"; $res = mysql_query($sql) or die(mysql_error() . "<br/>" . $sql); if(mysql_num_rows($res) > 0) echo '1'; else echo '0'; That way you can also use the same result to iterate through the rows.
  2. "$xml->healings[0]->".$xmla."[0]->descrip[0]"; This might require that you use the function eval.
  3. echo utf8_decode($xml->healings[0]->$xmla[0]->descrip[0]); to echo utf8_decode($xml->healings[0]->xmla[0]->descrip[0]); Without more information about the object etc, what are you hoping to achieve?
  4. like everyone else said, nl2br --- if you have something that addslashes when going into the database you made need to do a str_replace("\\\\", "\\", $string);
  5. your Parameters for the If statements aren't being set? if you are receiving them over post or get declare them via $var = $_POST['var']; maybe??
  6. iversonm - i test the following code. If you leave out the {} brackets it will execute or not to the next ';' (semi-colon). <?php $p1 = ""; $p2 = 'on'; $k = 'on'; $pointsmin = 'ptmin'; $pointsmax = 'ptmax'; $xLow = 1; $xHigh = 3; $yLow = 0; $yHigh = 4; $x1 = 2; $x2 = 3; if ($p1=='on' AND $p2=='') $include = " AND points >= '$pointsmin'"; else if ($p1=='' AND $p2=='on') $include = " AND points <= '$pointsmax'"; else if ($p1=='on' AND $p2=='on') $include = " AND points BETWEEN '$pointsmin' AND '$pointsmax'"; else if ($p1=='' AND $p2=='') $include = ""; if ($k =='on') $betweenclause = "x BETWEEN $xLow AND $xHigh AND y BETWEEN $yLow AND $yHigh"; else if ($x=='on' AND $y=='') $betweenclause = "x BETWEEN $x1 AND $x2"; print $include . "<br/>"; print $betweenclause . "<br/>"; ?> and got the result of
  7. simplest way for you would be to run in through a function that converts from that format to the desired $time = str_replace(array(" ", ":"), array("-","-"), $col['date']); //format for explode $time = explode("-", $time); $time_stamp = mktime($time[3], $time[4], $time[5], $time[1], $time[2], $time[0]); //Convert to timestamp print date('d F Y', $time_stamp); There is probably a better way, but none that involves that sort of simplicity.
  8. Look at this, i can understand the want to speed up the code by losing the '{'. But in this case put that back in. The second if and else if statements need ( not { styled brackets.
  9. be wary, some servers with disable your access if you try to send 10000 at once
  10. Yes, look in /catalog/includes/configure.php and /catalog/admin/includes/configure.php - However, you change one you change them all in this case.
  11. I have heard of this recently. If you have an old version of FckEditor that could be a cause. There is also numerous other ways that do it to. More likely this vuneralbility was somethign that you did not do but a third party software. Any thoughts on that?
  12. Your answer may lie in a Java applet or a Adobe Air application.
  13. front. In form definition, multipart maybe?. There is little reason why Server side code should be effected by browser usage.
  14. The best editor i have found so far is definately Web Expressions 3 by Microsoft. Other than that mainly Dreamweaver or Visual Studio 2005 with the PHP.NET add on.
×
×
  • 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.