<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>Form1</class>
<widget class="Dialog">
    <property name="name">
        <cstring>Form1</cstring>
    </property>
    <property name="geometry">
        <rect>
            <x>0</x>
            <y>0</y>
            <width>553</width>
            <height>325</height>
        </rect>
    </property>
    <property name="caption">
        <string>Variable passing demo with PHP</string>
    </property>
    <property name="icon">
        <pixmap>image0</pixmap>
    </property>
    <property name="associations" stdset="0">
        <stringlist>
            <string></string>
            <string>AboutDialog1.initialize("Variable passing demo", "", "0.1", "Copyright 2008")
AboutDialog1.addAuthor("Eric Laffoon", "Designer", "eric@kdewebdev.org", "http://kittyhooch.com")
AboutDialog1.setHomepage("http://kommander.kdewebdev.org")
AboutDialog1.setBugAddress("eric@kdewebdev.org")
AboutDialog1.setDescription("Demo of passing arguments to and from scripts,
You can also pass an echo to stdout back from 
your script by calling your script with
echo(ScriptObject.execute)")
AboutDialog1.setLicense("GPL_V2")
PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 1)
if str_length(exec("ls -1 /usr/bin/php")) == 0 then
  message_error("This dialog requires command line PHP installed as /usr/bin/php in order to show the external script functions with PHP. if it is installed elsewhere you could edit the PHP script sheebang in the dialog or create a symlink on your system.", "PHP not detected")
endif</string>
            <string></string>
        </stringlist>
    </property>
    <property name="useInternalParser">
        <bool>true</bool>
    </property>
    <property name="toolTip" stdset="0">
        <string></string>
    </property>
    <grid>
        <property name="name">
            <cstring>unnamed</cstring>
        </property>
        <property name="margin">
            <number>11</number>
        </property>
        <property name="spacing">
            <number>6</number>
        </property>
        <widget class="Label" row="2" column="0" rowspan="1" colspan="2">
            <property name="name">
                <cstring>Label8</cstring>
            </property>
            <property name="text">
                <string>Value to pass back</string>
            </property>
        </widget>
        <widget class="ExecButton" row="3" column="0" rowspan="1" colspan="2">
            <property name="name">
                <cstring>ExecButton3</cstring>
            </property>
            <property name="sizePolicy">
                <sizepolicy>
                    <hsizetype>1</hsizetype>
                    <vsizetype>4</vsizetype>
                    <horstretch>0</horstretch>
                    <verstretch>0</verstretch>
                </sizepolicy>
            </property>
            <property name="text">
                <string>Pass I&amp;nternally</string>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string>ret = ScriptObject2.execute(LineEdit7.text, LineEdit1.text, LineEdit2.text)
LineEdit6.setText(ret)</string>
                </stringlist>
            </property>
        </widget>
        <widget class="Label" row="4" column="0">
            <property name="name">
                <cstring>Label9</cstring>
            </property>
            <property name="text">
                <string>Set</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="Label" row="6" column="0">
            <property name="name">
                <cstring>Label6_2</cstring>
            </property>
            <property name="text">
                <string>Pass back</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="ExecButton" row="3" column="4" rowspan="1" colspan="2">
            <property name="name">
                <cstring>ExecButton72</cstring>
            </property>
            <property name="sizePolicy">
                <sizepolicy>
                    <hsizetype>1</hsizetype>
                    <vsizetype>4</vsizetype>
                    <horstretch>0</horstretch>
                    <verstretch>0</verstretch>
                </sizepolicy>
            </property>
            <property name="text">
                <string>P&amp;ass to PHP Script</string>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string>// test for PHP
pt = exec("php --version")
if str_contains(pt, "Zend") then
  php = ScriptObjectPHP.execute(LineEdit7.text,LineEdit1.text,LineEdit2.text)
  LineEdit4.setText(php)
else
  message_error("It looks like PHP CLI is not installed and on your path")
endif</string>
                </stringlist>
            </property>
        </widget>
        <widget class="Label" row="6" column="3" rowspan="1" colspan="2">
            <property name="name">
                <cstring>Label6</cstring>
            </property>
            <property name="text">
                <string>Pass back</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="Label" row="4" column="3" rowspan="1" colspan="2">
            <property name="name">
                <cstring>Label5</cstring>
            </property>
            <property name="text">
                <string>Set with @</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="Label" row="5" column="3" rowspan="1" colspan="2">
            <property name="name">
                <cstring>Label37</cstring>
            </property>
            <property name="text">
                <string>Return</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="LineEdit" row="4" column="5" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit3</cstring>
            </property>
        </widget>
        <widget class="Label" row="5" column="0">
            <property name="name">
                <cstring>Label37_2</cstring>
            </property>
            <property name="text">
                <string>Return</string>
            </property>
            <property name="alignment">
                <set>AlignVCenter|AlignRight</set>
            </property>
        </widget>
        <widget class="LineEdit" row="5" column="5" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit4</cstring>
            </property>
        </widget>
        <widget class="LineEdit" row="6" column="5" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit5</cstring>
            </property>
        </widget>
        <widget class="LineEdit" row="5" column="1" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit6</cstring>
            </property>
        </widget>
        <widget class="LineEdit" row="4" column="1" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit8</cstring>
            </property>
        </widget>
        <widget class="LineEdit" row="6" column="1" rowspan="1" colspan="2">
            <property name="name">
                <cstring>LineEdit9</cstring>
            </property>
        </widget>
        <widget class="ScriptObject" row="3" column="2">
            <property name="name">
                <cstring>ScriptObject2</cstring>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string>LineEdit8.setText("Kommander "+_VERSION)
LineEdit9.setText(Self.Item(0))
x = Self.Item(1)/Self.Item(2)
return(x)</string>
                </stringlist>
            </property>
        </widget>
        <widget class="ScriptObject" row="3" column="6">
            <property name="name">
                <cstring>ScriptObjectPHP</cstring>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string>#!/usr/bin/php
&lt;?php
@LineEdit3.setText(Kommander @global(VERSION))
@LineEdit5.setText(@Self.Item(0))
echo round(@Self.Item(1)/@Self.Item(2),5)
?&gt;</string>
                </stringlist>
            </property>
        </widget>
        <widget class="Label" row="0" column="0" rowspan="1" colspan="3">
            <property name="name">
                <cstring>Label12</cstring>
            </property>
            <property name="sizePolicy">
                <sizepolicy>
                    <hsizetype>5</hsizetype>
                    <vsizetype>4</vsizetype>
                    <horstretch>0</horstretch>
                    <verstretch>0</verstretch>
                </sizepolicy>
            </property>
            <property name="text">
                <string>Numbers to pass to scripts</string>
            </property>
        </widget>
        <widget class="LineEdit" row="2" column="2" rowspan="1" colspan="4">
            <property name="name">
                <cstring>LineEdit7</cstring>
            </property>
            <property name="text">
                <string>Pass back</string>
            </property>
            <property name="toolTip" stdset="0">
                <string>right click on dialog for about dialog</string>
            </property>
        </widget>
        <spacer row="3" column="3">
            <property name="name">
                <cstring>Spacer1</cstring>
            </property>
            <property name="orientation">
                <enum>Horizontal</enum>
            </property>
            <property name="sizeType">
                <enum>Expanding</enum>
            </property>
            <property name="sizeHint">
                <size>
                    <width>108</width>
                    <height>0</height>
                </size>
            </property>
        </spacer>
        <widget class="TQLayoutWidget" row="1" column="0" rowspan="1" colspan="7">
            <property name="name">
                <cstring>Layout1</cstring>
            </property>
            <hbox>
                <property name="name">
                    <cstring>unnamed</cstring>
                </property>
                <property name="margin">
                    <number>0</number>
                </property>
                <property name="spacing">
                    <number>6</number>
                </property>
                <spacer>
                    <property name="name">
                        <cstring>Spacer3</cstring>
                    </property>
                    <property name="orientation">
                        <enum>Horizontal</enum>
                    </property>
                    <property name="sizeType">
                        <enum>Expanding</enum>
                    </property>
                    <property name="sizeHint">
                        <size>
                            <width>71</width>
                            <height>0</height>
                        </size>
                    </property>
                </spacer>
                <widget class="Label">
                    <property name="name">
                        <cstring>Label35</cstring>
                    </property>
                    <property name="text">
                        <string>op 1</string>
                    </property>
                </widget>
                <widget class="LineEdit">
                    <property name="name">
                        <cstring>LineEdit1</cstring>
                    </property>
                    <property name="sizePolicy">
                        <sizepolicy>
                            <hsizetype>4</hsizetype>
                            <vsizetype>0</vsizetype>
                            <horstretch>0</horstretch>
                            <verstretch>0</verstretch>
                        </sizepolicy>
                    </property>
                    <property name="text">
                        <string>22</string>
                    </property>
                </widget>
                <widget class="Label">
                    <property name="name">
                        <cstring>Label36</cstring>
                    </property>
                    <property name="text">
                        <string>/ op 2</string>
                    </property>
                </widget>
                <widget class="LineEdit">
                    <property name="name">
                        <cstring>LineEdit2</cstring>
                    </property>
                    <property name="sizePolicy">
                        <sizepolicy>
                            <hsizetype>4</hsizetype>
                            <vsizetype>0</vsizetype>
                            <horstretch>0</horstretch>
                            <verstretch>0</verstretch>
                        </sizepolicy>
                    </property>
                    <property name="text">
                        <string>7</string>
                    </property>
                </widget>
                <spacer>
                    <property name="name">
                        <cstring>Spacer2</cstring>
                    </property>
                    <property name="orientation">
                        <enum>Horizontal</enum>
                    </property>
                    <property name="sizeType">
                        <enum>Expanding</enum>
                    </property>
                    <property name="sizeHint">
                        <size>
                            <width>71</width>
                            <height>0</height>
                        </size>
                    </property>
                </spacer>
            </hbox>
        </widget>
        <widget class="AboutDialog" row="0" column="5">
            <property name="name">
                <cstring>AboutDialog1</cstring>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string></string>
                </stringlist>
            </property>
        </widget>
        <widget class="PopupMenu" row="0" column="4">
            <property name="name">
                <cstring>PopupMenu1</cstring>
            </property>
            <property name="associations" stdset="0">
                <stringlist>
                    <string>AboutDialog1.execute</string>
                </stringlist>
            </property>
        </widget>
    </grid>
</widget>
<images>
    <image name="image0">
        <data format="XPM.GZ" length="6350">[encoded data, 5268 characters]</data>
    </image>
</images>
<connections>
    <connection>
        <sender>Form1</sender>
        <signal>contextMenuRequested(int,int)</signal>
        <receiver>PopupMenu1</receiver>
        <slot>popup(int,int)</slot>
    </connection>
</connections>
<layoutdefaults spacing="6" margin="11"/>
</UI>
