Recently learned VML: cakepie. innerhtml = "<v: Shape id = 'cake" + (I + 1) + "'Type = '# cake_3d'" +
"Style = 'position: absolute; left:" + (_ left + height/8) + "PX; top:" + (_ top + height/24) + "PX; width: "+ height +" PX; Height: "+ height +" PX; rotation: "+ rotates +"; Z-index: "+ zindex +" 'adj = '"+ adjs +", 0' "+
"Stroked = 'false' fillcolor = '" + this. cakes [I] [2] + "'onclick = 'movecake (cake" + (I + 1) + ", REC" + (I + 1) + ")' Onmouseover = 'moveover ( \ "" + This. Cakes [I] [0] +" \ "," + This. percent [I] + ") 'onmouseout = 'moveout () '>" +
"<V: Fill Opacity = '60293f' color2 = 'fill lighten (120) 'O: opacity2 = '60293f' rotate = 't'angle = '-135' method = 'linear Sigma 'focus = '000000' type = 'gradient'/> "+
"<O: extrusion V: ext = 'view' on = 't'background= '16' rotationangle = '60' viewpoint = '0, 0' viewpointorigin = '0, 0 'skewamt = '0' lightposition = '-50000,-50000 'lightposition2 = '20140901'/> "+
"</V: Shape> ";
The red partMoveoverThe first parameter of the function is the name of cake, because it is in a double quotation mark string.In the beginning, it was written as follows:Onmouseover = 'moveover ("+ this. Cakes [I] [0] +", "+ this. percent [I] + ")'
The value of this. Cakes [I] [0] cannot be obtained in the moveover function. Then I added single quotes on both sides.Onmouseover = 'moveover ('"+ this. Cakes [I] [0] +"', "+ this. percent [I] + ")'I still can't. I finally solved it with a forward slash + double quotation marks (in blue ).