if (barLimit <1)
divobj.innerHTML = ("This will not work because you have surpassed the limit of " + barLimit.toFixed(0) );
else if (weightLimit <1)
divobj.innerHTML = ("This will not work: wl="+ weightLimit+","+spaceUsable+","+barsNeededFor1800+";");
respond = 'With the total cargo area of the chosen car, you are able to fit ' +totalCanFit.toFixed(0) +
' bars. You will need ' + barsNeededFor1800.toFixed(0) +
' bars to reach to the 1800 lbs limit. ';
that means that barLimit is always >= 1 and weightLimit is always >= 1.
You just need to do some basic debugging to find out why. You can use the developer tools in your browser to step through your code to check values of variables at various points or you can use alert() statements to check values of variables at different points. Just step through your code line by line until you find a variable whose value is not what it should be and then back track your code to find where the value is being assigned and fix it.
Think of debugging as character building and a skill you need to develop if you're going to be a coder of any kind.