SitePoint Sponsor

User Tag List

Results 1 to 15 of 15
  1. #1
    SitePoint Enthusiast
    Join Date
    Oct 2001
    Location
    Alabama
    Posts
    91
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PHP pages .. do they get indexed?

    Do pages created ion PHP get indexed in search engines as well as html pages? I have searched, and don't see many .php pages in rankings. I am redesigning a site and want to do it in php, but I am not sure if the search engines will like the php.

    Any insite on this? And my apologies if this is a frequent question or something.
    Is this normal??? --

  2. #2
    SitePoint Addict LiveTronix's Avatar
    Join Date
    Sep 2001
    Location
    Vancouver
    Posts
    370
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    page.php - would get listed
    page.php?section=39 - does not get listed

  3. #3
    Wanna-be Apple nut silver trophy M. Johansson's Avatar
    Join Date
    Sep 2000
    Location
    Halmstad, Sweden
    Posts
    7,400
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    The question mark (?) acts as some form of "stop sign" for some search engines (Google does not have this problem, for instance)

    I would suggest learning how to do search engine friendly urls - it's not really hard. There is a great tutorial at PHPbuilder.

    Good luck!
    Mattias Johansson
    Short, Swedish, Web Developer

    Buttons and Dog Tags with your custom design:
    FatStatement.com

  4. #4
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Theres a better tutorial at sitepoint:

    http://www.webmasterbase.com/article/485/

    which covers 3 methods of doing it instead of 1.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  5. #5
    SitePoint Enthusiast
    Join Date
    Oct 2001
    Location
    Alabama
    Posts
    91
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thanks

    Thanks for the advice. Now I have been learning PHP, I am kinda hooked on it and didn't think about search engines. I will over the links.

    Thanks again all.
    Is this normal??? --

  6. #6
    SitePoint Zealot
    Join Date
    Mar 2001
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    After you make your URLs search engine friendly (and I recommend Aspen's article for learning how), should you resubmit your site to Google? or just wait for them to index it again?

  7. #7
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Resubmitting it won't make them index it any sooner. But then again Google does not penalize you at all for submitting so if you really want to it wouldn't hurt.

    Google does it's indexing usually at the beginning of each month - and they publish the results a month later.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  8. #8
    SitePoint Zealot
    Join Date
    Mar 2001
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the info.

    One last question. I used the PATH_INFO method to change my URLs. I noticed that if I append ".html" at the end of the URL (e.g., http://www.mysite.com/script.php/54/65/10.html) the page works fine. Should I do this? Will it help with indexing my site because it looks like a "normal" url?

  9. #9
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I haven't really experimented with adding .html

    I wouldn't think that it'd mess up search engines - but I can't know for sure. It would make it more "user friendly" to those less than Internet literature people.

    However if you are using the PATH INFO method I would suggest changing to method 3. Method 3 easily works with the path info method, in fact all it really requires is changing your links and adding a few lines to your .htaccess file.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  10. #10
    SitePoint Zealot
    Join Date
    Mar 2001
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I've tried method 3, but cant seem to get it to work. I created the .htaccess file as follows:

    <Files myfilename>
    ForceType application/x-httpd-php
    </Files>

    and uploaded it to my 'public_html' folder (in ASCII). Then I altered my links to eliminate the ".php" (e.g., www.mysite.com/myfilename/10/2).

    When I run the script, however, I get a 404 error.

    I didn't understand the drawback mentioned in the article for this method, so maybe my url is incorrect?

  11. #11
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the drawback of it is that your url's are slightly longer.

    However there is no reason why it shouldn't be working by what you've said.

    You should really check with your server administrator. They control what you can and can not do with .htaccess and if this isn't working perhaps that is the reason.

    To check you could change it to this.

    <Files test.html>
    ForceType application/x-httpd-php
    </Files>

    and then make a test.html, put some php in it, and see if it gets parsed as php
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  12. #12
    SitePoint Zealot
    Join Date
    Mar 2001
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    My (stupid) mistake...it works great. I didn't remove the .php extension from the file in question.

    Now, what is the syntax if you want the ForcedType to work on more than one file:

    <Files file1, file2, file3>
    ForceType application/x-httpd-php
    </Files>

    or do you have to create separate entries for each file:

    <Files file>
    ForceType application/x-httpd-php
    </Files>

    <Files file2>
    ForceType application/x-httpd-php
    </Files>

    Thanks for all the help.

  13. #13
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm not sure, I justed looked in my pocket reference but they didn't say either.

    I think its 1 for each however - this would be very easy to test of course.
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums

  14. #14
    SitePoint Enthusiast ericthehalfbee's Avatar
    Join Date
    Oct 2001
    Location
    Auckland, NZ
    Posts
    46
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Dynamically generated URLs by other methods

    I found this thread hugely helpful and managed to get methods 1 & 3 to work relatively easily

    I don't suppose anyone has any helpful similar information re asp, cfm etc?

  15. #15
    Serial Publisher silver trophy aspen's Avatar
    Join Date
    Aug 1999
    Location
    East Lansing, MI USA
    Posts
    12,937
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You can use the same principles as method 2 with CF and ASP if you have your own server.

    http://www.netmechanic.com/news/vol4/promo_no3.htm
    Chris Beasley - I publish content and ecommerce sites.
    Featured Article: Free Comprehensive SEO Guide
    My Guide to Building a Successful Website
    My Blog|My Webmaster Forums


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
  •