Solved

please see what is wrong with my jquery code

Posted on 2012-04-07
6
212 Views
Last Modified: 2012-04-22
Hi I am just learning a bit of jquery.

Can someone please advise what is wrong with my code below?

thanks


<html>
      <head>
            <title>Follow me!</title>
            <script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script>
            <script type="text/javascript">
                  $(function() {
                        $("<p>Hi there!</p>").insertAfter("#followMe");
                  });
            </script>
      </head>
      <body>
            <p id="folowMe"></p>
      </body>
</html>
0
Comment
Question by:jecommera
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 37819058
followMe vs folowMe

you miss one << l >> in the
<p id="folowMe"></p>

Open in new window

should be :
<p id="followMe"></p>

Open in new window

0
 

Author Comment

by:jecommera
ID: 37819062
thanks, however I still get the no paragraph added
<html>
      <head>
            <title>Follow me!</title>
            <script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script>
            <script type="text/javascript">
                  $(function() {
                        $("<p>Hi there!</p>").insertAfter("#followMe");
                  });
            </script>
      </head>
      <body>
            <p id="followMe"></p>
      </body>
</html>
0
 
LVL 82

Expert Comment

by:leakim971
ID: 37819078
maybe you need to refresh/clear your cache : http://jsfiddle.net/avdQE/
0
Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

 

Author Comment

by:jecommera
ID: 37819102
Hi,

This is front end local host.
Does the code run on your computer?
0
 

Author Comment

by:jecommera
ID: 37819104
actually its working fine now.

By the way what is that jsfiddle site you are using above?
0
 
LVL 82

Expert Comment

by:leakim971
ID: 37819144
0

Featured Post

[Live Webinar] The Cloud Skills Gap

As Cloud technologies come of age, business leaders grapple with the impact it has on their team's skills and the gap associated with the use of a cloud platform.

Join experts from 451 Research and Concerto Cloud Services on July 27th where we will examine fact and fiction.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

DOM Attributes and Properties treatment with jQuery 1.6 by Ivo Stoykov jQuery (http://jquery.com/) 1.6 introduces .prop() (http://api.jquery.com/prop/) and .removeProp() (http://api.jquery.com/removeProp/) methods which allow modifying or removi…
Requirements JQuery 1.6+ HTML CSS Introduction This article was inspired by an EE question (http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28372511.html) on how to make a page show some balloons animate up a page…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

628 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question