[jQuery] jquery array
I need to make a array from a list ulli class=dataimg src=xtabletrtddata/td/tr/ table/li li class=dataimg src=x2tabletrtddata2/td/tr/ table/li li class=dataimg src=x3tabletrtddata3/td/tr/ table/li/ul I am having a hard time using jQuery.makeArray() to make an array from the data and print it out. How can this be done. Thanks -Tom
[jQuery] loop through div
how can i loop through each div on a page and have them appear one by one i am trying var arrayList2 = $.makeArray(document.getElementsByClassName (.type)); $.each(arrayList2,function() { $(this).show(); }); thanks -tj
[jQuery] Re: loop through div
thanks guys! On Mar 16, 7:26 pm, ricardobeat ricardob...@gmail.com wrote: jQuery.fn.showLoop = function(i){ var i = i || 0, self = this; $( this[i] ).show(600, function(){ self.showLoop(++i); }); }; $('.type').showLoop(); On Mar 16, 7:27 pm, Tom Shafer tom.sha...@gmail.com wrote: how can i loop through each div on a page and have them appear one by one i am trying var arrayList2 = $.makeArray(document.getElementsByClassName (.type)); $.each(arrayList2,function() { $(this).show(); }); thanks -tj
[jQuery] Re: loop through div
im getting too much recursion in firebug, any thought? On Mar 16, 7:26 pm, ricardobeat ricardob...@gmail.com wrote: jQuery.fn.showLoop = function(i){ var i = i || 0, self = this; $( this[i] ).show(600, function(){ self.showLoop(++i); }); }; $('.type').showLoop(); On Mar 16, 7:27 pm, Tom Shafer tom.sha...@gmail.com wrote: how can i loop through each div on a page and have them appear one by one i am trying var arrayList2 = $.makeArray(document.getElementsByClassName (.type)); $.each(arrayList2,function() { $(this).show(); }); thanks -tj
[jQuery] Re: loop through div
doesnt seem to work get a recursion error thanks! On Mar 16, 7:26 pm, ricardobeat ricardob...@gmail.com wrote: jQuery.fn.showLoop = function(i){ var i = i || 0, self = this; $( this[i] ).show(600, function(){ self.showLoop(++i); }); }; $('.type').showLoop(); On Mar 16, 7:27 pm, Tom Shafer tom.sha...@gmail.com wrote: how can i loop through each div on a page and have them appear one by one i am trying var arrayList2 = $.makeArray(document.getElementsByClassName (.type)); $.each(arrayList2,function() { $(this).show(); }); thanks -tj
[jQuery] jquery each help
I have articles in a group of divs div class=art div id=leftMainimg src=media/img/greenBar.png width=11 height=211//div div id=rightMain span class=postedDatePOSTED: 15 MARCH 2008 1400 HOURS/span div class=articleHeader SNEAK PREVIEW OF iNO CHILD.../i/ div div class=articleContentpLorem ipsum dolor sit am/p/div div class=articleDownload a href=#DOWNLOAD 10% DISCOUNT PASS/a/div div class=clearfix/div /div div class=art div id=leftMainimg src=media/img/greenBar.png width=11 height=211//div div id=rightMain span class=postedDatePOSTED: 15 MARCH 2008 1400 HOURS/span div class=articleHeader SNEAK PREVIEW OF iNO CHILD.../i/ div div class=articleContentpLorem ipsum dolor sit amet, conat nulla facilisis./p/div div class=articleDownload a href=#DOWNLOAD 10% DISCOUNT PASS/a/div div class=clearfix/div /div I am trying to loop through each class and display them one at a time, article one will display and each class inside article one will show (using the show()) function one at a time. This will happen with each with each article one after another for as many articles as there are. This could be 2 this could be 10. I know this is not a convenient way to load a page but this is what i am trying to do. I am also using a typewriter unction to display letters one at a time. I have this right now var arrayList = $.makeArray($('.art').get()); $.each(arrayList,function() { $(this).show(); $('.postedDate').show().jTypeWriter({onComplete:function(){ $('.articleHeader').show().jTypeWriter({onComplete:function(){ $('.articleContent').show().jTypeWriter({onComplete:function() { }}); }}); }}); }); it doesnt quite get it right. Here is the sample page http://pavlishgroup.com/projects/cpt-test/ thanks in advance
[jQuery] Re: jquery each help
Im getting the effects I want just not in the right order. I think im going the right way with each, im just not using it the right way. Any other thoughts? -TJ On Mar 15, 4:20 pm, Josh Powell seas...@gmail.com wrote: read up on the .animate() jQuery effect, this might be what you are looking for. http://docs.jquery.com/Effects/animate On Mar 15, 11:46 am, Tom Shafer tom.sha...@gmail.com wrote: I have articles in a group of divs div class=art div id=leftMainimg src=media/img/greenBar.png width=11 height=211//div div id=rightMain span class=postedDatePOSTED: 15 MARCH 2008 1400 HOURS/span div class=articleHeader SNEAK PREVIEW OF iNO CHILD.../i/ div div class=articleContentpLorem ipsum dolor sit am/p/div div class=articleDownload a href=#DOWNLOAD 10% DISCOUNT PASS/a/div div class=clearfix/div /div div class=art div id=leftMainimg src=media/img/greenBar.png width=11 height=211//div div id=rightMain span class=postedDatePOSTED: 15 MARCH 2008 1400 HOURS/span div class=articleHeader SNEAK PREVIEW OF iNO CHILD.../i/ div div class=articleContentpLorem ipsum dolor sit amet, conat nulla facilisis./p/div div class=articleDownload a href=#DOWNLOAD 10% DISCOUNT PASS/a/div div class=clearfix/div /div I am trying to loop through each class and display them one at a time, article one will display and each class inside article one will show (using the show()) function one at a time. This will happen with each with each article one after another for as many articles as there are. This could be 2 this could be 10. I know this is not a convenient way to load a page but this is what i am trying to do. I am also using a typewriter unction to display letters one at a time. I have this right now var arrayList = $.makeArray($('.art').get()); $.each(arrayList,function() { $(this).show(); $('.postedDate').show().jTypeWriter({onComplete:function(){ $('.articleHeader').show().jTypeWriter({onComplete:function(){ $('.articleContent').show().jTypeWriter({onComplete:function() { }}); }}); }}); }); it doesnt quite get it right. Here is the sample page http://pavlishgroup.com/projects/cpt-test/ thanks in advance
[jQuery] slowly load image 1 line at a time
hi, I am in need of some way to slowly load a image 1 line at a time, or maybe load a div 1 line at a time any ideas? thanks, -tom
[jQuery] [Exception... Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE)
what does this error mean [Exception... Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.open] nsresult: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) location: JS frame :: http://tjshafer.com/projects/boyd/js/jquery-1.3.2.min.js :: anonymous :: line 19 data: no] -tj
[jQuery] nsIXMLHttpRequest.open error
I get the error [Exception... Component returned failure code: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) [nsIXMLHttpRequest.open] nsresult: 0x80070057 (NS_ERROR_ILLEGAL_VALUE) location: JS frame :: http://tjshafer.com/projects/boyd/js/jquery-1.3.2.min.js :: anonymous :: line 19 data: no] [Break on this error] (function(){var R=/((?:\((?:\([^()]+\)|[... (J,typeof K===string?K:K+px)}})})(); Here is the page it is on http://tjshafer.com/projects/boyd/home.php click on add new on the left menu, a form will pop open and when you click next you can see the error in firebug please let me know what it might be -thanks, tj
[jQuery] attr feature
Does the attr feature let me capture my own attribute inside a element. I am trying and it doesnt seem to be working. I just wondering if there was a way to do this. Thanks -Tom
[jQuery] Re: attr feature
sorry about that $('#projectid').attr('link') this is going into ajax post On Feb 9, 10:59 am, MorningZ morni...@gmail.com wrote: Maybe showing an example of what isn't working would help others help you On Feb 9, 10:28 am, Tom Shafer tom.sha...@gmail.com wrote: Does the attr feature let me capture my own attribute inside a element. I am trying and it doesnt seem to be working. I just wondering if there was a way to do this. Thanks -Tom
[jQuery] sortable update problem
I am using sortable and using the update feature to post the order $(#2).sortable({ //connectWith: [#homePage,#acquire,#build], items: li, opacity: 90, revert: true, placeholder: sortHelper, activeclass: sortActive, hoverclass: sortHelper, dropOnEmpty:true, update: function(element, ui) { $.post(addLinks.php,{ step:'update',order:$(this).sortable (serialize)}); } }); it seems that update doesnt work after i upgraded to jquery 1.3.1 i also upgraded jquery ui to 1.5.3 as well as sortable I can drag and drop and do everything I used to be able to do with 1.2.6. I upgraded to take advantage of the new live function for event delegation What could of changed or what I am i missing to make update work Thanks Tom
[jQuery] Re: sortable update problem
works perfectly, thank you very much -Tom On Feb 2, 12:32 pm, Richard D. Worth rdwo...@gmail.com wrote: jQuery UI 1.5.3 is only compatible with jQuery 1.2.6. In order to use jQuery UI with jQuery 1.3+, you'll need the latest preview release1.6rc6. It is compatible with 1.3 (but not 1.2.6), and the final release is scheduled for tonight. See http://blog.jquery.com/2009/01/30/jquery-ui-16rc6-help-us-test/ Also note, there is a dedicated mailing list for jQuery UI help: http://groups.google.com/group/jquery-ui Thanks. - Richard On Mon, Feb 2, 2009 at 11:26 AM, Tom Shafer tom.sha...@gmail.com wrote: I am using sortable and using the update feature to post the order $(#2).sortable({ //connectWith: [#homePage,#acquire,#build], items: li, opacity: 90, revert: true, placeholder: sortHelper, activeclass: sortActive, hoverclass: sortHelper, dropOnEmpty:true, update: function(element, ui) { $.post(addLinks.php,{ step:'update',order:$(this).sortable (serialize)}); } }); it seems that update doesnt work after i upgraded to jquery 1.3.1 i also upgraded jquery ui to 1.5.3 as well as sortable I can drag and drop and do everything I used to be able to do with 1.2.6. I upgraded to take advantage of the new live function for event delegation What could of changed or what I am i missing to make update work Thanks Tom
[jQuery] Re: sortable update problem
On Feb 2, 12:32 pm, Richard D. Worth rdwo...@gmail.com wrote: jQuery UI 1.5.3 is only compatible with jQuery 1.2.6. In order to use jQuery UI with jQuery 1.3+, you'll need the latest preview release1.6rc6. It is compatible with 1.3 (but not 1.2.6), and the final release is scheduled for tonight. See http://blog.jquery.com/2009/01/30/jquery-ui-16rc6-help-us-test/ Also note, there is a dedicated mailing list for jQuery UI help: http://groups.google.com/group/jquery-ui Thanks. thanks i appreciate it - Richard On Mon, Feb 2, 2009 at 11:26 AM, Tom Shafer tom.sha...@gmail.com wrote: I am using sortable and using the update feature to post the order $(#2).sortable({ //connectWith: [#homePage,#acquire,#build], items: li, opacity: 90, revert: true, placeholder: sortHelper, activeclass: sortActive, hoverclass: sortHelper, dropOnEmpty:true, update: function(element, ui) { $.post(addLinks.php,{ step:'update',order:$(this).sortable (serialize)}); } }); it seems that update doesnt work after i upgraded to jquery 1.3.1 i also upgraded jquery ui to 1.5.3 as well as sortable I can drag and drop and do everything I used to be able to do with 1.2.6. I upgraded to take advantage of the new live function for event delegation What could of changed or what I am i missing to make update work Thanks Tom
[jQuery] live and plugins
How would I make live work with plugins? With the livequery plugin i used $('.text-edit').livequery('click', function() { akedit(save_url, options); }); akedit is a not a jquery function. How would I make a plugin work with this Thanks, -Tom
[jQuery] Re: live and plugins
no your right, i have no idea what i was thinking. I got it working Thanks though On Feb 1, 9:31 pm, Mike Alsup mal...@gmail.com wrote: How would I make live work with plugins? With the livequery plugin i used $('.text-edit').livequery('click', function() { akedit(save_url, options); }); akedit is a not a jquery function. How would I make a plugin work with this It should work the same way (unless I misunderstood your question): $('.text-edit').live('click', function() { akedit(save_url, options); });
[jQuery] jquery fadeto
I have the following li. I am trying to make it so when you hover over the first a and all of the child ul with the class of sub fadeTo will come to full opacity. When you mouseout it changes opacity again. Here is what I have come up with. li class=parent first id=parent1a href=aboutAbout Us/a ul class=sub id=sub1 li id=lisub1a href=valuesOur Values/a/li li id=lisub2a href=teamOur Team/a/li /ul /li $(#parent1).find(a:first + ul).mouseover(function() { $(#firstImage).fadeTo(slow,.99); }); $(#parent1).find(a:first + ul).mouseout(function() { $(#firstImage).fadeTo(slow,0.33); }); I have it working with a:first. I just need it to work on both the a, and the ul, I have achieved something like this with all the a's but it fades in and out more than once when using this method. Any suggestions?
[jQuery] move and resize window according to parent window position
Does anybody have a way to move a popup window so that it is always centered over the parent window. I am having trouble figuring this out. Thanks, Tom
[jQuery] apples webclip feature in jquery
I am wanting to write something like apples webclip feature in safari for jquery, I am trying to figure out where the best place to start is. Does anyone have any ideas? Thanks, -TJ
[jQuery] Re: apples webclip feature in jquery
In safari 3 there is a webclip feature to make a widget for dashboard http://www.apple.com/pro/tips/webclip.html I am trying to make this in javascript and would like yo use jquery On Sep 17, 10:54 am, Andy Matthews [EMAIL PROTECTED] wrote: Could you elaborate? What is this webclip of which you speak? -Original Message- From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Tom Shafer Sent: Wednesday, September 17, 2008 11:41 AM To: jQuery (English) Subject: [jQuery] apples webclip feature in jquery I am wanting to write something like apples webclip feature in safari for jquery, I am trying to figure out where the best place to start is. Does anyone have any ideas? Thanks, -TJ
[jQuery] post data response problem
I am getting a data response from post in the form of variable1 | variable2 I am having trouble splitting this and applying the results to where its needed. $.post($(this).attr(href)),{}, function(data) { update = data.split('|'); $(update[0]).replaceWith(update[1]); }; return false; Thanks
[jQuery] $.post callback problem
i am trying to use data i am getting back from $.post but I am not able to get the function with the data in it to work $(a.rater).click(function(event) { $.post($(this).attr(href)), function(data) { update = data.split('|'); $('#'update[0]).replaceWith(update[1]); }; return false; } ); i also tried $(a.rater).click(function(event) { $.post($(this).attr(href)), function(data) { alert(+data); }; return false; } ); any suggestions?
[jQuery] jquery.livequery with with variables
i got livequery to bind but i need to be able to pass a variable to it lets say i have a function like deleteitem(id) how can i make livequery use this function with the variable i tried this $(li).livequery(click, deleteitem); but i get a syntax error deleteitem( how would i do something like this thanks
[jQuery] Re: remove dynamically placed dom element
im not exactly sure what i would be listening for, i get the error in firebug that deleteitem doesn't exist. I understand the concept of how to use on other elements but im not sure how this would be used on my submit function On Jul 13, 11:17 pm, Kevin Pepperman [EMAIL PROTECTED] wrote: For dynamicly loaded elements you will need to use a plugin. I suggest the 'listen' plugin. Refer to the FAQ for more information. http://docs.jquery.com/Frequently_Asked_Questions#Why_do_my_events_st...https://mail.google.com/mail/#inbox/11b1f57192f17027 On Sun, Jul 13, 2008 at 9:46 PM, Tom Shafer [EMAIL PROTECTED] wrote: I am using this code to add a new item to a list $(#addLinks).submit(function() { $.post(addLinks.php,{ step:'addLink',title:$ ('#title').val(),url:$('#url').val(),pageID:$('#pageID').val()} , function(data) { $('#'+$('#pageID').val()). append(li id='link_'+data+a href='javascript://' id='delete' onclick='deleteitem(+data+); return false;'img src='img/delete.gif' //ah1+$('#title').val()+/h1p+$ ('#url').val()+/p/li); $('#link_'+data).effect(pulsate, { times: 3 }, 1000); }); return false; }); as you can see i am adding a href='javascript://' id='delete' onclick='deleteitem(+data+); return false;'img src='img/ delete.gif' //a to delete the newest dom element. this works on page refresh but I would like it to work right after someone added the dom element here is what i am using to delete data from the database and the element that goes along with the delete item function deleteitem(id) { $(function() { $.post(addLinks.php,{ step:'deleteLink',linkId:+id}); $('#link_'+id).remove(); }); } $('#link_'+id).remove(); removes the item after a page refresh. How can it the element be removed without a page refresh after being added thanks -tom -- Fred Allen - Television is a medium because anything well done is rare.
[jQuery] using live query howto
i am trying to use live query to bind a click to a href on a form submit $(#addLinks).submit(function() { $('#addLinks') .livequery('onclick', function(event) { deleteitem(); }); $.post(addLinks.php,{ step:'addLink',title:$ ('#title').val(),url:$('#url').val(),pageID:$('#pageID').val()} , function(data) { $('#'+$('#pageID').val()). append(li id='link_'+data+a href='javascript://' id='delete' onclick='deleteitem(+data+); return false;'img src='img/delete.gif' //ah1+$('#title').val()+/h1p+$ ('#url').val()+/p/li); $('#link_'+data).effect(pulsate, { times: 3 }, 1000); }); return false; }); im not sure where i should put it, any help would be appreciated thanks -tj
[jQuery] remove dynamically placed dom element
I am using this code to add a new item to a list $(#addLinks).submit(function() { $.post(addLinks.php,{ step:'addLink',title:$ ('#title').val(),url:$('#url').val(),pageID:$('#pageID').val()} , function(data) { $('#'+$('#pageID').val()). append(li id='link_'+data+a href='javascript://' id='delete' onclick='deleteitem(+data+); return false;'img src='img/delete.gif' //ah1+$('#title').val()+/h1p+$ ('#url').val()+/p/li); $('#link_'+data).effect(pulsate, { times: 3 }, 1000); }); return false; }); as you can see i am adding a href='javascript://' id='delete' onclick='deleteitem(+data+); return false;'img src='img/ delete.gif' //a to delete the newest dom element. this works on page refresh but I would like it to work right after someone added the dom element here is what i am using to delete data from the database and the element that goes along with the delete item function deleteitem(id) { $(function() { $.post(addLinks.php,{ step:'deleteLink',linkId:+id}); $('#link_'+id).remove(); }); } $('#link_'+id).remove(); removes the item after a page refresh. How can it the element be removed without a page refresh after being added thanks -tom
[jQuery] jquery form multiple php variables
Hi, I am trying to use the jquery form plugin and i have 3 form fields i need to go to php and come back and be inserted into a list. I am having trouble getting more than 1 php variable to return. here is the code example i am using $('#addLinks').ajaxForm({ // dataType identifies the expected content type of the server response dataType: 'json', // success identifies the function to invoke when the server response // has been received success: processJson }); function processJson(data) { // 'data' is the json object returned from the server alert(data.message); } and the php ?php echo '{ message: ' . $_POST['message']. ' }'; ? How can i return more than 1 variable and specify what returns where? I am very confused on this thanks
[jQuery] jquery form multiple php variables
Hi, I am trying to use the jquery form plugin and i have 3 form fields i need to go to php and come back and be inserted into a list. I am having trouble getting more than 1 php variable to return. here is the code example i am using $('#addLinks').ajaxForm({ // dataType identifies the expected content type of the server response dataType: 'json', // success identifies the function to invoke when the server response // has been received success: processJson }); function processJson(data) { // 'data' is the json object returned from the server alert(data.message); } and the php ?php echo '{ message: ' . $_POST['message']. ' }'; ? How can i return more than 1 variable and specify what returns where? I am very confused on this thanks
[jQuery] jquery ajax post not working
I am trying to use ajax post to simply send a form field to php and return it to a div Here is what I have $(document).ready(function(){ $(#addLinks).submit(function() { $.ajax({ url: 'addLinks.php', type: 'POST', data: {url: $(#url).val(),title: $ (#title).val() }, error: function(){ alert('Error adding link'); }, success: function(data){ $(#contentcol4).append(data); } }) }); }); the php file contains ? echo $_POST['url'];? i keep getting a error of This XML file does not appear to have any style information associated with it. The document tree is shown below. im not sure what to do, I am new to this Thanks
[jQuery] thickbox moves underlying div in ie
When a state is pressed on my example. Thickbox opens but the underlying div moves to the left, but only in ie. Is there anyway to fix this? http://thebattalion.tv/firehouses.php Thanks -TJ
[jQuery] Re: disable tooltip plugin upon thickbox call and enable when thickbox is closed
Well it seems to be a safari only issue. I wonder why that is. Thanks anyway -TJ On May 26, 10:56 pm, Su [EMAIL PROTECTED] wrote: Be more specific? I don't see this in my copies of IE6 or Fx2. On 5/26/07, Tom Shafer [EMAIL PROTECTED] wrote: I have a page where you select a state and the tooltip plugin displays the states name. When you click on it thickbox appears with a list of states. Now when you hover around thickbox the tooltps show up. How can i prevent this from happening. I tried setting the z-index of the elements. Here is the problem page. http://www.thebattalion.tv/dev/firehouses.php -Tom Shafer
[jQuery] Re: jqgrid and php
Thanks. I wasnt sure what those params woudl be. Thanks -TJ On May 25, 5:09 am, Tony [EMAIL PROTECTED] wrote: Hi Tom, You must calculate this values by hand. I personaly use a exelent adodb library which returns this values from the resulting query. In your case: To the server are passed 4 parameters, that you must have attention. page - the requested page rows - the number of rows, that the server must return sidx - the culumn that must be sorted sord - the sort order Having this you must first calculate haw many rows are returned from the query - i.e use a count(*) function - let this is variable $mycount The total number of pages is (fill total tag with this value) : $mycount/rows - (round this value). If the query return data you must fill the tag page with the requested page parameter. As for the LIMIT in MySql - this can be calculated easy You reqest by example page 5, then you request must end with 5*rows The begining records are rows*(5-1) + 1 records or 4*rows + 1 By the way I have add some additinal features - subgrid. Have fixed some bugs. This will be available next week Regards Tony
[jQuery] load thick box within ajax load
I am using the jquery load function function loadContent(id) { $(#bioscontent).load(grabbios.php?id=+id+); } and I am wondering how I can make thickbox work inside of it. When i try It just pushes the loading ar to the bottom of the page. Here is the page I am using it on. http://www.thebattalion.tv/dev/bios.php I am trying to make it popup to play a flash movie. Thanks -TJ
[jQuery] simple div with scrollbar plugin
I am in need of a simple div with scrollbar plugisn. I am not quite sure how to write one. Is there one out there? Thanks
[jQuery] Re: jcarousel safari
That doesnt seem to work. Is there any other way. -TJ On May 15, 11:14 pm, Klaus Hartl [EMAIL PROTECTED] wrote: Karl Rudd wrote: I haven't looked at the page but I'll wager it's one of Safari's lazy update type problems. Sometimes you change the styling of an object and it doesn't update till it gets an actual change in the DOM. You can try putting the following somewhere after the carousel is built: if ( $.browser.safari ) $('span/').appendTo( section ).remove();// force redraw Karl Rudd Ah, Karl, thats interesting! I have the same problem and had no clue what to do to fix it. Will try it out when I'm getting to the office! That would be just in time... :-) -- Klaus
[jQuery] jcarousel safari
In safari I have to redraw the page in order for it to work. Like resize it or something. It has to be redrawn so I can use the arrows. Anybody else have this prob? -TJ
[jQuery] ajax and links
is it possible to have the url and the data come from the link href using the ajax funtions in jquery?
[jQuery] Re: jquery page jump
Yea that does work. Here is what I have on the onsubmit onclick=\$('#comment.$row2['feedbackID'].').slideToggle('slow');$ ('#scrollLink.$row2['feedbackID'].').ScrollTo(1500); return false;\ please note that this came from php On Apr 14, 6:26 pm, Allan Mullan [EMAIL PROTECTED] wrote: You need to do an onclick=return(false); to prevent this... Allan Tom Shafer wrote: how do I prevent the page from jumping back to the top when calling scrollto from the interface plugin http://dev.unfetteredpress.com/story/Chavez_to_shut_down_opposition_TV# click on add comment
[jQuery] custom selecters
Hi, i need to be able to find all elements with a div id of something like divname plus some randmom number, each div id will be like this, so something like divname324 or divname453 so how can I select all divs with a name divname plus some random numbers $(#divname + random number).ajaxForm({ target: '#commentFormOutput', success: processcommentForm }); Thanks -TJ
[jQuery] jquery form plugin
I am trying to return html after the form has been processed. I get it to work with plain text such as echo '{ message: Thanks }'; but html doesnt seem to want to work. Any thoughts?
[jQuery] Re: jquery form plugin
Yea I am using json. http://dev.unfetteredpress.com/story/Chavez_to_shut_down_opposition_TV click your turn and you can reply, the data is inserted into the database it just wont come back with the html message i wouls like Thanks, -TJ On Apr 12, 7:22 pm, Mike Alsup [EMAIL PROTECTED] wrote: Do you have the dataType set to 'json' by any chance? Can you post a sample page that shows the problem? Mike On 4/12/07, Tom Shafer [EMAIL PROTECTED] wrote: I am trying to return html after the form has been processed. I get it to work with plain text such as echo '{ message: Thanks }'; but html doesnt seem to want to work. Any thoughts?
[jQuery] Re: jquery form plugin
oh, ok cool i did not know that. Thank you. -TJ On Apr 12, 7:46 pm, Mike Alsup [EMAIL PROTECTED] wrote: Tom, The target and dataType options can not be used together. If you must use json then you need to process the response yourself. Otherwise you can just remove the dataType option and return html from the server and the target will be updated for you. Mike On 4/12/07, Tom Shafer [EMAIL PROTECTED] wrote: Yea I am using json. http://dev.unfetteredpress.com/story/Chavez_to_shut_down_opposition_TV click your turn and you can reply, the data is inserted into the database it just wont come back with the html message i wouls like Thanks, -TJ On Apr 12, 7:22 pm, Mike Alsup [EMAIL PROTECTED] wrote: Do you have the dataType set to 'json' by any chance? Can you post a sample page that shows the problem? Mike On 4/12/07, Tom Shafer [EMAIL PROTECTED] wrote: I am trying to return html after the form has been processed. I get it to work with plain text such as echo '{ message: Thanks }'; but html doesnt seem to want to work. Any thoughts?
[jQuery] Traversing the dom selecting ever other dom
I was wondering how I can traverse through the dom and start at a div and then select every other div until i want it to stop so that I may add a class to it. Any Ideas? Thanks Tom
[jQuery] Re: blockui timeout
thanks mike, im getting the hang of this. $this is your friend im learning On Apr 3, 6:32 am, Mike Alsup [EMAIL PROTECTED] wrote: Tom, Just add the timeout after you've called block(). $('a.respond').bind('click', function() { var $el = $(this); $el.prev('div').block('h1Please a href=\login\Login/a to submit your opinion./a/h1',{ border: '3px solid #a00'}); setTimeout(function(){ $el.unblock(); }, 5000); return false; }); Mike PS: Thanks Erik! On 4/3/07, Tom Shafer [EMAIL PROTECTED] wrote: Thanks guys, I got rid of the function and using this. $('a.respond').bind('click', function() { $(this).prev('div').block('h1Please a href=\login\Login/ a to submit your opinion./a/h1',{ border: '3px solid #a00'}); return false; }); so wouldnt I need to chain the settimeout onto this and set it to call the function $.unblockUI? On Apr 2, 11:33 pm, Erik Beeson [EMAIL PROTECTED] wrote: Your setTimeout syntax looks a little off. Maybe: setTimeout(function() { $el.unblock(); }, 5000); --Erik On 4/2/07, Mike Alsup [EMAIL PROTECTED] wrote: Tom, If you're still using a function to block, it's something like this: function blockElement(id) { var $el =$('#'+id); $el.block(); setTimeout(function() { $el.unblock(); 5000 }); } On 4/2/07, Tom Shafer [EMAIL PROTECTED] wrote: How could I use settimeout on block so that blockui will goway after a certain amount of time?