Results 1 to 6 of 6

Thread: Hide sortable lists.

  1. #1
    Join Date
    Jul 2007
    Posts
    40
    Thanks
    9
    Thanked 0 Times in 0 Posts

    Default Hide sortable lists.

    I have this site I am working on and it has a sortable list which has over 2000 entries:

    http://tivaelydoc.110mb.com/horror2.html

    As you can see, it lags beyond belief. So, what I am trying to do is hide all the entries except for 20, 50, or 100 but still have it retain all the entries.

    How would I accomplish this?

  2. #2
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    So you want to have all 2000 on the page, but only show 20?

    from a pure CSS standpoint, you could add display:none to any element that you don't want to show.

    What I would do is set everything to hidden, and then seletively go in and set 20 to show. Perhaps with css and markup like this:

    CSS
    Code:
    td { display:none }
    td.show { display:block; }
    HTML Code:
    <td class="show">This Will Show</td>
    <td>This Will Not</td>

    What I would really do in your situation is use some PHP and database to store all those entries. But I guess that's outside the scope of your question.
    Last edited by Medyman; 03-25-2008 at 12:04 AM.

  3. The Following User Says Thank You to Medyman For This Useful Post:

    tivaelydoc (03-24-2008)

  4. #3
    Join Date
    Jul 2007
    Posts
    40
    Thanks
    9
    Thanked 0 Times in 0 Posts

    Default

    Is there a tutorial on how to store all the entries with PHP?

  5. #4
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    Quote Originally Posted by tivaelydoc View Post
    Is there a tutorial on how to store all the entries with PHP?
    sure is...

    http://www.php-mysql-tutorial.com/

  6. #5
    Join Date
    Feb 2008
    Posts
    63
    Thanks
    2
    Thanked 8 Times in 8 Posts

    Default

    Hi,

    In one of my classes we learned about collapsible lists and we used javascript for the list. You could arrange them like you have them collapsing directors last names a-d or put them in alpha order collapsing by title a-d or somthing like that. But here ya go:

    (it's the first lists)
    http://www.sandysdesignline.com/webb...eek2part1.html

    Good Luck. Let me know if this works for you.

    Sandy

  7. #6
    Join Date
    Mar 2007
    Location
    Currently: New York/Philadelphia
    Posts
    2,735
    Thanks
    3
    Thanked 519 Times in 507 Posts

    Default

    Quote Originally Posted by sandyk3 View Post
    Hi,

    In one of my classes we learned about collapsible lists and we used javascript for the list. You could arrange them like you have them collapsing directors last names a-d or put them in alpha order collapsing by title a-d or somthing like that. But here ya go:

    (it's the first lists)
    http://www.sandysdesignline.com/webb...eek2part1.html

    Good Luck. Let me know if this works for you.

    Sandy
    The issue still remains that javascript isn't optimal for the kind of thing that the OP is doing. The performance, quite frankly, is horrible. PHP would be able to handle this way better than javascript will. Manipulation of data structure should generally be relegated by the server unless there is some good reason to handle it client side.

Bookmarks

Posting Permissions

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