Site Sponsors:
Capital has been described as ... 

From the EBook of International Finance:

"... Capital has been described above as money put to certain purposes. This was done for the sake of clearness and because this definition fits in with the facts as they usually happen in these days. Economists define capital as wealth reserved for production, and we must always remember that money is only a claim for, or a right to, a certain amount of goods or a certain amount of other people's work. Money is only a title to wealth, because if I have a sovereign or a one-pound note in my pocket, I thereby have the power of buying a pound's worth of goods or of hiring a doctor to cure me or a parson to bury me or anybody else to do anything that I want, up to the buying power of that sovereign. This is the power that money carries with it. When the owner of this power, instead of exercising it in providing himself with luxuries or amusements, uses it by lending it to someone who wants to build a factory, and employ workers, then, because the owner of the money receives his rate of interest he is said to be exploiting labour, because, so it is alleged, the workers work and he, the capitalist, sits in idleness and lives on their labour.

And so, in fact, he does. But we have not yet found out how he got the money that he lent. That money can only have been got by work done or services rendered, for which other people were ready to pay. Capital, looked at from this point of view, is simply stored up work, and entitled to its reward just as much as the work done yesterday. The capitalist lives on the work of others, but he can only do so because he has wrought himself in days gone by or because someone else has wrought and handed on to him the fruits of his labour. ..."

Nice read - Here is the free eBook. Feel free to share this book by Mr. Hartley Withers with any eager learners you may bump into over the holidays?



[ view entry ] ( 4094 views )   |  permalink  |  related link
Drag & Drop, HTML 5, and jQuery 
HTML5 has a lot to offer. From new tags to embedded media support & drawing on graphical canvases, much more is afoot than simply levelling the Web 2.0 playing field!

So it was as I was recently teaching a class on jQuery. While drag-and-drop is surely part of the HTML5 bag of tricks, jQuery's User Interface (UI) can load the AxtiveX and other plug-ins we need to make much of it work on older Browsers.

Here is the jQuery-UI.

Here is a nice jQuery / JavaScript example:

<!doctype html>

<html lang="en">
<meta charset="utf-8" />
<title>jQuery: Drag, Drop, &amp; Disable Example</title>
<script src="jquery-1.8.3.js"></script>
<script src="jquery-ui.js"></script>
#drag { background-color: #ff0000; cursor: move; width: 200px; height: 50px; padding: 0.5em; float: left; margin: 10px 10px 10px 0; }
#drop { background-color: #00ff00; cursor: pointer; width: 300px; height: 150px; padding: 0.5em; float: left; margin: 10px; }
<!-- REF: -->
$(function() {
$( "#drag" ).draggable();
$( "#drop" ).droppable({
drop: function( event, ui ) {
$( this ).find( "p" ).html( "Welcome home ... " );
$( "#drag" ).html("Thanks!");

<div id="drag">
<p>Fly me into the green box</p>

<div id="drop" >
<p>Landing Zone!</p>




[ view entry ] ( 3143 views )   |  permalink
Installing Tomcat - Eclipse & Windows 

Step 1: Get Your JDK

Before doing "anything Java", we need to get the SDK.

While we are surely using JEE (Tomcat!), the plain old JDK is all that is required - indeed, because the JEE SDK + JDK packages install Glassfish as well, to the uninitiated, installing yet another web server can also compete for the same computer ports. It will drive beginners nuts!

So for this post, note that we are using JDK 6 Update 37. We got that here, not here. (Do YOU use Glassfish? -Neither does anyone else :)

Since the default port for Tomcat is 8080, you might want to be sure that http://localhost:8080/ is not being used...

Next, since the JDK will obviously have to RUN those things that we write, the JDK obviously includes the JRE. (If you do not know what a JRE or an JDK is, then please seek another page-of-worship. This post ain't where you want to be starting out ;-)

Install Your JDK

Since you will need to install the EXE (what we wanted to do on Windows), you will most likely need to be logged in as an Adminstrator.

So install your JDK, remembering where you install it: You will need to use that location in the next step. For my VM, the default was C:\Program Files\Java\....

Path Your JDK

Of course, just because we install something, does not mean that Apache / Tomcat will be able to find it. To allow others to find the Java that we want to use, we need to set up one of three (3) possible environment variables. Presently, these can either be PATH, JAVA_HOME, or the JRE_HOME.

Since the names imply what they are, we decided to use JAVA_HOME over the System-Wide PATH.


Under Windows, Environment Variables are accessible via a RIGHT-click on Start | My Computer (or - since Microsoft, not those who bought it, owns it these days, post Windows XP it is just labelled "Computer" ;-) ) to peruse "Advanced Settings", then "Environment Variables."


For the JAVA_HOME environment variable, we used C:\Program Files\Java\jdk1.6.0_37. If you used PATH, you would need to use C:\Program Files\Java\jdk1.6.0_37\bin.

Step 2: Get Your Tomcat

There are several ways to get a copy of Tomcat. Since we were using Eclipse Juno, after installing Eclipse, we just let the IDE download it for us. Others might want to download & unzip it from here.

No matter how (or where) we get Tomcat, the starting of it is simple: Unzip the install to a folder, open the folder, then go to the BIN directory. Thereafter, use the startup / shutdown commands to start & stop the Tomcat Server.

NOTE: Once Tomcat is running, that startup console window will remain open until Tomcat is shut down. If the console window flashes and then goes away, open another command prompt, navigate to that same folder, and run the startup file directly. 99 times our of 100, the output from the process will tell us that you need to repair your JAVA_HOME.

Once Tomcat is started, you can verify that all is well by navigating to port 8080 on your localhost. If Tomcat is running, then you will see a page displayed there.

Step 3: Get Your Server

Now open Eclipse. If you have a non-working Apache Server Definition installed in your Servers View, then delete the monster - config file and all.

To get a WORKING Server Definition:

(1) Out Of Eclipse: Start your Tomcat or otherwise verify that 8080 is showing that default Tomcat page. Do not run more than one instance of Tomcat.

(2) Inside Eclipse: Open a Server View to create a new Tomcat Server Definition. Map your installation path to wherever that presently-running instance of Tomcat is located.

(3) Test Your Server: Create a dynamic web project. Create an interesting index.html under that WebContent folder. Deploy and run the project on the Tomcat Server. All should be well!

(4) Out Of Eclipse: Once tested, Eclipse knows what to do from now on-out. It will deploy, run, shut-down, and test your web applications as expected. Feel free to shut Tomcat down.

Step 4: Notes

Note that if you want to use the Tomcat Manager Link on the default 8080 page, then we will have to include a user in Tomcat's config/tomcat-users.xml file:

If you are using Tomcat 6:
<?xml version='1.0' encoding='utf-8'?>
<user username="admin" password="admin" roles="admin,manager"/>

If you are using Tomcat 7:
<?xml version='1.0' encoding='utf-8'?>
<role name="manager-gui"/>
<user username="admin" password="admin" roles="admin,manager-gui"/>

Next, if you are using a NEWER version JRE in Eclipse (1.7), then when deploying to a web-based Tomcat, you might see:
com/javatunes/web/CartServlet :
Unsupported major.minor version 51.0 (unable to load class
The solution is to DOWNGRADE Eclipse to use a comparable JDK. (In this case, one would change your Eclipse Project from 1.7 to 1.6, so as to match (for example) the JAVA_HOME previously specified.)

Finally, if you still have a setup problem, then many find the `related link` (in red, below) to be of value - (I simply found most of it to be annoying :)



[ view entry ] ( 3036 views )   |  permalink  |  related link

<<First <Back | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | Next> Last>>