Forum Moderators: open

Message Too Old, No Replies

Setting News ticker at website it shows an error

         

toplisek

12:41 pm on Apr 14, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I have tested news ticker at URL:
[makemineatriple.com...]

I have put all working code at URL and seen error inside function:
$ is not a function
$(document).ready(function() {


Javascript is at the top of website:
<script language="JavaScript" type="text/javascript">
/*<![CDATA[*/
$(document).ready(function() {
var options = {
newsList: "#news",
startDelay: 10,
placeHolder1: " []"
}
$().newsTicker(options);
});
/*]]>*/
</script>

Do you have idea how to avoid this error as on local PC works without any issue. When I upload it shows an error.

Need help.

mbabuskov

2:53 pm on Apr 14, 2011 (gmt 0)

10+ Year Member



$ is short for jQuery. You probably have a wrong path to it, i.e. path that works on your local machine, but not on the server.

HTH

--
Milan B.
www.CountdownGames.tv

toplisek

7:44 pm on Apr 14, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



My path to jquery script is correct. Should be put $(document).ready(function() {
some value?
Is there some line in javascript to detect error in path?

mbabuskov

9:49 pm on Apr 14, 2011 (gmt 0)

10+ Year Member



No, not jquery function, but path to jquery library in <script> tag where you include jQuery in your HTML.

Something like:

<script src="http://myserver/path/to/jquery.js" type="text/javascript"></script>