I bet you used the filter() function to do it, right?

This function only works if you specify one field or an array of fields to use in filtering out results based on 1 search text. If there is more than 1 value to consider in filtering entries in the store, you will have to use the filterBy() function for custom and complex scenarios.

Check out this sample code.

The code filters entries in the store where a model’s field name labeled fieldname1 and fieldname2 has a substring of searchkey1 and searchkey2 respectively. That is how you should do it.

This won’t work.

windowslogo_256x256Wow, I just read today that China has announced it would indefinitely postpone a mandate requiring all personal computers sold in the country to be accompanied by a controversial content-filtering application. If that software is in my desktop, I would be feeling uneasy knowing that everything I do, surf, type, whatever may not be possible in some cases because of that filtering. It is always good to know what is going on with your country and that filtering software will surely minimize content regarding politics. While its main purpose they say is to filter pornography, there will be other purposes not divulged to the public.

It is their government so they can do pretty much anything they want. But it would be a good thing if people would know everything that is happening in their country rather than hiding some of the truth from them. The software is good for Windows based PCs. If the software were to be installed now, it is a good time to buy a Macbook ;).

tomcatWhen using Apache Tomcat as the Servlet container server for your Servlet needs, sooner or later you will come across a situation where you need to do something before and after you login using j_security_check. The solution is to use Servlet filters so that every request will pass through these filters. But using it for j_security_check? The answer is? NO. You cannot do this in Tomcat. While I did read in some articles that IBM Websphere will let you do this, in Apache Tomcat there is just no way. You can try some other workaround that uses the Servlet Filter class to do what you want it to do.

Related Posts Plugin for WordPress, Blogger...