Solved

htaccess url rewriting problem

Posted on 2006-07-21
2
202 Views
Last Modified: 2010-03-04
My customer is using MAMBO
Can anyone figure out why the indicated line does not work?
It seems to work when I remove the ReWriteCond and ReWriteRule.

Can you suggest a solution so that all these lines work together?

Here is the htaccess file:
----------------------------
<IfModule mod_rewrite.c>
 RewriteEngine On
 RewriteBase   /

 # This line is not working....it says FILE NOT FOUND...any ideas?
 RewriteRule ^hickory-creek.html?$ /index.php?property_id=17 [L]

 RewriteCond %{REQUEST_FILENAME} !-f
 RewriteCond %{REQUEST_FILENAME} !-d
 RewriteRule ^(.*) index.php
</IfModule>
----------------------------
0
Comment
Question by:dasher3000
2 Comments
 
LVL 16

Accepted Solution

by:
xDamox earned 500 total points
ID: 17162958
Hi,

Comment out the RewriteCond and bottom RewriteRule and just try this:

RewriteRule ^hickory-creek.html$ index.php?property_id=17 [L]



0
 

Author Comment

by:dasher3000
ID: 17184459
hi, thanks for the suggestion. it did not work.
we resolved this by creating seperate php pages for each property_id and just having a php include as the contents of the file.

<?php include("index.php?property_id=17"); ?>

we then added a field in the property database that is called "property_detail_page" that contains the name of the newly created php file that contains the correct include.

so when users search the properties database, that page is output into the results.

I know this sounds like a lot of extra work, but we are hoping that this will increase our potential for search engine placement, since each file will be named with a few important key words related to that property.

we are also including in the database some fields for page title and keywords so that the meta information will be unique for each property as well.

thanks again,
dasher
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Over the last year I have answered a couple of basic URL rewriting questions several times so I thought I might as well have a stab at: explaining the basics, providing a few useful links and consolidating some of the most common queries into a sing…
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

774 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question