conan318 Posted May 19, 2011 Share Posted May 19, 2011 hi i am about to start building a small search where users type in what they are searching for but i am wanting to also find similar things to what they have typed in. $data = mysql_query("SELECT * FROM users WHERE users.bizname='%$bizname%' "); would i use something like that.. i haven't tried yet. thought id ask first Quote Link to comment https://forums.phpfreaks.com/topic/236842-wildcards-like/ Share on other sites More sharing options...
anupamsaha Posted May 19, 2011 Share Posted May 19, 2011 Try $data = mysql_query("SELECT * FROM users WHERE users.bizname LIKE '%$bizname%' "); Quote Link to comment https://forums.phpfreaks.com/topic/236842-wildcards-like/#findComment-1217439 Share on other sites More sharing options...
Adam Posted May 19, 2011 Share Posted May 19, 2011 i haven't tried yet. thought id ask first You should always at least experiment and try things for yourself before requesting help. It's part of the learning process... Quote Link to comment https://forums.phpfreaks.com/topic/236842-wildcards-like/#findComment-1217456 Share on other sites More sharing options...
conan318 Posted May 19, 2011 Author Share Posted May 19, 2011 thanks.. i know i should try first i wrote that line down but i knew it was missing something Quote Link to comment https://forums.phpfreaks.com/topic/236842-wildcards-like/#findComment-1217473 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.