No announcement yet.

Hide .php

  • Filter
  • Time
  • Show
Clear All
new posts

  • Hide .php

    Hi, i'm runnning a xampp apache server on XP Professional SP3 and i'm trying to hide the .php part of a url like on youtube.
    Go and watch a video on youtube, Now notice that there should be a .php after /watch and before ? but there isnt.
    now i can prove that youtube is .php by just adding in .php after /watch.
    Can anyone tell me how to do this to my server?
    I reckon its something to do with mod_rewrite
    Last edited by alexcomboy; 11th November 2008, 21:17.

  • #2
    Re: Hide .php

    This isn't really a security issue. You would be better off posting to an Apache or PHP mailing list.
    Gareth Howells

    BSc (Hons), MBCS, MCP, MCDST, ICCE

    Any advice is given in good faith and without warranty.

    Please give reputation points if somebody has helped you.

    "For by now I could have stretched out my hand and struck you and your people with a plague that would have wiped you off the Earth." (Exodus 9:15) - I could kill you with my thumb.

    "Everything that lives and moves will be food for you." (Genesis 9:3) - For every animal you don't eat, I'm going to eat three.


    • #3
      Re: Hide .php

      Moved to Misc forum.
      I missed this one.
      Technical Consultant

      MCITP(EA, SA), MCSA/E 2003:Security, CCNA, SNAF, DCUCI, CCSA/E/E+ (R60), VCP4/5, NCDA, NCIE - SAN, NCIE - BR, EMCPE
      "No matter how secure, there is always the human factor."

      "Enjoy life today, tomorrow may never come."
      "If you're going through hell, keep going. ~Winston Churchill"


      • #4
        Re: Hide .php

        The apache httpd.config file sets the pre-processor for each page type. If you wish you can set it to send to the php pre-processor by default.

        look for something like this

        <Files *.php>
        SetOutputFilter PHP SetInputFilter PHP LimitRequestBody 9524288
        and change *.php to pick up all files. Different apache setups may not have this as part of the main config so you may need to go look for it in includes.

        PS you will need to re-name all your files and look at how links are formed. Unix/Linux/BSDs etc have tools that can do this.