Recent Notes

Displaying notes 41 - 50
Created by James on August 08, 2014 12:17:50    Last update: August 08, 2014 12:17:50
Simple answer: use $(elem).css('margin-top') , $(elem).css('padding-left') , etc., don't use $(elem).css('margin') or $(elem).css('padding') , they return empty strings. Example: // set margin to 8px $('#test-div').css('margin...
Created by James on August 06, 2014 16:11:23    Last update: August 06, 2014 16:11:23
Select all <li> that are descendants (children, grand children etc.) of <ul> : ul li { margin: 0 0 5px 0; } Select all <li> that are direct children of <ul> : ul > li { margin: 0 0 5px 0; } Select all <p> that immediately follow another <p> : p + p { font-size: smaller; } Select a <ul> that immediately follows an element with id " title ": #title + ul { margin-top: 0; } Select all <p> that follow another </p> , not necessarily immediate sibling: p ~ p { font-size: smaller; }
Created by James on August 05, 2014 13:35:05    Last update: August 05, 2014 13:36:15
This demo page shows how to fade text in the end of an abstract with a "Learn more..." link to the full text. This technique could be helpful when you want to display an RSS feed abstract in a fixed height element and provide a link to the full-length article at the bottom. <html> <head> <title>Learn More</title> <...
Created by Jenny on July 29, 2014 10:35:51    Last update: July 29, 2014 10:35:51
For working with xml files use a good xml tool like an xml editor .
Created by James on July 29, 2014 10:09:55    Last update: July 29, 2014 10:09:55
To sort a selected list of divs by vertical position: $('div.container').sort(function(a, b) { return $(...
Created by woolf on June 29, 2014 17:55:44    Last update: June 29, 2014 17:55:44
This is the command: $ git remote show origin
Created by James on June 17, 2014 16:27:29    Last update: June 17, 2014 16:27:29
With built-in Array.concat : // initialize a1 a1 = [1, 2, 3] // i... With jQuery merge : // initialize a1 a1 = [1, 2, 3] // i...
Created by James on June 17, 2014 16:13:40    Last update: June 17, 2014 16:13:40
The jQuery extend function merges the contents of two or more objects into the first one. // initialize the first object o1 = { a: 1, b: ...
Created by Dr. Xi on June 04, 2014 18:59:37    Last update: June 04, 2014 18:59:37
There's really no good solution since Tomcat hardwires the root context to the WAR file name. The easiest solution might be simply rename the WAR file during deployment.
Created by Dr. Xi on June 04, 2014 16:56:56    Last update: June 04, 2014 16:56:56
The error was something like this: Simple type "ExtraLongEnumListType" was not mapped... Solution: create a binding file to increase the EnumMemberSizeCap limit. The POM file: <dependency> <groupId>org.apach... Contents of bindings.xml : <jaxb:bindings xmlns:jaxb="http://java.sun....
Previous  1 2 3 4 5 6 7 8 9 10 Next