Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5

Thread: HTML or ASPX?

  1. #1
    Regular Coder
    Join Date
    Feb 2003
    Location
    South Africa
    Posts
    251
    Thanks
    0
    Thanked 0 Times in 0 Posts

    HTML or ASPX?

    I am currently developing an image gallery site similar to www.thunda.com

    My site is template driven, so if i change my template file, the site look and feel will change.

    Looking at thunda.com, after choosing a province, then clicking on "pics", then selecting any event, a list of thumbnails appear - this page is an HTML page. I assume that when they uploaded their images, the page was dynamically created.

    These images could be displayed this way, or using an aspx page which fetches image information from the database every time the page is viewed.

    Currently i am using the latter option, but it seems a bit slow - i would imagine that the static html page would load faster because of no server side interaction.

    Performance is a major concern with this site - what are my best options? Should i dynamically create an html file for each set of images i upload, or should i try and optomise my aspx page and display the images directly from the database?

    Please let me know if i am being unclear about anything...
    Bypass your proxy and get anonymous internet surfing FREE!

  • #2
    Regular Coder
    Join Date
    Oct 2004
    Location
    In front of this computer. (Where else?)
    Posts
    442
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Couldn't view ur site. It's censored by our firewall until after work. Anyway, to your question, I think it depends on how much space you've got. How large is the HTML file you want to create? Multiply the size of the HTML file by how many sets of images you'll be uploading.
    Then weigh that with the amount of traffic you'll be having on that particular page. You will get a better idea.
    It's always better to do everything dynamically though, and use aspx. Don't know aspx ... yet, but isn't it supposed to have better performance than classic ASP?
    Tomorrow is the first day of the rest of your life... What have you done today?
    Tutorials
    Web: w3schools, htmldog General tips: Hardware, Networking

  • #3
    Senior Coder
    Join Date
    Apr 2003
    Location
    England
    Posts
    1,192
    Thanks
    5
    Thanked 13 Times in 13 Posts
    just dynamically create it and set the cache controls on it so that it only generates it if it wasnt loaded in the last x minutes or whatever

    i think you can also set them so that it caches it differently for each querystring (so it only re-generates it if the time has expired for that querystring)

    i cant really remmember much about this, its all in the @ stuff at the top but i only ever used it once and it was for generating an image, and im not too good on asp.net

    edit: also make sure you write your code in the most efficient way possible.. no offence but if you have to ask about efficiency, you probably arent

    this involves keeping opjects open only as long as they are needed etc, using getrows to populate a 2d array instead of using movenext etc
    Last edited by ghell; 01-28-2005 at 03:36 PM.

  • #4
    Regular Coder
    Join Date
    Aug 2002
    Location
    Texas
    Posts
    287
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Good advice given so far. I would definitley choose the aspx route - just store the path to the image in the database and use that to load the image plus whatever else onto the page.

    Probably your bottleneck in any case will be the physical size of the images.
    If you have a page of thumbnails, be sure that you have them actually stored as thumbnails and aren't simply large image constrained by height and width html attributes.

    Here is an example of such a thing done with PHP. .NET also allows you to resize images in such a way also - http://www.tcdesign.net/FarGalleries/index.php

    fv

  • #5
    Regular Coder
    Join Date
    Feb 2003
    Location
    South Africa
    Posts
    251
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks all for your replies - I have infact already implimented fragment caching which does drastically increase performance on the aspx page. I have unlimited storage on my server, so space is not an issue. The thunmbnails i am displaying are actual thumbnails which are generated when the images are uploaded through my content management system. Dont worry, no offence taken ghell - I would like to think i am quite efficient in my code though - I just asked the question because i am unsure about performance of .net under stressful conditions of high traffic... I think for now i will stick to the dynamic route, and later consider static page creation if performance problems arise...

    Thanks again!
    Bypass your proxy and get anonymous internet surfing FREE!


  •  

    Posting Permissions

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