views:

62

answers:

1

This code is straight from the original page of the jQuery.Path plugin, only I added a hash in front of the selector after i gave my tag an id of "my_elem" because it wasn't working.

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="path.aspx.cs" Inherits="path"     %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1    /DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"&gt;
<head runat="server">
<script src="scripts/jquery-1.3.2.min.js" type="text/javascript"></script>
<script src="scripts/jquery.path.js" type="text/javascript"></script>
<script type="text/javascript">
    $(document).ready(function() {
        var bezier_params = {
            start: {
                x: 185,
                y: 185,
                angle: 10
            },
            end: {
                x: 540,
                y: 110,
                angle: -10,
                length: 0.25
            }
        };
        $("#my_elem").animate({ path: new $.path.bezier(bezier_params) }, 1000);
    });
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
    <img id="my_elem" src="images/image.jpg" />
</div>
</form>
</body>
</html>

and it doesn't do a thing. My little 50x50 jpg loads and sits there. Should I even be expecting it to move? What am I missing? I have included jquery-1.3.2.min.js and jquery.path.js followed by the above code.

Edit Added full page code.

A: 

For those of you anxiously awaiting the fix for this, it is relative positioning that I would say I missed, but it was never really mentioned anywhere. I reviewed the source of the sample shown everywhere and it hit me.

<img id="my_elem" src="images/image.jpg" style="position: relative;" />
David