Ajax/Javascript

    Date: 09/04/07 (Javascript Community)    Keywords: php, java

    I was never very good at JavaScript when I had to use it in school. It just annoyed the crap out of me.

    But for the project I'm working on, I need to incorporate some Ajax "Yummyness".

    I would appreciate any assistance you can give me in trying to solve the following problem.


    Our IT department has an online form that people fill out when they want to create a service request. It was put together in about 5 seconds because nobody had any time to think about it. Now that things have settled down a bit, I've been given the task of making it easier for people to fill out.

    For some reason, though, people insist on leaving certain fields blank, or just putting in trash data to get past our "You didn't fill this out!" validation, so in trying to make this as "Easy for the stupid" as possible, I'm adding a little calendar onto the page where the user just clicks the day and it populates the field (clicking the calendar date is the only way to populate the field, as it's been locked).

    Since this is an internal page, I decided to use the free Ajax calendar available at http://www.bmgadg.com/ajax_calendar.php as a platform to work from. I'm trying to add the "click the box and populate the form field" functionality, but I can't figure out how to a) get the information from the calendar to the form field and b) to do it without causing the entire page to refresh (and thus clearing all the data).

    Source Code available:
    Main Page
    JS Functions
    Calendar
    Calendar JS Functions

    The above files do not attempt to pull date information from the calendar and put it into the form. The calendar was next on my list of things to make work, and while I got the calendar to display and look the way I wanted it, it doesn't actually do anything other than look pretty.

    I'm completely lost in this final step. I really should just suck it up and try and understand JavaScript a bit better before attempting this sort of thing.

    Any suggestions on how to accomplish what I described earlier would be a godsend and earn you my undying adoration.

    Source: http://community.livejournal.com/javascript/140350.html

« Jquery Issue || Javascript to change nested... »


antivirus | apache | asp | blogging | browser | bugtracking | cms | crm | css | database | ebay | ecommerce | google | hosting | html | java | jsp | linux | microsoft | mysql | offshore | offshoring | oscommerce | php | postgresql | programming | rss | security | seo | shopping | software | spam | spyware | sql | technology | templates | tracker | virus | web | xml | yahoo | home