logo
down
shadow

Show/hide text doesn't work when targeting link within div


Show/hide text doesn't work when targeting link within div

Content Index :


Comments
No Comments Right Now !

Boards Message :
You Must Login Or Sign Up to Add Your Comments .

Share : facebook icon twitter icon

JQuery hide and show doesnt work


Tag : jquery , By : DK.
Date : March 29 2020, 07:55 AM
To fix this issue I have been trying to make a updateable grid.Which means i show an icon on mouseover on click of that icon i show a new row with textboxes and hide the previous row then there is a an icon which saves the values using ajax.On Successfull completion of this ajax save process i make a new row of the data and replace the previous row with textboxes. , Have you tried using on() instead of mouseover()?
E.g:
jQuery('[rel="innerRows"]').on("mouseover", function (){

    var spanId = jQuery(this).attr('spanid');
    jQuery('[rel="innerSpans"]').hide();
    jQuery('#edit_'+spanId).show();
 });

JQuery: show() and hide() targeting more than one div doesn't work?


Tag : javascript , By : lhoBas
Date : March 29 2020, 07:55 AM
I think the issue was by ths following , Its because, the way you have used the multiple-selector is wrong.
Try,
 $("#foo,#foo1,#foo2,#foo3").show();
 $(document).ready(function (){
    $("#state").change(function() {
       $("#foo,#foo1,#foo2,#foo3").toggle($(this).val() == "twoChoices");
    });
 });

Tag : javascript , By : JulianCT
Date : March 29 2020, 07:55 AM
this will help The purpose of classes is re-usability, if you want unique you can use ID. I suggest you to follow following pattern.
:id => "Identifier_ModelName_Id"

o/p => "Identifier_Question_15" 

Hide and show input doesnt work


Tag : javascript , By : Icyflash
Date : March 29 2020, 07:55 AM
Hope this helps I have the following code:
var getInput = document.querySelector('.search-form')
var screenWidth;
var getWidth;
var bodyDisplay;
var display;

window.onresize = function(event) {
    screenWidth = event.target.outerWidth;
};

function getCssProperty(elmId, property){
        var elem = document.getElementById(elmId);
        return window.getComputedStyle(elem,null).getPropertyValue(property);
}

function showInput(event) {
    event.stopPropagation();
    console.log(event.target.className);
    if(event.target.className == "search-field form-fluid") return;
    if(screenWidth === undefined){  //screenWidth is undefined but not null
     screenWidth = document.documentElement.clientWidth;
    }
    console.log(screenWidth ,"b")
    if(display === undefined && screenWidth > 500){ //display is undefined but not null
        getInput.style.display = 'inline-block';
        document.querySelector('.search-field').focus();
    display = true; //setting display true as a flag 
    } else {
    display=undefined; // making display undefined so that again on click if loop will execute
        getInput.style.display = 'none';
    }
}

document.getElementsByTagName('body')[0].onclick=function(event){
  console.log("body")
    display= true; // if true else loop in showInput will execute

  showInput(event);
};

Hide and Show Code doesnt work on other forms


Tag : chash , By : Lauren Kirschner
Date : March 29 2020, 07:55 AM
hope this fix your issue You have to use the same actual Form3Admin instance to Show it. Keep Form3Admin sa instance as a class variable and use that instance when you want to show it.
private void button2_Click(object sender, EventArgs e)
{
    this.Hide();
    sa.Show();
}
Related Posts Related QUESTIONS :
  • jquery toggle and fade in one function?
  • JQuery UI Tabs caching
  • Drag and Drop into another div and move in the div only using jquery
  • Links in rounded boxes? In ALL browsers (yep included IE8)
  • How to change the content of the Span using jQuery?
  • jQuery; combine user click and :checked
  • jQuery - Finding the element index relative to its container
  • jQuery .each() function. Resetting the index?
  • jQuery storing settings
  • Why does asp.net mvc form submits itself on button clicks when javascript function error?
  • Linking to non-home panel in JQTouch site
  • How to Edit jQuery Table Using CSS
  • Jquery hover triggers "mouse leave" without cursor leaving
  • DELETE http://localhost:8000/product/[object%20Object] 500 (Internal Server Error)
  • Comparing two string arrays and returning key of not found element using jquery
  • using jquery to change list items is changing all list items, when i want to only change one list item
  • Sending a Json data from my html page to a php
  • Click function to search a specific element in a Json object
  • Bootstrap 4 - Progress Bar Progression
  • how to deleted item materialize chips
  • jQuery - Hide non-active elements using filter()
  • Adding style to string table is not working
  • Github merge multiple files into single compressed master file
  • Replace characters in a field on page load
  • Unable to send data from Form to SQL database
  • If all divs have same style, remove element
  • How to click a jQuery Dialog button in TestCafe
  • Cannot reinitialise DataTable with Angular Datatable
  • How to add Class active on Click in Navbar
  • how to call fail method into jquery.get/post success method?
  • Slider with tabs
  • Jquery Get parent element from data function
  • Ho to put a new line in <p> tag in my jquery?
  • How can I use a text value as a mathematical operator?
  • DataTable columns values showing Only DefaultContent
  • JQuery select dynamically added elements
  • How to change an image source on hover?
  • How to bind jquery event to dynamically added multiple DOM elements?
  • How to get td values and store in array using Jquery?
  • How to add handler to dinamically created tr in JQuery?
  • How to Covert Html to PDF in Jquery?
  • Jquery before() and after() used to create a <div> container not inserting closing tags in after()
  • I want to delete previously added class
  • Open html page in same window after clicking on navlink
  • Datatable is not working when I populate table using smarty
  • How to change image based on the offset top of the content div
  • Find the index of table column with specific id
  • How to return value of $(window).resize()
  • How to optimize adding numerous elements dynamically into web page
  • Content slide down on top of page?
  • How to write if statement for when a specified option is selected in select tag in JQuery
  • HTML tags remove from textarea using jQuery
  • ShareThis not display properly when initially hidden
  • jquery - Bind datepicker event
  • How can I cause an element to move on mouse scroll using transform matrix?
  • How to add Custom summaries for autogenerated colums?
  • How to update table row with data from an array using jQuery
  • Cannot get the element in jQuery
  • How to search for two values in array at the same time?
  • Creating a floating document property control that is available in all tabs of Spotfire dashboard
  • shadow
    Privacy Policy - Terms - Contact Us © scrbit.com