Dating And Meet-up Zone › Re: "Chat Central and Derailer's Paradise"...Welcome! by osarcho: 1:22am On Jul 12, 2015 |
HBD to my NL crush Spark4daz  WULLNP  |
Food › Re: See What A Lady Cooked For Her Man ! by osarcho: 1:11am On Jul 12, 2015 |
Lol...dis is really funny |
Crime › Re: Safety Tips - Dss by osarcho(op): 10:27am On Jun 30, 2015 |
vimi: iif those hot lines work then ii believe hell iis not real  Lol, they myt work...I havent tried them tho |
Crime › Safety Tips - Dss by osarcho(op): 8:45am On Jun 30, 2015*. Modified: 9:02am On Jun 30, 2015 |
|
Programming › Re: ASP.NET HELP!¡! Any Programmer Can Give Suggestion. by osarcho(op): 4:28pm On Jun 16, 2015 |
xtremrules: Assuming you are using Linq to Query your database and the Table name is Pages with a column called PageContents where the content of each page is saved and its Class representation is called Page, you will something like this: if The data in the textbox is saved in a variable called searchData;
string[] searchArray = searchData.Split(); //Returns a substring using the default space separator
//Assuming Pages is a List of pages data from Database
var result = Pages.Where(x => searchArray.All(y => x.PageContents.ToLower().Contains(y.ToLower()))).ToList();
//The Above variable returns is collections of Pages( List<Pages> ) that has exactly all search strings. you can manipulate the collection the way you wish. replace .FirstOrDefault() if you want just want a Page class result This was wha I came up with at first, dunno why it's not workin: foreach (eachWord PageData in Page) { string url = PageData.url; string word = PageData.word; foreach (string text in txtSearch.Text.Split()) { // if word is not in url set flag as false and stop loop if (!word.Contains(text)) break; searchQuery += 1; // (globally created integer)
}
if (searchQuery == txtSearch.Text.Split().Length) Response.Write(url + "<br />" ;
} } It still brings out result according to the position of the word in the text box even though I tried to cater for that in if (searchQuery == txtSearch.Text.Split().Length) |
Programming › Re: ASP.NET HELP!¡! Any Programmer Can Give Suggestion. by osarcho(op): 3:43pm On Jun 16, 2015 |
xtremrules: Assuming you are using Linq to Query your database and the Table name is Pages with a column called PageContents where the content of each page is saved and its Class representation is called Page, you will something like this: if The data in the textbox is saved in a variable called searchData;
string[] searchArray = searchData.Split(); //Returns a substring using the default space separator
//Assuming Pages is a List of pages data from Database
var result = Pages.Where(x => searchArray.All(y => x.PageContents.ToLower().Contains(y.ToLower()))).ToList();
//The Above variable returns is collections of Pages( List<Pages> ) that has exactly all search strings. you can manipulate the collection the way you wish. replace .FirstOrDefault() if you want just want a Page class result to my surprise, it only works for one word searches |
Programming › Re: ASP.NET HELP!¡! Any Programmer Can Give Suggestion. by osarcho(op): 6:02am On Jun 16, 2015 |
xtremrules: Assuming you are using Linq to Query your database and the Table name is Pages with a column called PageContents where the content of each page is saved and its Class representation is called Page, you will something like this: if The data in the textbox is saved in a variable called searchData;
string[] searchArray = searchData.Split(); //Returns a substring using the default space separator
//Assuming Pages is a List of pages data from Database
var result = Pages.Where(x => searchArray.All(y => x.PageContents.ToLower().Contains(y.ToLower()))).ToList();
//The Above variable returns is collections of Pages( List<Pages> ) that has exactly all search strings. you can manipulate the collection the way you wish. replace .FirstOrDefault() if you want just want a Page class result Tanx, dat should work...Ill try it |
Programming › Re: ASP.NET HELP!¡! Any Programmer Can Give Suggestion. by osarcho(op): 10:43am On Jun 15, 2015 |
blenyo11: Pass your URL list and search term to this function public List<string> Search(List<string> allUrls, string searchTerm) { var result = new List<string>(); var wordList = searchTerm.Split(' '); //loop through all the urls foreach (var url in allUrls) { //lets create a flag for tracking var addUrl = true; //loop through the word list foreach (var word in wordList) { //if this word is not in the url; don't add this url //so let's set our flag to false if(!url.Contains(word)) addUrl = false; } //if addUrl is true then all the words are in the url. so add the url to our result if(addUrl) result.Add(url); } return result; } Nice, it works, but it is being affected by the position of the word |
Programming › ASP.NET HELP!¡! Any Programmer Can Give Suggestion. by osarcho(op): 8:51am On Jun 15, 2015 |
Please I need your help concerning a program of mine, I have a database with a table in which a list of words on my site, and the page they appear in is, a page with a textbox, a button and a datalist. The purpose is to enter a group of words in the textbox, separated by a space, then each word is searched in a table in my database, and the page(s) where the words appear is returned, and saved into a List<className> I created for this, now my problem is how do I return only the page where all words in the textbox appears in order to populate the datalist.
cc: Raypawer, ilekky, satindersingh1, dmayor7, avosoft, basbone, xtremrules, gimakon, blenyo11, francis164 |
Politics › Re: Buhari: Why My Meetings With Jonathan Last Less Than 15 Minutes by osarcho: 11:30pm On May 24, 2015 |
OREMUSSANCTUS: Lol
Jonathan is a christian and not a terrorist You must have spawned from the generation of ORANGUTANS... |
Politics › Re: Buhari: Why My Meetings With Jonathan Last Less Than 15 Minutes by osarcho: 11:22pm On May 24, 2015 |
I love the way GMB answers interview questions, sometimes I doubt he is the one sef... SAI BABA...I think he'll be a better president, altho i dont expect miracles o. |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:09pm On May 24, 2015 |
|
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:07pm On May 24, 2015 |
southniyikaye: u need one pack of artesunate cost u are suffering from chronic malaria fever lmfao...I so luv nairaland |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 7:19pm On May 24, 2015 |
iykedare: You hate six packs? No,you hate hungry packs. Wait until you see my six packs. yeaaa...now, u r my def of d sexy I tot gals usually talk abt...altho, I love my big tummy o |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 6:19pm On May 24, 2015 |
armadeo: Comments like this is why I love nairaland. Acidic. You guys make me laugh.
But go easy on the young fella same reason I posted the pics here, so I could be proved right. |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 2:44pm On May 24, 2015 |
vjsmiles and KingTom, God will provide you with brains o...e b like say IGBO scarcity dey, I understand your plights |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 1:13pm On May 24, 2015 |
 Whizzcute: dem don day create awareness for MR NAIRALAND contest .  |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:16am On May 24, 2015 |
vjsmiles: see this fvvking moronic fa9... Wait for me at the lagos sea port i will send one of my boys to smuggle you in a torn ghana must go to come and sell chinese periwinkle(nfi)for me... In china.. Btw av you passed your village highway before? That pic u took in an eatery must be your village chief son or daughters wedding where they loaded all of you in a truck to go and play ogene
fvvking fvck outa my mentions frustrated lizard Once again.. ^goat^ no offe? Nse pls geh away from ma thread...dis isnt some curse ground for you |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:12am On May 24, 2015 |
|
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:09am On May 24, 2015 |
taofeeq137: ahnahn bro...must u now disgrace me on NL? yeah...sorry, had to...got ut NL id from Hassan(dat ya friend) |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 10:34am On May 24, 2015 |
shokky24: For ya mind for him mind...got his nairaland id as Taofeeq137 |
Celebrities › Re: Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 11:13pm On May 22, 2015 |
more
|
Celebrities › Is This Guy The Sexiest Nairalander, Or A Day Dreamer? by osarcho(op): 10:42pm On May 22, 2015*. Modified: 10:31am On May 24, 2015 |
I was at a contest in unilag...Mr....can't remember the name, and there was this guy beside me ranting about how he should have gone for the contest, but couldn't because he didnt have the moni for the form...na im I look side o...and saw 1 skinny boi like dat, so I was like...see crayfish wanting to compete wit dese muscular guys o...So I asked him to send me his best pics, dat I was goin to fix him into a modelling contest I knew of, and dat I would pay the bills...the guy sent me d pics, na him I show sum gals 4 my department o, and most of dem confirmed he was truely sexy...which I dont, pls guys drop your comments, is he truly sexy? or a day dreamer according to what I fink he is. |
Culture › Re: Amazing Pictures From Nigeria's Past by osarcho: 1:26am On May 15, 2015 |
ROSSIKE: What is so special about these pics? Nigeria was very underdeveloped when all those pics were taken. Most people were malnourished, lived in neglected villages with no electricity or running water. Cars were only for the super rich. Roads were virtually non existent. Illiteracy was the order of the day. Op please stop romanticising misery and deprivation. LIFE IS MUCH BETTER TODAY FOR NIGERIANS. And who are you sir  |
Phones › Re: Help! I Want To Root My Lg L90 Dual (d410) by osarcho: 9:36am On May 13, 2015*. Modified: 1:53pm On May 24, 2015 |
.. |
Education › Re: Have U Cried Because Of This Before? by osarcho: 10:46pm On May 06, 2015 |
RickRichards: Velvet beans. I've heard about it. You can make coffee with it. and your throat will prefer boiling water to the coffee after drinking it, its soo sweet, its good for entertaining visitors too |
|
Politics › Re: Throwback Pic Of Buhari When He Was Decorated As A Major General. by osarcho: 3:31pm On May 06, 2015 |
OREMUSSANCTUS: Say no to "change" We nid transformation I pray and hope we won't regret voting out transformation bro pls who the fu...ck are you, I'm starting to suspect you are Jonathan...abi wich levels now, sey na u dem commot for seat wey u just dey take am personal like say na ya post dem steal from you...even the victim don accept defeat... |
Nairaland General › Re: FUEL SCARCITY: 3 Types Of People That Can Get Fuel Easily At The Fuel Stations by osarcho: 3:16pm On May 06, 2015 |
olass2sms: Hello Mr/Mrs
We are here in purpose of improvement our community also to introduce our service to you.
We are company that provide Bulk SMS service to improve your sale, organization we are best in Nigeria and globally wen we are talking about server is the best to chose reliable server that we Deliver your sms in second to your organization, Client and member.
Our server is base on United State which you we not have a issue on our site.
And we offer avoidable price to our user and our Re-seller our website is www.olass2sms.com/
We make sure we will serve you better as we do for our Client visit us today to know what we are talking about we expect your visit to serve you better.
Regard OLASS2SMS. 08059908320 can the sms be integrated with an ASP.NET website  |
Nairaland General › Re: FUEL SCARCITY: 3 Types Of People That Can Get Fuel Easily At The Fuel Stations by osarcho: 3:13pm On May 06, 2015 |
femi4: na the baby wan drink the fuel? Awon alagbara aiye n ba e finra |
Celebrities › Re: Chichi Igbo Ex-super Falcons Star Talks About Her Sexuality, Dressing by osarcho: 3:05pm On May 06, 2015 |
see dis man o |
Politics › Re: Man Trekking To Otuoke For GEJ Gets Female Partner [photo] by osarcho: 2:59pm On May 06, 2015 |
OREMUSSANCTUS: Na wa ooo
Single boiz go soon start to dhe trek
So as to get free pvnny as price for trekking
I luv dis change, if na dis "change" apc dhe talk abt
Say no to "change"
We nid transformation
I pray and hope we won't regret voting out transformation I pray u grow brain sir
|