I have this function and i want to grab the values from the prmpts and instert them in the transformation matrix. For some reason this is not working. I am thinking that the problem is because i need to use "" before and after each var but because its already within the " " 's of the transformation matrix i cant nest them. Any ideas?
This is my code.
<script>
function output() {
var transformw = prompt("Enter your new width");
var transformh = prompt("Enter your new height");
var newnew = 4;
svgCanvas.changeSelectedAttribute("transform", "matrix( transformw, 0, 0, transformh, 0, 0)");
svgCanvas.recalculateAllSelectedDimensions();
}
</script>
I have this function and i want to grab the values from the prmpts and instert them in the transformation matrix. For some reason this is not working. Any ideas?