is someone able to explain the format for using the #REDIRECT command? i'm confused about a couple of things:
1) in the example, #REDIRECT [targetpage] ... do i need to include the file extension?
2) how exactly do i trigger this re-direct link? i had assumed the following:
- create a new 1-line file called, "fileA"
- link to "fileA" from say, my home page
- "fileA" would automatically load the targetpage coded into the #REDIRECT command
i must be missing something because when i click on the link, my re-direct page doesn't lead anywhere -- i only see the 1-line code of the page i just created.
thx in advance ....
PS -- i'm not a programmer by any stretch so plz choose your words carefully
thx for this guys, but .. i've since discovered that the #redirect i was asking about is an internal command << not quite the result i was looking for.
however .. i am familiar with the html refresh and javascript options, BUT ...
am now trying to use the htaccess file and am having little luck. are either of you able to field some suggestions if i provide a little more detail? ...
yes - i've moved on to the htaccess file but that's not working either. it will redirect my page fine, but the affiliate link that i'm trying to hide still shows in the URL.
i'm using the same syntax that you used, david68 and am thinking that there must be some other attributes in some other files that ignore htaccess unless i set them accordingly. otherwise ... not sure why it isn't working ...?
by "Internal Rewrite," can i assume that you are talking about the htaccess file? then, what is the "External Redirect?" do i still use the htaccess for that?
i will give you a specific example of what i would like to accomplish:
1. i created a dedicated folder ("temp" with multiple sub-folders, each with their own affiliate link reflected in the sub-folder's index file
2. i want to redirect each subfolder's index page directly to the sales page without revealing my affiliate link in the URL
3. the syntax i have been using (with the htaccess from the "temp" folder):
redirect 302 /[filename] http://[affiliatelink]
the redirect works, but the affiliate link still displays in the address bar and everything i have read, including a video tutorial, shows the URL changing to the domain of the sales page (eg. www.productA.com)
if this syntax represents an "external redirect" and that's not what i should be doing, what would be the correct syntax for the "internal rewrite?"
An external redirect sends a code like "301" back to the web browser along with the URL of the new location where the content is now located. The browser then sends a new request for that new URL.
An internal rewrite takes requested URL "A" from the browser but then actually fetches the content from internal URL "B". The browser doesn't get to see the value for "B" and will never know that it exists.
URL "B" is directly accessible to users but should never be linked to from any of your pages, otherwise you create a Duplicate Content issue. In most cases where you rewrite A to B, you also need to redirect B to A. This does NOT cause a loop, because one is a redirect and the other is a rewrite.
it sounds like both produce similar results - even that BOTH methods will display the URL of site "B," which is what i want to see (not my affiliate link).
so, i am still unclear about the application of either (sorry - i'm slow).
what is the syntax for the internal rewrite?
"ch_mod" or "mod_rewrite"
URL "B" is directly accessible to users but should never be linked to from any of your pages, otherwise you create a Duplicate Content issue.
So ... does this mean that i can only refer to url "B" in my masking efforts?
In most cases where you rewrite A to B, you also need to redirect B to A. This does NOT cause a loop, because one is a redirect and the other is a rewrite.
i'm not getting my head around that. again, i'm not seeing the difference if both do the same thing.
i looked at your resource, formerskeptic (thx). however, i am already applying the exact redirect 301 syntax and as it's not giving me the desired results. redirect works, but affiliate link is displayed.
also, the section on "Hiding affiliate links using mod_rewrite" is a little vague to me (i'll need to brush up on that). it sounds to me like the thing to do is to use this syntax to redirect the contents of a folder to site "B" - which is what i'm wanting to do. i just thought that it could be done using "redirect 301." again, not getting what the difference is.
i hate to test your guys' patience, but are either of you able to specifically provide a syntax example to resolve my specific need from above (2 posts ago)?
"redirect" isn't working. do i need "ch_mod" or "mod_rewrite" or something else?
hopefully, it isn't too foggy but i can try to simplify if necessary.
The only other explanation to your problem, I think, would have to do with your host. If you're using a shared host, chances are they've probably put some kind of block on their (apache) config file to restrict any dynamic functions. I could be wrong but just check with your host.
Had a similar problem like this once & when I asked the host why I can't redirect using .htaccess, they pretty much had no idea what I was talking about. Thats another thing, make sure you use a compitent host who knows about server configurations.
If you're on a dedicated server or virtual server, then you should pretty much have unlimitted access to all the resources.
If you still can't get it to work, I'd suggest a redirect script. Php, asp, etc.
i think this is the stage i'm at - incompetent hosting!
i am so-o frustrated with the run-around i've rec'd from them. it's bad enough that i have to wait ~3 minutes for every reply, but the best advice i've rec'd is links to their forum that have absolutely nothing to do with my questions, until eventually, i am told that it is a scripting problem and they are only available to help with hosting problems -- *Geesh!!*
i ran a phpinfo on my domain and saw no added modules, let alone any apache references, although they assure me that the module is enabled by default. to prove that it was available on my domain, they told me to do phpinfo on THEIR domain. naturally, it showed the apache mod_rewrite module ... on their domain.
am i an idiot? ... am i the only one who's inquired into this subject with this host? ...
i apologize for venting, but it is an ongoing (3 weeks+ now). when i don't have an answer for someone, i find it so much easier to admit that i don't know, and offer to find out. how hard is that?
i apologize for venting. i'm glad for your recent post though, because for me, it verifies that there is an outside chance it's NOT just me. i think i've read every online tutorial that's out there (apache mod_rewrite, redirects, url rewriting, robots.txt, & other SEO implications) and i know i'm slow, but for Heaven's sake, i think i can put 2 and 2 together long enough to determine whether or not i am completely daft.
this thread has introduced me to the differences between internal and external redirects and the overall nuances with redirects. THANX g1smd as well!
one last request ... can any of you please recommend a knowledgeable, reputable hosting service?
thx in advance!
PS
i promise i will be in a better mood next time.....
I use serverheaven dot NET - very cheap prices but really good hosting - and I know it allows internal and external redirects as I use both! Of course it depends on how big your site is if this is a practical solution.
RE: support tickets - most hosts won't help you with syntax, they only worry about if the server is running properly and has the modules/features you need installed. SH is pretty good about adding stuff for you if it's not there as long as it's not a security risk (some mods are). The owner wants it to be RELIABLE for his users.
(their homepage isn't accurate - click on signup and it'll show the prices - visit ...net/forums for more info - I'm a moderator there)
You are not permitted to post messages in this forum or topic, because of one or more of the following reasons:
You have not yet logged in, or registered properly as a member
You are a member, but no longer have posting rights.
This is a private forum, for which you do not have permissions.
If you are a recent member, it's possible that you simply have not yet confirmed your account. Please
check your email for a message entitled 'JimWorld Forums: Confirm Your Account' and follow the instructions
contained within.
If you are still experiencing problem, please read the
Login Assistance
Article for some advice on what may be causing your login not to work properly.