Re: [jQuery] little help
Ah yes, i did have a look at the interface plugin. Very nice stuff. I hear that there going to be implimented into qjuery? so there will be no need for the 2 files? is this true? thanks again :) John Resig wrote: Also 2 more thing. could i put this into a new .js file and link it in the header and it will still work? Yes! As long as its after the jquery.js file, like you did before. and what other 'fxs' can i have? Iv experimented with the hide() and show() ones. jQuery comes with hide/show, slideUp/slideDown, and fadeIn/fadeOut - they're all pretty simple, and documented here: http://jquery.com/api/ However, the magic comes in when you use .animate, which allows you do do stuff like: $(#foo).animate({ top: 100, height: show, opacity: show }, slow); Which will give you some sort of crazy effect. The Interface library (http://interface.eyecon.ro/) has a whole mess of extra effects built in to it, so that's an option too. --John ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ -- View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6232427 Sent from the JQuery forum at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
No, i think it is going to stay as a plugin. You can move the contents of the interface.js file into your jquery file, and that would do the same thing.On 9/10/06, kevdotbadger [EMAIL PROTECTED] wrote: Ah yes, i did have a look at the interface plugin. Very nice stuff. I hearthat there going to be implimented into qjuery? so there will be no need forthe 2 files? is this true?thanks again :)John Resig wrote: Also 2 more thing. could i put this into a new .js file and link it in the header and it will still work? Yes! As long as its after the jquery.js file, like you did before. and what other 'fxs' can i have? Iv experimented with the hide() and show() ones. jQuery comes with hide/show, slideUp/slideDown, and fadeIn/fadeOut - they're all pretty simple, and documented here: http://jquery.com/api/ However, the magic comes in when you use .animate, which allows you do do stuff like: $(#foo).animate({ top: 100, height:show, opacity: show }, slow); Which will give you some sort of crazy effect. The Interface library (http://interface.eyecon.ro/) has a whole mess of extra effects built in to it, so that's an option too. --John ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/--View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6232427 Sent from the JQuery forum at Nabble.com.___jQuery mailing listdiscuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
It dont work sorry! !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 TRANSITIONAL//EN html head title/title script type=text/javascript src=jquery-latest.pack.js/script script type=text/javascript $('#showCommentBox').click(function() { $('#addcomment:hidden').slideDown(); }); $('#hideCommentBox').click(function() { $('#addcomment').slideUp(); }); /script style #addcomment { display: block; border: 1px solid red; width: 300px; } /style /head body javascript:void(0) Show Comment Form div id=addcomment safglkjahdsgakljfhgad glkaf hj aflkjg haf g jk lkj aglj javascript:void(0) Hide Comment Form /div /body /html any ideas? Also whats the deal with 'javascript:void(0)'? whast that do? thanks -- View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6222954 Sent from the JQuery forum at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
On Sep 9, 2006, at 7:27 AM, kevdotbadger wrote: It dont work sorry! any ideas? Also whats the deal with 'javascript:void(0)'? whast that do? Hi, there are a couple things you can do to make this work. 1. wrap your jquery code in $(document).ready( 2. add return false; to your click events. 3. by adding return false; you can get rid of the ugly javascript:void(0) in your href. What you put in the href is up to you, but you should consider graceful degradation when users have javascript turned off. I grabbed your example below and dropped it into a page on my site so you can see a functioning example. Just view source from the page and copy and paste what you want: http://sandbox.englishrules.com/show- hide.htm Cheers, Karl ___ Karl Swedberg www.englishrules.com www.learningjquery.com !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 TRANSITIONAL//EN html head title/title script type=text/javascript src=jquery-latest.pack.js/script script type=text/javascript $('#showCommentBox').click(function() { $('#addcomment:hidden').slideDown(); }); $('#hideCommentBox').click(function() { $('#addcomment').slideUp(); }); /script style #addcomment { display: block; border: 1px solid red; width: 300px; } /style /head body javascript:void(0) Show Comment Form div id=addcomment safglkjahdsgakljfhgad glkaf hj aflkjg haf g jk lkj aglj javascript:void(0) Hide Comment Form /div /body /html ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
Ah i see! I get you now! and its perfect! just what i want! and only 10 lines! WOW! Thank for all the help! you've made my day! AND you guys are so nice to a noob around here! ususally if i post a simple question like this and start telling you that you got the point of the topic wrong i get my bum kicked! AND now ive got a lil better understanding of how things work. Functions, and changing class's etc! Thank you VERY much everyone! Also 2 more thing. could i put this into a new .js file and link it in the header and it will still work? and what other 'fxs' can i have? Iv experimented with the hide() and show() ones. Karl Swedberg-2 wrote: On Sep 9, 2006, at 7:27 AM, kevdotbadger wrote: It dont work sorry! any ideas? Also whats the deal with 'javascript:void(0)'? whast that do? Hi, there are a couple things you can do to make this work. 1. wrap your jquery code in $(document).ready( 2. add return false; to your click events. 3. by adding return false; you can get rid of the ugly javascript:void(0) in your href. What you put in the href is up to you, but you should consider graceful degradation when users have javascript turned off. I grabbed your example below and dropped it into a page on my site so you can see a functioning example. Just view source from the page and copy and paste what you want: http://sandbox.englishrules.com/show- hide.htm Cheers, Karl ___ Karl Swedberg www.englishrules.com www.learningjquery.com !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 TRANSITIONAL//EN html head title/title script type=text/javascript src=jquery-latest.pack.js/script script type=text/javascript $('#showCommentBox').click(function() { $('#addcomment:hidden').slideDown(); }); $('#hideCommentBox').click(function() { $('#addcomment').slideUp(); }); /script style #addcomment { display: block; border: 1px solid red; width: 300px; } /style /head body javascript:void(0) Show Comment Form div id=addcomment safglkjahdsgakljfhgad glkaf hj aflkjg haf g jk lkj aglj javascript:void(0) Hide Comment Form /div /body /html ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ -- View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6229373 Sent from the JQuery forum at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
Also 2 more thing. could i put this into a new .js file and link it in the header and it will still work? Yes! As long as its after the jquery.js file, like you did before. and what other 'fxs' can i have? Iv experimented with the hide() and show() ones. jQuery comes with hide/show, slideUp/slideDown, and fadeIn/fadeOut - they're all pretty simple, and documented here: http://jquery.com/api/ However, the magic comes in when you use .animate, which allows you do do stuff like: $(#foo).animate({ top: 100, height: show, opacity: show }, slow); Which will give you some sort of crazy effect. The Interface library (http://interface.eyecon.ro/) has a whole mess of extra effects built in to it, so that's an option too. --John ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
haha john, your getting a little too complicated here, he just needs slideup, slidedown, no ajax requests involved ;)This should work kenton:in your head:script$('#showCommentBox').click(function() { $('#addcomment:hidden').slideDown();});$('#hideCommentBox').click(function() {$('#addcomment').slideUp();});/scriptAnd heres the links you need:a href="" id=showCommentBoxShow Comment Form/a And the hide link, goes inside the div:a href="" id=hideCommentBoxHide Comment Form/aOn 9/8/06, kevdotbadger [EMAIL PROTECTED] wrote: Hay, i think you got a lil too complicated for what i want! Im reallygreatful for the help and replys BUT all i need is a div (#addcomment) to beshown(slide down) when a link is clicked. then another link within the div to slide the div up(slide up).thanks =)kenton.simpson wrote: I'm using nabble for my post. I would seem somethings are not posting where John Resig wrote: That is correct and the $(function is shorthand. and the [ is require and the function will not work with out it. oops by bad!!! I guess I need to review the docs agian. $.ajax(post,savecomment.cgi, { comment: $(#fldcomment).val() }); You only need the [ { name: ..., value: ... } ] syntax if the order of the parameters matters to you. And since there's only one, this is a moot point. --John ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ --View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6214483Sent from the JQuery forum at Nabble.com.___jQuery mailing listdiscuss@jquery.comhttp://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] little help
I'm using nabble for my post. I would seem somethings are not posting where John Resig wrote: That is correct and the $(function is shorthand. and the [ is require and the function will not work with out it. oops by bad!!! I guess I need to review the docs agian. $.ajax(post, savecomment.cgi, { comment: $(#fldcomment).val() }); You only need the [ { name: ..., value: ... } ] syntax if the order of the parameters matters to you. And since there's only one, this is a moot point. --John ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ -- View this message in context: http://www.nabble.com/little-help-tf2235942.html#a6202198 Sent from the JQuery forum at Nabble.com. ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/