Jump to content

cunoodle2

Members
  • Posts

    602
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

cunoodle2's Achievements

Member

Member (2/5)

0

Reputation

  1. What is the error message you are getting?
  2. My guess is that this code is OUTSIDE of the "<?php" bracket.. "$start = ($page-1)*$per_page; $sql = "SELECT productId, productCode, image, name, price, stock_level FROM inventory WHERE productCode LIKE '%".$searchp."%' OR name LIKE '%".$searchp."%' AND Seller_ID = '" . $_SESSION['SESS_SELL_ID'] . "' order by name limit $start,$per_page"; $rsd = mysql_query($sql);"
  3. I wish I could press a "LIKE button" for Pikachu2000 responses.
  4. Create another include file and call it something like "includes.php" or "pagename.php" On every page where you would want to define this just "require_once includes.php;" have a variable in there called $site_name and set it based upon the URL of the current page. On every page just have "echo $site_name" and that will display what you are looking for.
  5. I'm betting you have an error in your html form. Since IE is so loose on errors it may be slipping through. I bet that "$id" is not even set or being passed in. You need to do better error checking too after you get your results from the query. Do this.. $getdata = mysql_query("SELECT * FROM motorola WHERE id=$id", $db); if (!$getdata) echo "There are no results else { $row = mysql_fetch_array($getdata); $title = $row["title"]; $price_1 = $row["price_1"]; $price_2 = $row["price_2"]; $price_3 = $row["price_3"]; $imageaddr = $row["imageaddr"]; $description = $row["description"]; $keywords = $row["keywords"]; $time = $row["time"]; }
  6. You are missing some code. Please show us the actual code at line #3 which is where php says the issue is.. "MySQL server version for the right syntax to use near 's','home')'" I'm guessing that you may have an older version of mysql or something. However, I would need to see your code to even begin troubleshooting this.
  7. From what I know that is a FILE encryption as apposed to a string. According to the manual it states "openssl_pkcs7_encrypt() takes the contents of the file named infile and encrypts them using an RC2 40-bit cipher" Can you give me a little more info on what you are trying to do? Maybe there is a better/different way to do what you are looking for. Are you also looking to be able to decrypt said string/file or is this 1 way (I.E. password, etc..)?
  8. Show us some code and I'll take a look for you.
  9. step 1 is to share your code. Without it we are of zero help to you
  10. Line 17.. check there. Likely that is where your coding issue is.
  11. The issue appears to be on line 17 of your code. Try looking there and let me know what you come up with.
  12. If there was a LIKE button for your comment I'd press it.
  13. I edited my post while you were viewing the page. Please refresh to get the correct code.
  14. The issue is that your query will pull the value if ANY of the following items are true.... 1) status ='1' AND (title LIKE '%a%') 2) (titletext LIKE '%a%') 3) (tags LIKE '%a%') 4) (originaltitle LIKE '%a%') 5) (url LIKE '%a%') What exactly do you want your results to be? Since you are using "OR" if ANY of those items are true they will be pulled. What mikesta707 is saying is that if you move the parenthesis around you will be able to alter your out put. For example... SELECT * FROM videos WHERE status ='1' AND ((title LIKE '%a%') OR (titletext LIKE '%a%') OR (tags LIKE '%a%') OR (originaltitle LIKE '%a%') OR (url LIKE '%a%')) ORDER BY (videos.up-videos.down) DESC LIMIT 0, 5 Note that I added in another set of parenthesis. The query I wrote would be True only in 1 cases... 1) status ='1' AND ANY of the following are true.. (title LIKE '%a%') OR titletext LIKE '%a%') OR (tags LIKE '%a%') OR (originaltitle LIKE '%a%') OR (url LIKE '%a%')
  15. Well you need to first write a mysql query to gather all of the results. I honestly don't know why you need to store them in an array unless you need to some how modify the order but that too should be able to be done in the query. Then after you do the query loop through all results and echo them out to the screen. Try writing out this code and let me know what you come up with.
×
×
  • 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.