SitePoint Sponsor

User Tag List

Results 1 to 8 of 8
  1. #1
    SitePoint Member
    Join Date
    Mar 2010
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Static pages and .htacess

    Hi all,
    I want to create arnd 10,000 static pages...
    say like www.example.com/record1 and www.example.com/record2 and each page has different content and the contents are in db..
    So my doubt is if i do it using .htacess and do and internal redirection like www.example.com/record.php?id=1 and www.example.com/record.php?id=2 is this considered as static pages?? is this the correct way of doin??

    Thanks in advance.

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,712
    Mentioned
    102 Post(s)
    Tagged
    4 Thread(s)
    What you're creating is a dynamic page, as the content of the page is dependent on the values contained in the querystring.
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  3. #3
    SitePoint Member
    Join Date
    Mar 2010
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by pmw57 View Post
    What you're creating is a dynamic page, as the content of the page is dependent on the values contained in the querystring.
    Yeah i get u i am doin a dynamic page, my representation was wrong.
    k then wat is the best way to create 10,000 pages like this?? I cannot change my url, it needs to be the same in any case. So wat is the best way of doin this other than htaccess?

  4. #4
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,712
    Mentioned
    102 Post(s)
    Tagged
    4 Thread(s)
    Why is htaccess a problem, and what is the issue with dynamic vs static?
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  5. #5
    SitePoint Member
    Join Date
    Mar 2010
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by pmw57 View Post
    Why is htaccess a problem, and what is the issue with dynamic vs static?
    Okay this the case. The site now works like this. it has a search box in its home page and if u search using that it goes to a search.php page. I have arnd 10,000 records. Now this the only way of seeing these records. But now, I want separate page for each record this is for SEO stuff and also will be useful for referencing, So i want a unique url for all my records and i wish to have the url it in that way. Thank you.

  6. #6
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,712
    Mentioned
    102 Post(s)
    Tagged
    4 Thread(s)
    htaccess can easily do that for you then.

    I'll see if we can get this thread in to the Apache Configuration forum, because that is where the htaccess experts reside.
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  7. #7
    SitePoint Member
    Join Date
    Mar 2010
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by pmw57 View Post
    htaccess can easily do that for you then.

    I'll see if we can get this thread in to the Apache Configuration forum, because that is where the htaccess experts reside.
    Wow Thank you. i appreciate your help.

  8. #8
    Certified Ethical Hacker silver trophybronze trophy dklynn's Avatar
    Join Date
    Feb 2002
    Location
    Auckland
    Posts
    14,653
    Mentioned
    19 Post(s)
    Tagged
    3 Thread(s)
    vaira,

    What you're asking for is found in the mod_rewrite tutorial linked in my signature. Read it, ask questions (if you need to - the examples there should show you how to do this), post your attempt at mod_rewrite then I'll comment on it until you learn how it works and can implement it on your site.

    Paul,

    Thanks for the move.

    Regards,

    DK
    David K. Lynn - Data Koncepts is a long-time WebHostingBuzz (US/UK)
    Client and (unpaid) WHB Ambassador
    mod_rewrite Tutorial Article (setup, config, test & write
    mod_rewrite regex w/sample code) and Code Generator


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
  •