Results 1 to 10 of 678

Hybrid View

  1. #1
    Join Date
    Nov 2003
    Posts
    1,987
    Plugin Contributions
    15

    Default Re: Quick Updates 1.3 ?

    Hi Chaddro,

    a problem with check boxes is that they only can be checked, not "unchecked".

    A checked checkbox may post a value of 1 to the next page.
    i.e.: $_POST['quick_updates_new']['product_is_call'] = 1

    But an unchecked checkbox does not post any data, and so it is the same as having no checkbox at all. That is why it can only switch on what is off, but not the other way around (I hope this explanation makes sense...).

    A way around this is to use 2 radio inputs (true/false or on/off or whatever). There are other ways to solve it of course, but I think using the radio inputs is the easiest in this case.

  2. #2
    Join Date
    Apr 2006
    Location
    Dark Side of the Moon
    Posts
    987
    Plugin Contributions
    1

    Default Re: Quick Updates 1.3 ?

    Quote Originally Posted by paulm View Post
    a problem with check boxes is that they only can be checked, not "unchecked".

    A checked checkbox may post a value of 1 to the next page.
    i.e.: $_POST['quick_updates_new']['product_is_call'] = 1

    But an unchecked checkbox does not post any data, and so it is the same as having no checkbox at all. That is why it can only switch on what is off, but not the other way around (I hope this explanation makes sense...).
    Hi Paul,

    Thanks for looking at this. I didn't know this about checkboxes. When you uncheck a checkbox, it doesn't POST anything? Hmmm... I don't have the code in front of me, but some of the extra efforts I saw around product_status is making sense.

    I was able to get the unchecking working, but then the form updated ALL the records on the page for the checkbox instead of just the one changed.

    I am using the "status" checkbox at my roadmap, but missing something. The original programmers added a lot of functionality to status (record filtering) on top of simply changing status. But even when I code it JUST like them, it isn't working.

    I think I am just missing something simple. Nothing like being this >< close, but just not getting it. Your radio button solution makes sense after looking at the regular product editing code. But I'd sure like to use the checkbox... :)

    well, back to the grind stone !

  3. #3
    Join Date
    Nov 2003
    Posts
    1,987
    Plugin Contributions
    15

    Default Re: Quick Updates 1.3 ?

    Quote Originally Posted by chadderuski View Post
    When you uncheck a checkbox, it doesn't POST anything?
    Exactly. This amazed me at first too, but when you think about it it does make sense after all. What value shoud it post when uncheked? And it works similar to radio inputs: only a checked radio input sends data.

  4. #4
    Join Date
    Oct 2006
    Posts
    8
    Plugin Contributions
    0

    Default Re: Quick Updates 1.3 ?

    First, I would like to say I really appreciate this Mod. It used to work for me but I can't figure out what caused this formatting problem. Here is my screen shot. Should I delete and re-install the mod?


 

 

Similar Threads

  1. Quick Updates
    By jayson.gurney in forum All Other Contributions/Addons
    Replies: 49
    Last Post: 1 Mar 2008, 11:08 AM
  2. Quick Updates 2.0*
    By Doodlebuckets in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 6 Jun 2007, 01:32 PM
  3. Quick Updates
    By tuckerm in forum Customization from the Admin
    Replies: 11
    Last Post: 16 Dec 2006, 11:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg