redirect that also extracts part of referrer and appends that part to url
Let's say I have two links:
- Case 1: domain.com/webpage-123.php
- Case 2: domain.com/webpage2-456.php (note the 2 here!)
If a person comes from ip 123.456.789 or 987.654.321 (and more are possible), he should just continue to the webspot/link he or she clicked. However, if the person does not come from said ip address, he or she should be redirected:
- In case 1: domain.com/custom_string1=123 (where 123 is extracted from the original URL and appended!)
- In case 2: domain.com/custom_string2=123 (where 456 is extracted from the original URL and appended!)
If this could be done with a php redirect, that would be preferred I guess since I don't want to mess with the htaccess all the time, but if no alternatives are available, of course htaccess code would do fine.
Thanks a lot
-
tweakr -
Thanks - 1 reply
{{ DiscussionBoard.errors[5429398].message }}-
Kelebek -
Thanks
{{ DiscussionBoard.errors[5429603].message }} -
-
-
frenchsquared -
Thanks
{{ DiscussionBoard.errors[5431160].message }} -
-
frenchsquared -
Thanks
{{ DiscussionBoard.errors[5431186].message }} -
-
frenchsquared -
Thanks
{{ DiscussionBoard.errors[5431244].message }} -
-
tweakr -
Thanks - 1 reply
{{ DiscussionBoard.errors[5432002].message }}-
Kelebek -
Thanks - 1 reply
{{ DiscussionBoard.errors[5433402].message }}-
Kelebek -
Thanks
{{ DiscussionBoard.errors[5442411].message }} -
-
-