Posts Tagged ‘PHP Tutorials’

coming soon: new design and much more

Friday, September 21st, 2007

katun.ch welcome pageMy blog appears in a new style. This means that i will develop an additional webpage for katun.ch on which I’m providing my services as web developer. Since a while I have more and more assignments of tasks for customers which want their own website.

So I made a entry site for katun.ch for people who want to visit this blog they can click on the blog link. All others can click on the work link.

PHP in_array for Javascript

Tuesday, March 20th, 2007

For several programs i need the PHP

in_array()

function. Today I’ve needed this function in Javascript. I searched the Internet and found this hint at selfHTML.org. I think it’s a very usefull function. You can download a sample source here

How to copy a highlighted php to MS Word

Monday, March 19th, 2007

For my application I have to write a technical manual. In this manual I would like to show pieces of my php script. At the beginning I thought I can copy the code from eclipse to word. But when I do this, de code isn’t highlighted. Now I wrote a little php script that returns you the highlighted source from any php file you want. You have to wrote the foldernames write to an array. And this script will you highlight all php files in this folders.
After you have the highlighted source in your browser, copy and paste it.

 $folders = array('classes', 'functions','.');

 foreach($folders as $folder) {
    $verz = opendir($folder);
    while($file=readdir($verz)) {
      if($file!='.' AND $file!='..') {
        if(substr($file, -3)=='php') {
      	  echo ''.$file.'';
    	  show_source($folder.'/'.$file);
          echo '

'; } } } closedir($verz); }

Download the source here.

Relay – Ajax Directory Manager

Friday, March 2nd, 2007

Oliver Raduner has written a post about Ajax Frameworks. He wrote a link to MiniAjax.com. There I’ve found a nice tool called Relay.
It’s a Ajax based directory manager for webservers. I searched a very long time for a tool like this. So I’ve installed it on my Hostpoint webserver and it’s fantastic.

During the installation I had some problems, but these problems are very simple to fix. Folow these steps and you can run Relay on your webserver!

  • Download Relay here
  • Extract the relay folder to the desired directory on your webserver
  • Add
    ini_set('allow_url_fopen', 'on');

    after the first php opening tag in

    install/index.php

    and

    index.php

    in your Relay root

  • chmod 755 upload.pl in your Relay root
  • Browse to that directory from your favorite web-browser
  • Follow the on-screen instructions

Requirements for Relay at minimum:

  • PHP version 4+
  • MySQL version 4+
  • Perl 5.8.0 (for upload progress)
  • Apache/IIS

If you want to test Relay, visit the demopage.

A screenshot of Relay
Relay Screenshot

Connecting to an IBM DB2 Database with PHP

Tuesday, February 13th, 2007

In my apprenticeship as computer scientist, I’m developing several applications. But now at the end of my apprenticeship i have an IPA (Individual productive work in german Individuelle Produktiv Arbeit). In this work I have to develop a webfrontend in PHP for an application that runs with IBM DB2.
I’ve searched the world wide web for an how to or a tutorial. But I don’t have found any clever hints.

Here is an expample how to connect PHP5 with a IBM DB2 Database in Windows!
(more…)