www.webdeveloper.com
Results 1 to 7 of 7

Thread: treeview with js+php+mysql

  1. #1
    Join Date
    Mar 2006
    Location
    mumbai, india
    Posts
    17

    treeview with js+php+mysql

    hi there
    i want to build a treeview structure for my menu, like what we find in windows for menu display
    something like folder image and folder name, after clicking folder image/name it should display files under that
    i want to design it in php with the help of js
    i have managed to do it but it's static
    i mean i give filename and it displays those
    but what i want is,
    it should take that folder name, search in mysql database and display those filenames stored in database
    any help would be gr8ly appreciated
    thanx
    Edit/Delete Message

  2. #2
    Join Date
    Dec 2004
    Posts
    8,637
    The "proper" (old-school) method of doing this requires that you make each folder name into a link so that another request is sent to the server and, then, the server sends back the file listing for that folder. The alternative method (new-school) for accomplishing this same thing is to use the XMLHttpRequest object to call server-side code from your JavaScript. Search for it on Google.

  3. #3
    Join Date
    Nov 2002
    Location
    Nashua, NH
    Posts
    3,195
    These are not "old school" and "new school" ways.
    You have a basic accessible method that uses HTML + server side only and will work for any user agent and then you have an advaced JS driven interface to enhance human user experience in select browsers. Having only the latter creates inaccessible web site that is not indexed properly.
    Vladdy

    Working web site is not the one that looks the same in a few graphical browsers, but the one that adequately delivers its content to any device accessing it.

  4. #4
    Join Date
    Dec 2004
    Posts
    8,637
    hehehe some of these standards and accessibility freaks can be soooo touchy! Not that standards or accessibility is bad -- its just these freaks that can be a pain in the patootie.

    "Each to their own."

  5. #5
    Join Date
    Jan 2004
    Location
    Washington DC
    Posts
    1,107
    When was the last time you disabled javascript? I only disable it when someone has an annoying right-click blocker

    I think that accessiblity is in the eyes of the client, if they want a site that's fast and cheap, they get what they pay for. If they want it good and fast, they will have to pay for it done right. But, if they want it fast and cheap, it sure won't be that good. So, although we preach about accessibility, a client won't always pay you for the "good and fast" way, they would rather pay for the "fast and cheap" method where their end result is not all that good, making it very difficult to make every site accessible.
    Last edited by crh3675; 03-31-2006 at 10:25 PM.
    Bittersweet web development.

  6. #6
    Join Date
    Dec 2004
    Posts
    8,637
    Quote Originally Posted by gayatri
    any help would be gr8ly appreciated
    By the way... The combined use of JavaScript and the XMLHttpRequest object, I mentioned, has been dubbed "AJAX". You can search on that term, too -- if you like. Also, though it is in the name, XML is not required.

  7. #7
    Join Date
    Nov 2002
    Location
    Nashua, NH
    Posts
    3,195
    Quote Originally Posted by crh3675
    When was the last time you disabled javascript? I only disable it when someone has an annoying right-click blocker

    I think that accessiblity is in the eyes of the client, if they want a site that's fast and cheap, they get what they pay for. If they want it good and fast, they will have to pay for it done right. But, if they want it fast and cheap, it sure won't be that good. So, although we preach about accessibility, a client won't always pay you for the "good and fast" way, they would rather pay for the "fast and cheap" method where their end result is not all that good, making it very difficult to make every site accessible.
    I do not disable javascript, but SE bots to not have it to begin with. If you ignore SE bots for such functionality as navigation, you might as well keep your web site your HD

    As far all that "fast and good" stuff..... there is only one exception to "it-does-not-take-long-when-you-know-what-you-are-doing" rule, and web development is not it
    Vladdy

    Working web site is not the one that looks the same in a few graphical browsers, but the one that adequately delivers its content to any device accessing it.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles