The work around for this issue is not too complex:
In the .htaccess file you need to add a few lines. The first adds an extra option for the index file.
DirectoryIndex index.wml index.php index.html index.htm
Then we add some code to tell apache to use php to process the index.wml
AddType text/vnd.wap.wml .wml
AddHandler application/x-httpd-php .wml
Finally in the .wml file we put the relavent php code to generate the .wml code for the WAP clients.
2 comments:
Can you enlighten me on why the .htaccess file is necessary for this and what it's purpose is?
The commands in the htaccess file make the Apache webserver process .wml files as if they are .php files. This allows us to php code in the .wml files. Earlier phones are not clever enough to use the mime file type and rely on the file's extention to determine if it is wml or not hence we can't server .php files to such a phone.
Post a Comment