![](https://forums.phpfreaks.com/uploads/set_resources_1/84c1e40ea0e759e3f1505eb1788ddf3c_pattern.png)
harristweed
-
Posts
346 -
Joined
-
Last visited
-
Days Won
1
Posts posted by harristweed
-
-
$query2 = "SELECT * FROM performancecriteria WHERE project_id = $project AND year = 2010 AND ( type = 1 OR type + 2 )";
-
uhhmm
This displays the correct values:
<?php $temp1=9; $temp2=4; //$temp1 = $nonRBProducts[$counteri][3]; $temp1 * 1; //$temp2 = $RBProducts[$counterr][3]; $temp2 * 1; $temp3 = $temp1 + $temp2; echo"temp1 = $temp1<br />temp2 = $temp2<br />temp3 = $temp3<br />"; ?>
Are you sure the variables $nonRBProducts[$counteri][3]; and $RBProducts[$counterr][3]; contain a value?
And what is the purpose of attempting to multiplying by 1? If that's what you want to do because $temp2 * 1; wont do anything!
-
Oh yes, doh!
try changing
$query = mysql_query("SELECT AVG(customer_service) FROM rating WHERE cust_id LIKE '$search'");
to
$query = mysql_query("SELECT AVG(customer_service) FROM rating WHERE cust_id = '$search' ");
-
what is line 27?
-
try
<?php// dont use short tags!!! //connect to mysql //change user and password to your mySQL name and password $link_id=mysql_connect("localhost","user","password"); //select which database you want to edit if (mysql_select_db("voogahco_microblog", $link_id)); $search="$id"; //get the mysql and store them in $result //change whatevertable to the mysql table you're using //change whatevercolumn to the column in the table you want to search // Make a MySQL Connection $query = mysql_query("SELECT AVG(customer_service) FROM rating WHERE cust_id LIKE '$search'"); $result = mysql_query($query) or die(mysql_error()); $row=mysql_fetch_row($result); $average=$row[0]; echo"average=$average"; ?>
-
try
$file_name = trim($_FILES['file']['name']);// original name of file
Then
echo $file_name;
-
Hi, No I don't know....
but I put the question to Google and got loads of stuff
http://www.adrogen.com/blog/email-not-sending-to-same-domain/
-
If The script works on your server but not on their server, it must be a server issue. (The script works on my apache 2 / php5). Open a support ticket!
-
ok, try
$columns = 0; $columnsCounter = 2; echo "<table border='1'> <tr>"; while ($row = mysql_fetch_array($products)) { echo "<td>" . $row['title']. "<br> </td>"; $columns++; if ($columns == $columnsCounter) { echo "</tr><tr>"; $columns == 0; } } echo "</tr></table>";
-
at first glance you have a brace too many
echo " </td>"; $columns++; if ($columns == $columnsCounter) { echo "</tr><tr>"; } $columns == 0; }
should be
echo " </td>"; $columns++; if ($columns == $columnsCounter) { echo "</tr><tr>"; $columns == 0; }
-
looks like you are adding it twice
$add_member = mysql_query($insert); if (!mysql_query($insert,$con))
you have two insert actions
-
I'm in agreement. Best to have a table that holds the options. Easier to operate than a code for different combinations.
-
<option value="08" <?PHP IF ($fuel1 == 08) echo "selected"; ?>>Aug</option>
08 is not a number, it's a string
Change to
<option value="08" <?PHP IF ($fuel1 == "08") echo "selected"; ?>>Aug</option>
and it will work
-
Put each photo with text in to a div and position with CSS
-
you are welcome!
-
You cant have html content before a header call. It will never work. Java Script will do the job for you.
-
Read the front page of this site!!
http://www.phpfreaks.com/tutorial/defining-a-php-function-only-once
-
desc is a reserved word in MYSQL you need to change the field name.
-
Lets see the new insert statement
-
Where are the options coming from? Is the list dynamically generated? Lets see some code.
-
NOT
$sql = "INSERT INTO $table SET category='$category', supp_pn='$supp_pn', desc='$desc', $help='help'"; mysql_query($sql)or die (mysql_error());
BUT
$sql="INSERT INTO $table (category, supp_pn, desc, help)VALUES('$category', '$supp_pn', '$desc', '$help' )";
-
You can't have a variable name that has a space in it!
you have the ID as a variable
Why not...
$query_Connectors= sprintf("SELECT * FROM Connectors WHERE Conn_ID = %s", mysql_real_escape_string($_GET['EquipID']));
-
this is the first error
$query_Connectors = "SELECT * FROM Connectors WHERE Conn_ID = %s", GetSQLValueString($colname_Standard Connector, "int"));
Space in variable name $colname_Standard Connector
and same error furter down.....
-
I think this will solve it for you...
$reference[$name][$this->_levelsNumbering[$i][$name]] =$reference[$name][$this->_levelsNumbering[$i][$name]].$data
notice no space before . and $data
I had a similar problem.....
php mysql verify two rows
in PHP Coding Help
Posted
Sorry, can't type....