Skip to main content

Posts

Showing posts from May, 2018

log4net.config setting - appender create a file each month

Example of File and Folder structure └───2018 └───May-2018_logfile.log └─── Jun-2018_logfile.log └───Jul-2018_logfile.log └───Aug-2018_logfile.log Log4net.config configuration example <log4net> <appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender, log4net"> <file type="log4net.Util.PatternString" value="C:/logs/log4netLogs/%date{yyyy}/" /> <appendToFile value="true" /> <rollingStyle value="Date" /> <staticLogFileName value="false" /> <datePattern value="MMM-yyyy'_logfile.log'" /> <layout type="log4net.Layout.PatternLayout"> <conversionPattern value="%date [%thread] %-5level %logger %M - %message%newline%newline" /> </layout> </appender> <logger name="File"> <level value="All" /> <appender-ref ref="

Selecting and manipulating CSS pseudo-elements such as ::before and ::after using jQuery

You could also pass the content to the pseudo element with a data attribute and then use jQuery to manipulate that: In HTML: <span> foo </span> In jQuery: $ ( 'span' ). hover ( function (){ $ ( this ). attr ( 'data-content' , 'bar' ); }); In CSS: span : after { content : attr ( data-content ) ' any other text you may want' ; } If you want to prevent the 'other text' from showing up, you could combine this with seucolega's solution like this: In HTML: <span> foo </span> In jQuery: $ ( 'span' ). hover ( function (){ $ ( this ). addClass ( 'change' ). attr ( 'data-content' , 'bar' ); }); In CSS: span . change : after { content : attr ( data-content ) ' any other text you may want' ; } Ref : https://stackoverflow.com/questions/5041494/selecting-and-manipulating-css-pseudo-elements-such-as-before-and-after-usin

with(nolock) or (nolock) - Is there a difference?

There is no functional difference, but eventually the syntax without   WITH   will not work. This has been deprecated: select customer , zipcode from customers c ( nolock ) So you should be using this format: select customer , zipcode from customers c with ( nolock ) Not using the   WITH   keyword for table hints has been deprecated since at least SQL Server 2008. Search the following topic for the phrase   Specifying table hints without using the WITH keyword. : http://msdn.microsoft.com/en-us/library/ms143729%28SQL.100%29.aspx Ref :  https://stackoverflow.com/questions/12112855/withnolock-or-nolock-is-there-a-difference