473,513 Members | 2,601 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

.htaccess and mod_rewrite

is there a way that I can make my own file extension and have it load
as php?

from this:
example.com/something.php
to this:
example.com/something.extension

Oct 24 '07 #1
2 1293
On Oct 23, 11:04 pm, Lamer <Galat...@gmail.comwrote:
is there a way that I can make my own file extension and have it load
as php?

from this:
example.com/something.php
to this:
example.com/something.extension
You want something like this:

AddType application/x-httpd-php .foo

That will cause files with the .foo extension to be run through the
PHP engine.

Oct 24 '07 #2
Greetings, Lamer.
In reply to Your message dated Wednesday, October 24, 2007, 07:04:47,

Lis there a way that I can make my own file extension and have it load
Las php?

Lfrom this:
Lexample.com/something.php
Lto this:
Lexample.com/something.extension

Assume You are using PHP with Apache, take a look at Apache Filter SAPI
(php5apache2_2_filter.dll) and Filters reference manual on Apache website.
http://httpd.apache.org/docs/2.2/filter.html
--
Sincerely Yours, AnrDaemon <an*******@freemail.ru>

Oct 24 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
3678
by: Nel | last post by:
Just looking for some general advice on modifying the URL for php. I am using .htaccess to allow a web site to translate example.html to index.php?content=example (below) ErrorDocument 404...
15
5120
by: Taki Jeden | last post by:
Hello everybody Does anybody know why w3c validator can not get pages that use 404 htaccess redirection? I set up two web sites so that clients request non-existent urls, but htaccess redirects...
2
2825
by: Geradeaus | last post by:
I use htaccess to rewrite the url using the following rules : RewriteRule ^(+)/(+)/(+)?$ index.php?lang=$1&page=$2&id=$3 The only problem I have is when http://www.domain.com/admin is given,...
2
9241
by: jaanus | last post by:
Here we go... What I have been trying to do is to forward all http requests containing /cms/ to http://cms.mydomain.com/ example1: http://host1.mydomain.com/cms/init.php would be parsed from...
2
5993
helimeef
by: helimeef | last post by:
Hi. I'm having issues trying to get .htaccess make mod_rewrite work. I have mod_rewrite setup properly (it's in phpinfo()), but it just seems to not work. Right now I have two files, bob.html and...
9
4383
by: invertigo | last post by:
Hello, Im using this .htaccess file to rewrite my websites URL. Reason i try to do this is to make it more SEO friendly. Code: -------------------------------------------------------- Options...
4
6678
by: adnanjunk | last post by:
Hi, Having a little issue with .htaccess not working on windows server. I have clean url's setup using the htaccess file, working fine on linux server. I have researched for a while and found...
0
2078
by: AndyPSV | last post by:
Hello, I've got .htaccess file: RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule (.*) index.php It works properly on mine and...
4
4114
Dormilich
by: Dormilich | last post by:
Hi, is there a possibility to pass variables from .htaccess to PHP? I want to tell PHP, whether mod_rewrite is enabled (so I can use modified URLs in the navigation). what I've come up so far...
1
2041
by: gsherp | last post by:
I was wondering if there was anyway in the .htaccess file to access bash scripts. I want to do this because for the mod_rewrite configuration: RewriteBase /home/ { whoami } /www/ is there...
0
7259
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7158
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7380
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7535
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7098
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
1
5085
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3232
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
1
798
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
455
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.