Apache/PHP/MySql Linux Language Considerations Primer Tutorial

Apache/PHP/MySql Linux Language Considerations Primer Tutorial

Apache/PHP/MySql Linux Language Considerations Primer Tutorial

The recent CSS Style Javascript DOM Override Onload Primer Tutorial “proof of concept” web application ended up with the name …


are_you_happy_with_my_or_do_you_think_my_derriere_needs_work.html

… but along the way we wanted to call it …


are_you_happy_with_my_or_do_you_think_my_derrière_needs_work.html

… but this didn’t work as an RJM Programming website filename. Rather than make it work, we compromised, and called it (the final) are_you_happy_with_my_or_do_you_think_my_derriere_needs_work.html it ended up as. But this didn’t stop us wondering about all this language and the relationship of these language characters and where and how you can or can’t use those characters outside those usual US-keyboard type characters.

And that brings us to the great MAMP local Apache/PHP/MySql web server product, as a place to experiment, comforted in the knowledge that the Mac OS X Terminal application …


ls -li

… and knowledge of inodes (all the way to their “extreme case Linux system file removal talents) you can read about at Linux Inode File Removal Tutorial would probably protect me from home grown stupidities.

So what followed for me was a quick look at MAMP’s relevant php.ini file and its httpd.conf configuration files to see that the web server default “goto look for” file list for the web server directory can be altered by a change of …


DirectoryIndex index.html index.php

… to something else in httpd.conf Apache configuration file. But nothing to easily reinvent the US-keyboard feeling file extensions .htm and .html and .php that was apparent to me. And noting to change that …


[protocol]://localhost:[localHostPortNumber]/

… US-keyboard feeling prefix to a URL, such as our HTTP://localhost:8888/ prefix to a MAMP local Apache/PHP/MySql URL we created a Simplified Chinese character set “Hello World” folder scenario (and thank Google Translate for translation help today) …

http://localhost:8888/你好/世界/

index.html as per …


<!doctype html>
<head>
<title>RJM编程着陆页</title>
<meta charset="UTF-8">
</head>
<body>
<h1>欢迎来到-RJM编程网站</h1><br>
<a target=_blank title='RJM编程着陆页' href='https://translate.google.com/translate?sl=en&js=n&prev=_t&hl=en&ie=UTF-8&layout=2&eotf=1&u=%2F%2Fwww.rjmprogramming.com.au%2Findex.html&tl=zh-CN'>RJM编程着陆页</a>
</body></html>

Within the php.ini configuration file we found interesting, in particular …


; Automatically add files before or after any PHP document.
auto_prepend_file =
auto_append_file =

; PHP's built-in default is text/html
default_mimetype = "text/html"

; Whether to allow the treatment of URLs (like // or ftp://) as files.
allow_url_fopen = On

… the last of which, if set to Off could set up for the scenario of setting up a web server full of index.html and index.php code in web server folders that could include non US-keyboard characters, and so you could have within the code of …

http://localhost:8888/你好/

index.html a relative URL such as …

<a target=_blank title='你好 世界' href='世界'>你好 世界</a>

… taking you off to today’s (URL) starting place.

Am sure you can feel yourself, there is so much more to explore in this topic area, and we’ll be returning soon to this neck of the woods soon, we hope. In the meantime, take a look at our tutorial picture for a bit of what we did on MAMP with some of these concepts not changing any configuration files at all.

If this was interesting you may be interested in this too.

This entry was posted in eLearning, Operating System, Tutorials and tagged , , , , , , , , , , , , , , , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>