Jump to content

vikac

New Members
  • Posts

    2
  • Joined

  • Last visited

vikac's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. I knew that I would embarrass my knowledge. OK I will try to learn PDO. Jacques1, data in my database are ok (đ,č,ć) Thank you very much for reply
  2. Hello, First of all sorry for bad english :-) I have some data in mysql database. Have also search box which works fine except for "special croatian signs". We have š,ž,č,ć,đ. So, š and ž works also fine but ć, č đ doesn't work. I search a little bit and change unicode to UTF8, and also add three line in conn file: mysql_query("SET NAMES utf8"); mysql_query("SET CHARACTER SET utf8"); mysql_query("SET COLLATION_CONNECTION='utf8_unicode_ci'"); But still have nothing :-( When I enter đ instead đ, search work fine. Also when i enter sql query in mysql, works fine. But thrue web search failed. This is search code: <?php if (!empty($_REQUEST['term'])) { $term = mysql_real_escape_string($_REQUEST['term']); $sql = "SELECT * FROM table WHERE name LIKE '%".$term."%' OR proiz LIKE '%".$term."%'"; $r_query = mysql_query($sql); while ($row = mysql_fetch_array($r_query)){ echo '<a href="2.php?id='.$row['id'].'">'.$row['name'].'</a>'; echo '<br /> Tel: '.$row['tel']; echo '<br /> Proiz: '.$row['proiz']; echo '<br /><br /><br /><br /> '; } } ?> Is it possible to check and replace search term if user enter đ to replace it to đ and do the search? Again appologize for bad english and lack of knowledge in php Thanks in advance
×
×
  • 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.