# How to convert on the fly old WebDirect 15 URL’s to actual URL

**URL:** <https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503>\
**Category:** Questions\
**Tags:** webdirect\
**Created:** [October 3, 2021, 9:19am UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503 "2021-10-03T09:19:20Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fred](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/fred/32/269_2.png) [@Fred](https://the.fmsoup.org/u/Fred)\
**Post date:** [October 3, 2021, 9:19am UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/1 "2021-10-03T09:19:20Z")

</div>

Hello There,

I have hundreds of apps that occasionally connect to a WebDirect solution and where the URL is hardcoded using the old WD URL syntax of FMS 15 :

[http://192.168.123.101/fmi/webd?homeurl=http://192.168.123.101/xyz\_home.html](http://192.168.123.101/fmi/webd?homeurl=http://192.168.123.101/xyz_home.html) **#Contacts**

That worked until at least FMS 16 but now i updated to 19, the syntax should be :

[http://192.168.123.101/fmi/webd](http://192.168.123.101/fmi/webd) **/Contacts**?homeurl=http://192.168.123.101/ xyz\_home.html

Obviously i am figuring out how can i avoid to modify hundreds of files and configure the apache instance of FMS 19 to redirect theses old URL’s.

What is sad is i had the similar problem years ago with IWP and i had no luck. The track was the RewriteCond instruction.

I first tried to alter the httpd-rewrite.conf file located in : /Library/FileMaker Server/HTTPServer/conf/extras/

But even after restart of HTTPserver it sounds like my rules were ignored.

I suspected a fault in my syntax since i am not familiar with Apache nor REGEX , and tried very simple rules like :

RewriteRule ^/aloha /fmi/webd

I then excepted that

[http://192.168.123.101/aloha](http://192.168.123.101/aloha)

will lead to :

[http://192.168.123.101/fmi/webd](http://192.168.123.101/fmi/webd)

But nope…

Any tracks ?

Thanks !

Fred

 ![Capture d’écran 2021-10-03 à 10.34.14](https://canada1.discourse-cdn.com/flex030/uploads/fmsoup/original/2X/c/c54b46cce514d02f142c76414e1ec1f7addd34e8.png)

---

<div class="post-metadata">

**Author:** ![Malcolm](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/malcolm/32/196_2.png) [@Malcolm](https://the.fmsoup.org/u/Malcolm)\
**Post date:** [October 4, 2021, 5:45am UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/2 "2021-10-04T05:45:28Z")

</div>

You may be able to use mod\_alias. It’s simpler.

[https://httpd.apache.org/docs/2.4/mod/mod\_alias.html](https://httpd.apache.org/docs/2.4/mod/mod_alias.html)

---

<div class="post-metadata">

**Author:** ![Fred](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/fred/32/269_2.png) [@Fred](https://the.fmsoup.org/u/Fred)\
**Post date:** [October 4, 2021, 7:18am UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/3 "2021-10-04T07:18:50Z")

</div>

Thanks for the insight !

Yes you are right and i was able to manage my sample case "aloha" with the **redirect** command from alias module.

However, i think that converting my v15 WebDirect URL is finally impossible because FMI initially used an anchor to refer to databases ex : "[http://192.168.123.101/fmi/webd#Contacts](http://192.168.123.101/fmi/webd#Contacts)" and this # is not handled by the server.

But i would be very happy to be wrong… so pleeeaaaase don’t hesitate to tell me so 😊 🙏

---

<div class="post-metadata">

**Author:** ![Malcolm](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/malcolm/32/196_2.png) [@Malcolm](https://the.fmsoup.org/u/Malcolm)\
**Post date:** [October 4, 2021, 10:57pm UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/4 "2021-10-04T22:57:25Z")

</div>

Apache will allow you to access the query string but I don't have the answer. You might find knowledgeable advice on StackOverflow.

---

<div class="post-metadata">

**Author:** ![Fred](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/fred/32/269_2.png) [@Fred](https://the.fmsoup.org/u/Fred)\
**Post date:** [October 6, 2021, 7:32pm UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/5 "2021-10-06T19:32:03Z")

</div>

Thanks. Without any conviction i will give it a try...

---

<div class="post-metadata">

**Author:** ![Fred](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/fred/32/269_2.png) [@Fred](https://the.fmsoup.org/u/Fred)\
**Post date:** [October 6, 2021, 9:42pm UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/6 "2021-10-06T21:42:04Z")

</div>

Tried !  
[https://stackoverflow.com/questions/69472964/apache-redirect-when-original-url-contain-a-hashtag](https://stackoverflow.com/questions/69472964/apache-redirect-when-original-url-contain-a-hashtag)

---

<div class="post-metadata">

**Author:** ![Fred](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/fred/32/269_2.png) [@Fred](https://the.fmsoup.org/u/Fred)\
**Post date:** [October 10, 2021, 4:03pm UTC](https://the.fmsoup.org/t/how-to-convert-on-the-fly-old-webdirect-15-url-s-to-actual-url/2503/7 "2021-10-10T16:03:33Z")

</div>

Still struggling. Problem with # confirmed. It seem always ignored.

However, i am progressing.

I added this rule on "httpd-rewrite.conf" :

RewriteCond %{THE\_REQUEST} xyz\_home.html  
RewriteRule ^/fmi/webd https://%{SERVER\_NAME}/fmi/webd/Contacts

It works fine the first time after i cleared the cache of the browser and if the url is not secured (begin with http://).

as for instance :  
[http://192.168.123.101/fmi/webd?homeurl=http://192.168.123.101/xyz\_home.html](http://192.168.123.101/fmi/webd?homeurl=http://192.168.123.101/xyz_home.html) #Contacts

Then, all other similar tries fail, apparently because the browser automatically convert to https :  
http **s** ://192.168.123.101/fmi/webd?homeurl=http://192.168.123.101/xyz\_home.html

Here, the rule is failing and the url is not rewritten.

The point now seems to be http or https.

Is there another conf file for https ?

Or another rule to override ?

Any thoughts ?
