Passing HTML via JSON?
I am trying to pass some HTML code from an ASP page back into a JQUERY function called addlist but I can't get the syntax right with regards to writing out the html via ASP. if I dont Include html in my response.write then my function addlist works as it should. I am guessing this is in relation to ' or " ASP CODE Response.write ("{status:1,id:"&(rsProduct.Fields.Item("ID").Value)&",txt:'"&(rsProduct.Fields.Item("ProductName").Value)&" - <a href=""#"" onclick=""remove('"&(rsProduct.Fields.Item("ID").Value)&"');return
Superfish wordpress
Hi experts, I'm using superfish for my wordpress, but got a problem that I need your help to fix. http://fabuloussystem.com/category/product/radio In " Radio " category, it suppose to show only " Lincoln " but not all the post under Radio. The same thing at " Lincoln " category, it suppose to show only " walkie-talkie " but not FM701 which is under " walkie-talkie " category. The category flow as below: Product > Radio > Lincoln > Walkie-talkie > FM701 Anyone can help me on this? Appreciate it much!
The empty() function doesn't seem to properly complete its job
I have a site design that uses a 'content box' in the center of a page, into which different information is loaded as required, using calls like this, to clear the space first, then load the new content: $("#content_space").empty(); $("#content_space").load("18_prints.html"); This seems to work, in that the div does become 'empty', and the new content then appears. But 'under the hood', the previous content has not been erased, but is still there. When I watch the 'Activity Window' in Safari for
Better way to write this transversing statement?
Hello, I have this statement: $(this).closest("div.middle-box").next().next().next().next().children("div.comment-input-button").toggle("slow"); This works just fine I was wondering if there was a better way to write it though? Thanks! Randy
Problem with standalone jQuery API Browser (AIR)
FYI -- I have been unable to install the standalone API browser. On PC it just freezes and on Mac it says that it has a download problem.
Writing Ajax Form with IF ELSE statements
I'm writing an Ajax from for a project and I'm having a bit of a problem. When I click the submit button the form still goes to the sendmail.php page though I have return false Can someone take a look at this and tell me where I may have gone wrong... Please? $('#MyForm').submit(function(){ var subject = $(".subject").val(); var name = $(".name").val(); var email = $(".email").val(); var message = $(".message").val(); var pattern
ajax, how to detected error
Hi jQuery Users, i'm using the $ajax which works fine until I rename some of my files and the url in the $ajax is wrong. my problem is that the $ajax doesn't error and doesn't give me a chance to report to the developer that the URL supplied with the $ajax is wrong. is there a way to detect this? what am I missing? regards, Peter Wraae Marino
Tabs and floating sidebar
Hello, I have a page with a left floating sidebar and a main content div into which I am trying to place a JQueryUI Tabs widget. Seems that the widget header extends down to the length of the left floating sidebar. The only way to make this render as expected is levaing the sidebar empty. You can see it here: http://www.palomos.es Strange thing is: if I remove or set an invalid <!DOCTYPE html> declaration, IE8 renders it ok. Firefox won't render it ok, no matter what. Another sample of the same problem
Opposite of has()?
How to manupulate elements that has not some elements? For example, I need to take all divs that don’t have images: <div><img/></div> <div></div> ← I need to take this div <div><img/></div> If I needed divs with images, I would use $('div').has('img'), but what is opposite?
problem with image-map
I've got some code witch dosen't work. There ist no warning or error in FF and Opera. $('<area shape="poly" coords="' + coords + '" href="#" alt="' + x + '_' + y + '" title="(' + x + '|' + y + ')">').appendTo('#imgmap');Here is the HTM-code <map name="fields" id="imgmap"> </map> I hope someone is able to help me. excuse me für my bad english
Control contents in sliding effect
Hello there, First off i'm really happy with jQuery! Very nice stuff, glad i found it. Then my question. I'm making a site where i have multiple menu bars sliding up or down showing content. I'm wondering if there is a way to control the contents of the sliding div because now it slides up slightly aswell as the div gets closed (or opened), but i'd like it to stay where it is. So basicly i want the contents of the sliding div not to move when its animated, is that possible? Maybe with another jquery
Problem with attr() in Safari
Hi Guys I have a div as follows: <div id="div1" class="c1 test youtoo 3d"></div> alert($("#div1").attr('class')); When I get the contents of the attribute in firefox, it works fine but in safari it only returns the first selector (c1) only. Anyone know why this happens ?
When you add multiple handlers to handle an event what is the execution order?
I have some default code to handle the change event for input fields that I load for allow of my forms in the application. On some of the forms I add additional change event handler for certain input fields. What is the execution order for these handlers? I want my local handler to run before the default handler. Is there a way to accomplish this? Terry
A new TAB/AJAX menu without JQuery UI
Hey guys... I realized a new Tab Menu, without using jQuery UI! The content in each section is called using jQuery AJAX function .load() There's a Loader too! Hope you like it! Waiting for your comments
Show All / Hide All links for FAQ?
Hi Guys, I'm using a simple jQuery show/hide toggle effect for the FAQ on this page: http://www.buttecommunitybankproperties.com/resources/faq.php I would like to add Show All / Hide All links to the top and bottom of the page that will show and hide all answers at once. I'm stumped. Can anyone help? Many thanks. Vesper
parser error from json & jquery
I am writing a simple update php script. But the json is not working for the update.php. I am not familiar with json, can anyone help me on the json below? $items = rtrim($_POST['items'],","); $sql = "UPDATE service_table SET granted='1' WHERE id IN ($items)"; $total = count(explode(",",$items)); $result = runSQL($sql); $total = mysql_affected_rows(); header("Expires: Mon, 26 Jul 1997 05:00:00 GMT" ); header("Last-Modified: " . gmdate( "D, d M Y H:i:s" ) . "GMT" ); header("Cache-Control: no-cache,
jsonp request on same domain fails
Hi... ...I'm using jquery 1.3.2 and I notice that if I do a jsonp request on the same domain it fails without error: ex: this doesn't work: http://www.mysite.com/mypage.htm http://www.mysite.com/jsonp.php this works: http://www.mysite.com/mypage.htm http://mysite.com/jsonp.php I know that jsonp is used for crossdomain requests and this issue is not a real problem but I think that is strange... thanks Marco
Tabs problem in Chrome
I am using jQuery idTabs to create tabs. The page I'm doing this for is here . It works on FF, IE 6 and 7. Chrome fails to display correctly and just leaves everything jumbled up. Let me know if ya need anything else to know in order to help.
Loading javascript files dynamically.
Hey all, After reading a particular post I came up with some code to load javascript files dynamically. But I've got problems.. When the script element is dynamically added to the head section of html, i think that the document.ready event fires once again and therefore the code sort of runs twice. In the html page I call this method: function TestLoad() { $(document).ready( function() { alert('begin'); //this line is causing the problem $("script").appendTo("head").attr({src:'/js/test.js',
Help selecting next table rows div
Hi guys i was wondering if someone could help me! I have a table and when you click a row i'm trying to select the div inside the next tr I can get hold of the next tr using $(this).next() but i can't get the div! I tried $(this).next("div") but that didn't seem to work Cheers for any help Dom
Accordion Menu links not working
I followed a tutorial on here about Expanding Sliding Menu's or Accordion Menu's. Here is the script: $(document).ready(function(){ $(".Left #SideCategoryList ul#parent-cats ul:not(:first)").hide(); $(".Left #SideCategoryList ul#parent-cats ul:visible").hide(); $(".Left #SideCategoryList ul#parent-cats li h3 a").click(function() { $(".Left #SideCategoryList ul#parent-cats li ul:visible").slideUp("slow"); $(this).parent().next().slideDown("slow"); return false; }); $(".Left #SideCategoryList ul#parent-cats
Loading content question
I know this is a simple issue but I can't seem to wrap my head around it... Say I have a mysql table that is being updated with new records from multiple sources. I would like to create a page that will simply display the new records as they are posted to the database. Say the page can only display about 5-6 records at a time, so ideally the records would scroll from bottom to top...kind of like the credits at the end of a movie. (The effect isn't that important.) What would be the best way to accomplish
Calling all javascript/ajax expert opinions :)
I'm curious about the feedback from the jquery javascript/ajax community regarding issues developing what I would call an "all ajax" site. Meaning, a site that basically begins with a document, then all subsequent action takes place through ajax gets and posts. First note: I'm not concerned about end users that don't have javascript enabled. Second note: I'm not asking for feedback regarding usability/design. My question is regarding performance and overhead as the user continues to use the site
Return unique ID with jQuery.data(elem)
Before 1.4, it is possible to return an unique ID with jQuery.data(elem), now seems does not work. http://api.jquery.com/jQuery.data/ The new api must need a key, what is the key then? I just want an unique ID by inputing an element, why I need such a key? Thanks.
How do I combine jQuery object array??
I have two result. SelectableChildren: groupHead.nextAll(".SimpleButton") and SelectableChildren: groupHead.nextAll(".SimpleButton").next().children(".SimpleButton") I would like to combine them into one object so that I can bind a handle to them in one loop. $.each(combineResult, function(index, object){ ... }) I have to make them in one, so that I can pass it around. please help.
Will anything work in IE6?
I have been using jQuery for only a few weeks now, replacing all of my standard js in a massive Intranet PHP application with lovely and space-saving jQuery. However, I've been using FF to write and test code while the company standard is IE6. Nothing works in IE6 - nada, zip, zilch. It bugs out on the very first call to the js file and wants me to begin debugging. Am I correct in assuming that I'm going to have to go back to regular js? I'd love to get the company to upgrade to IE7 - I've not seen
Modal Dialog's Stripped Down
I've started using the jQuery Modal Dialog plugin recently, but I want to have full control over the dialog. I'm trying to look up how to build a modal dialog box with just html, css, and javascript (or jQuery), but all I can find is other plugins. Can someone explain to me the essential elements in creating a modal dialog from scratch?
AJAX content in tabs - need js to run on content
Hopefully the answer to this is something I have over looked. The content I am loading into my tabs is html via ajax. The pages being loaded have javascript (all jQuery) on them as they need to load as independent pages as well. These scripts are also in the head of the main (page they are being loaded into) page as some tabs are not loaded by ajax. How do I get the script to trigger every time the tab / content changes.
Find elements whos width was specified by CSS.?.
Is it possible to select the elements who's width was specified by CSS? It's easy if they specified it by the width attribute *[width]. If you look at each elements css('width') it shows what was specified or automatically generated (always something). Thanks
why won't it die()?
Why won't this work? $('#mainmenu li a').live('mouseout', function () { $(this).fadeTo('fast', 0.3); return false; }); $('#mainmenu li a').click(function(){ $(this).die('mouseout'); }); And how would I make it work?
illegal character?
Can anyone tell me why I am getting an 'illegal character' error on this line? $('#subsubclassdiv').html('<select name="sub_sub_class" id="sub_sub_class" onChange="getMaterials($('#itemclass').val(),$('#sub_class').val(),$('#sub_sub_class').val(),$('#p1').is(':checked'));"><option value="0">Select SubSubClass...</option>');
Moving a file input field
I have a set of web forms used to upload multiple files to a server. The first form (template) takes information shared between the files, and the remaining forms have the file information. What I am trying to do is, for each file, make a new form (final), copy the template form data into the final form, then copy the file input field into the final form, and then call an ajax upload. I've gotten everything but the file copy correct. Any suggestions on what I should do? Here is the code snippet:
Question about getting value from callback...
I have a callback function defined for AfterHide. options = $j.extend({title: "", closable: false, center: true, fixed: false, modal: true, afterHide: function() {var myobj = this.getContent();alert(myobj.html());} }, {}); var dialog = new Boxy("<div style=\"width: 580px; height: 495px;\"><?php print '<img src=/images/cat/ajaxlwhite.gif />'; ?></div>", options); Here's the html that's coming back <div> <div style="float: left; padding-left: 10px;"> <div id="storeName" style="font-size: 11px;"><b>Sacramento</b></div>
IE6/7 do not .show .hide divs, all other browsers work fine
Here's my issue, hoping someone can help. I have a page with 5 roundabouts on it showing pictures depending on a button click. Buttons would look like: DOGS CATS BIRDS FISH REPTILES So if you click Dogs, I want it to hide the roundabout for Cats, Birds, Fish, and Reptiles but show Dogs. This works perfectly in FF, Chrome, IE8, IE7, but if I view in compatibility mode or with an IE6/7 browser, all 5 roundabouts show and even if I hit the buttons, which fire the show/hide code, nothing
using height() and allowing overflow.
I'm using jquery height() function to make it so that a div inside my page fills the gap between the header and footer (which are fixed height) so that the entire page is fullscreen. However I want any content in that div to overflow:auto; When I set the css to overflow:auto; the div disappears totally. $("#col3_tab").height( contentH-$("#col3_content").outerHeight() );contentH is simply the sum height of the header and footer and #col3_content is a fixed height div above the div I want to be auto
Select option attribute selector issue in Firefox
Using jQuery 1.4.1 in Firefox 3.6 I'm working in a system that automatically inserts options into certain SELECT elements. I always know the text that is being inserted, but not necessarily the value. If I'm trying to get a certain option using the [text=] attribute, it returns null if I include the text in quotes in Firefox. e.g. var myindex = $('#fielddiv select[id="mc.route.stepstatus.step9"] option[text="Work Inprocess"]').attr('index'); If I leave the quotes off of the [text=] selector, it
IE 7 Receiving a Parse Error Calling a Web Service
I'm using 1.4.1 and I have two html files, the first one contains $(document).ready(function() { $('#recordHit').load("http://localhost/soapcall2.html"); }); the second file, soapcall2.html contains just the following (no <html/>,<head/> or <body/> tags) <script> var ServiceUrl = '/ws/'; var CreateSession = ServiceUrl + 'general.asmx?op=CreateUserSession'; var AddRecord = ServiceUrl + 'record.asmx?op=CreateRecord'; var TerminateSession = ServiceUrl + 'general.asmx?op=TerminateSession';
How to replace input tag with <p> tag
Hallo all. I need to replace all the input tag of a page with a <p> tag with inside the input value. I tried in this way var inputs = jQuery('input'); jQuery(inputs).each(function() { var val = jQuery(this).val(); console.debug(val); jQuery(this).append("<p>"+val+"</p>"); jQuery(this).remove(); }); The problem is that the <p> tag is appended inside the <input> and when i remove it i remove also the <p> just added. Any idea how
Vaga para Desenvolvedor Client-side no Rio Grande do Sul
Em setembro de 2009 iniciou-se uma empresa - Grifo - com foco em desenvolvimento Client-side com o objetivo ter um reconhecimento em excelência de código. Busca-se profissionais com bons conhecimentos em SEO, acessibilidade, usabilidade, javascript, jquery e performance. Também consideramos profissionais com bastante interesse em aprender. Perfil de profissional: - Pessoas dedicadas; - Pessoas sempre em busca de conhecimento; - Pessoas que querem o melhor para os projetos com os quais trabalham.
Good way to select the elements
Hi I have a doubt, Please clear me this doubt if some one have any idea. Is there any better way to use the selectors (div[id$=''] , div[id ^= ''] , div[id *= ''] ). I am using this way at so many places. I know this way of selecting the elements will be much expensive.Please let me know if there is any other better way. Note: I do not have the complete ID, thats why I am using this way. Please let me know if you have any way to use. example that I used: ("input[id$=reporter")
Next Page