Is it possible to rewrite the root to a specific page?
I would like the visitor coming to http://www.domain.com to be automatically taken to http://www.domain.com/new-page.html
I have tried various things, but they don't work.
RewriteEngine On
Options +FollowSymlinks
RewriteCond %{HTTP_HOST}...
Hi,
We have a website that can be accessed using two different domains names.
Using the .htaccess file, is it possible to deliver a different CSS file depending on which domain name is used to access the website?
I am having difficulty getting this to work...
I have some code that I would like not to display on particular webpages. I have a line of PHP like this:
<?php if ( $_SERVER['REQUEST_URI'] !== "/" ) { ?>
html content
<?php } ?>
This works inasmuch as the HTML content is not displayed on the...
I have an existing website that will now be moved to a subdomain. I would like to use rewrite rules to redirect all of the requested pages to the subdomain apart from the index.html and requests that come to the website using just the domain name (without index,html)
I have got as far as...
I am using a small script for saving code snippets.
The script saves each snippet in a text file. It is adding escape characters to some of the code:
snippet:
if(strstr($HTTP_ACCEPT_LANGUAGE,"en")) {
and this is how it is saved in the text file:
if(strstr($HTTP_ACCEPT_LANGUAGE,\"en\")) {
How...
Hi,
Does anybody know of a plugin or tool that can can test my outgoing e-mails for a "spam score" before they are sent?
I use The Bat! e-mail client and the ideal solution would be a small service or plugin that can quickly test my outgoing e-mail and then stop the message from being sent if...
Is it possible to use the .htaccess file to specify IP addresses that are allowed to access pages, with all others being redirected using the mod_rewrite?
I have tried this (and a number of other combinations) but without success:
order deny,allow
deny from all
Allow from 10.20.30.40...
Hi,
Can anybody advise me whether it is possible to use an "if" statement to style a specific link when it appears on a page?
The link appears like this in the browser's source code:
<li class="level1 item9">
<a href="/br/link.html" class="level1 item9">
<span>Best Link</span>
</a>
</li>
I...
First, I hope this is the appropriate board for a RegEx query...
I have a small script that takes the input from a form textarea and tries to extract all of the e-mail addresses. It works very well and the output shows each e-mail address separated with a space.
Can anybody tell me how I can...
After the deployment of a website, I would like to periodically run a script to monitor specified directories and sub-directories for file changes. (I might also like to specify the file types by extension.)
My query is, can this be accomplished with PHP and if so, where should I start looking...
Is it possible to limit the number of requests that are made to a webpage in the course of a day based on IP address and some other information?
I have the following basic tracking script:
<?php
$agent = $_SERVER['HTTP_USER_AGENT'];
$uri = $_SERVER['REQUEST_URI'];
$ip =...
I am planning some site upgrades.
Currently, I have an index.php file that redirects visitors according to the language of their browser:
<?php
if(strstr($HTTP_ACCEPT_LANGUAGE,"en")) {
Header("Location: http://www.DOMAIN.com/000/?sLang=en");
}
elseif(strstr($HTTP_ACCEPT_LANGUAGE,"sv")) {...
Hopefully, somebody here can point me in the right direction...
I often use PowerGrep to search within files for a particular string. Usually, this is within .php and .css files. Sometimes, this means that I have to download (FTP) the entire site before I can use PowerGrep.
Does anybody know...
Can mod_rewrite be used to change the domain name in a url?
I have one domain hosted with a little space and another domain hosted with more space. I have a mod_rewrite rule on the first domain that re-directs everything to a sub-directory the second domain.
Now, I would like to know if it is...
Can mod_rewrite be used to change the domain name in a url?
I have one domain hosted with a little space and another domain hosted with more space. I have a mod_rewrite rule on the first domain that re-directs everything to a sub-directory the second domain.
Now, I would like to know if it is...
I think the Subject line is slightly cryptic...
I have a simple query that outputs the records from a table that have dates 'entered' after 2008-04-01:
SELECT * FROM table_user w
WHERE w.`entered` >= '2008-04-01';
I am a complete novice trying to learn to perform some queries on my database...
I have a simple 301 Redirect that redirects all traffic to a particular page to another on a different domain:
redirect 301 /subdir/index.php http://www.newdoain.com/subdir/index.php
It works fine, but I still need access to this page.
Is there a way to add to the redirect rule to exclude my...
I need to move a MySQL database created with MySQL 4.1.22 on PHP 5.2.3 to a different server with MySQL 3.23.58 on PHP 4.3.8.
Is it possible to convert the database to do this?
Alternatively, is there a way to export from the newer version in a format that the older version will accept?
Hi,
I'm sure this is relatively simple, but my search on the forum for the terms "include" and "variable" are probably too vague for me to find the answer.
I have a page with the following include:
<?php include("upcoming.php"); ?>
This works fine.
I would like to add a variable to the end of...
When I change a file's extension, I always receive the message,
"If you change a file name extension, the file may become unusable"
Does anybody know how to disable this message?
Thanks/
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.