Comma (,)
Put comma
between difference selectors, you can get combine result. OR operator.
$("div,span,p.myClass").css("border","3px solid red");
In jQuery, call Multiple selector
Reference: http://api.jquery.com/multiple-selector/
Object orientation is much harder than you thinkMaybe it's just me, but coming from Computer Science class I thought that OO was easy. I mean, how hard can it be to create classes that mimic the real world? It turns out that it's pretty hard. Ten years later, I'm still learning how to model properly. I wish I spent more time reading up on OO and design patterns. Good modeling skills are worth a lot to every development team.




[ExpressionPrefix("Code")]
public class CodeExpressionBuilder : ExpressionBuilder {
public override CodeExpression GetCodeExpression(BoundPropertyEntry entry,
object parsedData, ExpressionBuilderContext context) {
return new CodeSnippetExpression(entry.Expression);
}
}
<compilation debug="true">
<expressionBuilders>
<add expressionPrefix="Code" type="Infinity.Web.Compilation.CodeExpressionBuilder"/>
</expressionBuilders>
</compilation>
<asp:CheckBox id="chk1" runat="server" Text="<%$ Code: DateTime.Now %>" />
- (void)doSomethingWithString:(NSString *)s {
if (nil != s) {
if ([s length] > 0) {
NSLog(@"%@", s);
}
}
}
// VS
- (void)doSomethingWithString:(NSString *)s {
if (nil == s)
return;
if (![s length])
return;
NSLog(@"%@", s);
}