ludvig87
Member
Posted 5 years ago #
Ive made tutorials on customizing your wp, so I would like to be able to show the codes online, but...
Ive saved the files as phps, but when I try to look at them online, there pops up a message on whether I want to save or open the document.. How do I change that, so the codes just show??
hmm, y not just renamed to .txt?
The ability to display .phps in a browser depends on your Apache server settings.
LoadModule php4_module /usr/local/apache/libexec/libphp4.so
<IfModule mod_mime.c>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
</IfModule >
has to be included in the httpd.conf file, which you may not have access to. You'd need to contact your server administrator to have it included.
ludvig87
Member
Posted 5 years ago #
Thanks. Ill try out both...
if not u can uise php functions called show_source() i think
You can also post it to the wiki, which does syntax highlighting. (Check out the my-hacks.php page.)
sunshine
Member
Posted 5 years ago #
<IfModule mod_mime.c>
AddType application/x-httpd-php-source .phps
</IfModule >
Is all you'll need. :)