php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #12135 i faced probelms in simple if conditions
Submitted: 2001-07-13 04:55 UTC Modified: 2001-07-13 04:57 UTC
From: haseebi at hotmail dot com Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.0.6 OS: win 98
Private report: No CVE-ID: None
 [2001-07-13 04:55 UTC] haseebi at hotmail dot com
// code that produced the problem.
echo $tend //prints 60
echo $total_rec //prints 162
if ($total_rec<$tend)
$tend=$total_rec;

//when the above conditionis reached i have $total_rec=162
//and $tend=60 but this condition turns out to be true
//resulting in all the records being displayed on the 
// same page.the value of $total_rec is assigned to $tend

// fixed code (i am calling this fixing coz its working.)

if ($total_rec<=$tend-1)
echo $tend=$total_rec;

// this condtion works
God Help Me.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-07-13 04:57 UTC] derick@php.net
This is not a PHP bug, ask on the php-general@lists.php.net mailinglist for support questions.

Derick
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 10:01:28 2024 UTC