Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7087697
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T07:42:21+00:00 2026-05-28T07:42:21+00:00

I’m designing a single page website. All the sections to the site pop up

  • 0

I’m designing a single page website. All the sections to the site pop up modally in DIV elements, so it never leaves the actual browser page. Initially I have all the sections hidden with css using “display:none”, and the navigation reveals and hides them accordingly.

Now I’ve come to putting together the portfolio section, I’m starting to wonder whether it would be best to use AJAX for each portfolio item, as they include larger images. Is there any rough guide to what’s a sensible limit for preloading? If all the items were preloaded, the HTML file would look quite monstrous.

I realise this is a bit of a general question and it feels like preloading everything is a bad idea but I don’t want to go on a hunch. I’m not quite sure what sort of resources are taken up with the user’s computer when elements are set to “display:none” (e.g. Is it a RAM issue?).

Cheers! 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T07:42:22+00:00Added an answer on May 28, 2026 at 7:42 am

    As @Digbyswift mentioned, having one large HTML file with lots of elements increases the page size, which has an impact the overall load time.

    For older browsers, the number of elements on the page had a _much_more noticeable effect, but you would have to get in to the 10s of thousands of elements range to start hitting the ceiling.

    For modern browsers, you don’t have as low of an element-count ceiling, so you should be fine there, but again, if you are doing a lot of javascript interaction with the elements, it will slow down less powerful clients, such as mobile devices.

    The biggest trade off you are dealing with, in my opinion, is that by having one much larger page instead of a bunch of individual calls, you are effectively trading size of a single server response with the number of smaller responses needed. Depending on your specific case, it may be a beneficial overall trade, or it may not.

    I would say that you need to test the differences it makes and base your decision on that. One thing that will affect this are using compression on the responses (aka. GZip or Deflate).

    Also, for the “portfolio”, you mentioned that there are lots of large images. Personally, I would probably not have the actual <img /> tags in the HTML for that section to prevent the browser from loading all of it initially and instead load the images in as needed by writing the elements in with javascript as those images need to be displayed. There are a number of techniques to do this, any you can add in more smarts around when the images get loaded, but reducing those large server calls will speed up the page a great deal. Likely even to the point that having one massive HTML page won’t be a performance hit and will likely make it faster.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Basically, what I'm trying to create is a page of div tags, each has
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I used javascript for loading a picture on my website depending on which small
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I have a text area in my form which accepts all possible characters from
I'm trying to use string.replace('’','') to replace the dreaded weird single-quote character: ’ (aka
I'm trying to create an if statement in PHP that prevents a single post

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.