Jump to content

[SOLVED] PHP4 issues?


darkfreaks

Recommended Posts

ok so i am running on PHP4 and MYSQL 5

 

 

everything seems to work right when i changed the fields the guy who coded this told me it would work on my site if i changed all the appropriate fields so now i get "mysql_num_rows not a valid function" .

 

num_rows lines:

<?php

if(mysql_num_rows($get1)<1){echo"You can only give me items you own! (<a href=wizelscove.php>Back</a>)";}
if(mysql_num_rows($get2)<1){echo"You can only give me items you own! (<a href=wizelscove.php>Back</a>)";}
if(mysql_num_rows($find)<1){echo"<b>$get1[item_id]</b> and a <b>$get2[item_id]</b>? I've never heard of such a combination.
..Best not to dabble in what we're not experienced with, don't you agree? (<a href=wizelscove.php>Back</a>)";}?>

 

 

Link to comment
Share on other sites

somehow i might think it is a coe problem

 

you might be wrong. the error "mysql_num_rows not a valid function" says what it means: the function mysql_num_rows is not in your installation. but that makes me wonder why you don't get the same error using the mysql_query function. maybe try this to see if mysql_query is running okay.:

 

<?php
$query = mysql_query("SELECT id FROM useritems2") or die(mysql_error());
echo "query: $query"; // see what you get here.
$row = mysql_num_rows($query); //problem line
if ($row>1) {
?>

 

 

 

Link to comment
Share on other sites

mysql_num_rows comes with php mysql. it's all or nothing. you can't install individual functions. i have no idea why you'd get that error. if you can use mysql_query() but not mysql_num_rows(), something must be really hosed in your php installation.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.