Exemplo n.º 1
0
function package($pattern, $destination, $recurse = false, $exclude = false)
{
    global $root, $stage_path;
    $search = $root . '/' . $pattern;
    echo "Packaging " . $search . "\n";
    foreach (glob($search, GLOB_BRACE | GLOB_NOSORT) as $file) {
        if (is_file($file)) {
            if ($exclude && exclude($exclude, $file)) {
                continue;
            }
            if (!is_dir("{$stage_path}/{$destination}")) {
                mkdir("{$stage_path}/{$destination}", 0777, true);
            }
            copy($file, $stage_path . '/' . $destination . '/' . basename($file));
        }
    }
    if ($recurse) {
        foreach (glob(dirname($search) . '/*', GLOB_ONLYDIR | GLOB_NOSORT) as $dir) {
            if ($exclude && exclude($exclude, $dir)) {
                continue;
            }
            package(dirname($pattern) . '/' . basename($dir) . '/' . basename($pattern), $destination . '/' . basename($dir), $recurse - 1, $exclude);
        }
    }
}
Exemplo n.º 2
0
<?php

require_once "functions.php";
$packing_array = packingData();
if (isset($_GET["pakitud"])) {
    $package_id = $_GET["pakitud"];
    package($package_id);
}
?>
<html>
	<body>
		<table border="1">
				<?php 
for ($i = 0; $i < count($packing_array); $i++) {
    echo "<tr>";
    echo "<input type='hidden' name='id' value='" . $packing_array[$i]->id . "'>";
    echo "<td>" . $packing_array[$i]->kirjeldus . "</td>";
    echo "<td>" . $packing_array[$i]->korpus . "</td>";
    echo "<td>" . $packing_array[$i]->kuvar . "</td>";
    echo "<td>" . $packing_array[$i]->pakitud . "</td>";
    echo "<td><a href='?pakitud=" . $packing_array[$i]->id . "'>Pakitud</a></td>";
}
?>
			</table>
	</body>
</html>
Exemplo n.º 3
0
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.system');
/**
 * 
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @license MIT
 *
 * @package mango.system
 *
 */
class MMutableString extends MString
{
    //
    // ************************************************************
    //
Exemplo n.º 4
0
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.system.io');
import('mango.system.*');
import('mango.system.exceptions.*');
/**
 * 
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @license MIT
 *
 * @package mango.system.io
 *
 */
abstract class MOutputStream extends MStream
{
    //
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: AllAmpolirosDatatransferTests.php,v 1.2 2004-07-08 15:04:26 alex Exp $
/**
 * @package com.solarix.ampoliros.tests.datatransfer
 * @author Alex Pagnoni <*****@*****.**>
 * @copyright Copyright 2000-2004 Solarix Srl
 * @since 4.0
 */
package('com.solarix.ampoliros.tests.datatransfer');
import('carthag.dev.unit.framework.TestSuite');
import('com.solarix.ampoliros.tests.datatransfer.ClipboardTest');
/**
 * @package com.solarix.ampoliros.tests.datatransfer
 * @author Alex Pagnoni <*****@*****.**>
 * @copyright Copyright 2000-2004 Solarix Srl
 * @since 4.0
 */
class AllAmpolirosDatatransferTests extends Object
{
    public static function suite()
    {
        $suite = new TestSuite('AmpolirosDatatransfer');
        $suite->addTestSuite(new ReflectionClass('ClipboardTest'));
        return $suite;
Exemplo n.º 6
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: XmlRpcUser.php,v 1.3 2004-07-08 15:04:26 alex Exp $
package('com.solarix.ampoliros.webservices.xmlrpc');
import('com.solarix.ampoliros.io.log.Logger');
/*!
 @class XmlRpcUser

 @abstract XML RPC interface users.
 */
class XmlRpcUser extends Object
{
    var $mLog;
    var $mAmpDb;
    var $mUserId;
    var $mProfileId = 0;
    var $mSiteId = 0;
    /*!
         @function XmlRpcUser
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.system.exceptions');
import('mango.system.*');
import('mango.system.io.*');
/**
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @package mango.system.exceptions
 *
 */
class MFileNotFoundException extends MException
{
    protected $filePath;
    public function __construct(MString $filePath, MException $previous = null)
    {
        parent::__construct(Sf("File at path '%s' could not be found!", $filePath), MException::FILE_NOT_FOUND_EXCEPTION, $previous);
Exemplo n.º 8
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: HuiDispatcher.php,v 1.10 2004-07-08 15:04:26 alex Exp $
package('com.solarix.ampoliros.hui');
/*!
 @class HuiDispatcher
 @abstract Hui events dispatcher.
 @discussion Hui events dispatcher.
 */
class HuiDispatcher extends Object
{
    /*! @var mName string - Dispatcher name. */
    private $mName;
    /*! @var mEvents array - Array of the event functions. */
    public $mEvents = array();
    /*! @var mDispatched bool - True when the events have been dispatched. */
    private $mDispatched;
    /*!
      @function HuiDispatcher
Exemplo n.º 9
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: RecordSet_odbc.php,v 1.3 2004-07-08 15:04:23 alex Exp $
package('com.solarix.ampoliros.db.drivers.odbc');
import('com.solarix.ampoliros.db.RecordSet');
class recordset_pgsql extends recordset
{
    var $suppseek = true;
    var $_start = false;
    function _Init()
    {
        $this->resultrows = @pg_numrows($this->resultid);
        $this->resultfields = @pg_numfields($this->resultid);
    }
    function _Seek($row)
    {
        $this->currentrow = $row;
        return true;
    }
Exemplo n.º 10
0
 *                    Ampoliros Application Server
 *
 *                      http://www.ampoliros.com
 *
 *
 *
 *   Copyright (C) 2000-2004 Solarix
 *
 *   This program is free software; you can redistribute it and/or modify
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: HuiAuthHelper.php,v 1.5 2004-07-14 15:16:44 alex Exp $
package('com.solarix.ampoliros.hui.helpers');
import('com.solarix.ampoliros.hui.mvc.HuiRequest');
import('com.solarix.ampoliros.hui.mvc.HuiResponse');
interface HuiAuthHelper
{
    public function auth(HuiRequest $request, HuiResponse $response);
}
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.data');
import('mango.system.*');
/**
 * Class that describes an entity's property
 *
 * This class holds and manages the information necessary to describe
 * an entity's property
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @license MIT
 *
 * @package mango.data
 *
 */
class MEntityDescriptionProperty extends MEntityDescriptionAttribute
#
#
require "../settings.php";
require "../core-settings.php";
require "../libs/ext.lib.php";
## Decide
if (isset($_POST["key"])) {
    switch ($_POST["key"]) {
        case "process":
            $OUTPUT = process($_POST);
            break;
        case "confirm":
            $OUTPUT = confirm($_POST);
            break;
        case "pack":
            $OUTPUT = package($_POST);
            break;
        default:
            $OUTPUT = slctEmployee();
    }
} else {
    $OUTPUT = slctEmployee();
}
require "../template.php";
function mlist($name, $curr = "")
{
    $month = 1;
    $months = array("1", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December");
    $list = "<select name={$name}>";
    while ($month <= 12) {
        if ($month == $curr) {
Exemplo n.º 13
0
<?php

/**
 * Description of ContrPerro
 *
 * @author ubuntu
 */
require_once Controller_php;
package("pack1");
import("Perro");
class ContrPack1 extends Controller
{
    /**
     * 
     * @return Pack1
     */
    public static function getInstance()
    {
        return parent::getInstance();
    }
    public function getPerro(Procedure &$pro, int $perroid)
    {
        $p = Perro::persistence();
        $perro = $pro->declare_var('per', new RowType($p));
        $pro->select($p->id, $p->nombre, $p->persona_id)->from($p)->where(c($p->id = $perroid))->into($perro);
        return $perro;
    }
    public function getPerros(Procedure &$pro)
    {
        $p = Perro::persistence();
        $pro->returns(new RowType($p));
Exemplo n.º 14
0
<?php

package('musicpd', ["emerge/use" => "vorbis"])->install();
service('musicpd')->enable()->requires(package('musicpd'));
Exemplo n.º 15
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: ModuleConfig.php,v 1.6 2004-07-08 15:04:25 alex Exp $
package('com.solarix.ampoliros.module');
/*!
 @abstract Module configuration handling.
 */
class ModuleConfig extends Object
{
    /*! @var ampdb dblayer class - Ampoliros database handler. */
    private $ampdb;
    /*! @var modname string - Module name. */
    private $modname;
    /*!
      @param ampdb dblayer class - Ampoliros database handler.
      @param modname string - Module name.
      */
    public function ModuleConfig(DBLayer $ampdb, $modname)
    {
Exemplo n.º 16
0
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.system.xml');
import('mango.system.*');
/**
 * 
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @license MIT
 *
 * @package mango.system.xml
 *
 */
class MXMLView extends MMarkupElementView
{
    //
    // ************************************************************
Exemplo n.º 17
0
<?php

package("japha.lang");
/**
 * $Id$
 *
 * Class ClassLoader
 *
 * Provides a mechanism for loading class files into the global namespace, and keeping track of those files
 * in an effort to make sure that the same file is not loaded twice, and to make sure that any errors that
 * can be caught in the linking process ARE caught, and not let alone until run time.
 *
 * @author <a href="mailto:gantt@cs.montana.edu">Ryan Gantt</a>
 * @version $Revision$
 */
class ClassLoader extends Object
{
    // The VM (parent) instance of the ClassLoader class. If no VM instance exists, then it is a reflective reference
    private $classLoader;
    function __construct($parent = null)
    {
        if ($parent == null) {
            $this->classLoader = $this->getSystemClassLoader();
        }
    }
    /**
     * Loads a class into the virtual machine memory space - If the class has not been resolved, then it starts
     * the resolution progress, along with verification and preparation. Not necessarily in that order.
     *
     * @param name The fully qualified name of the class to load
     * @param resolve A boolean value that states whether or not the current class has been resolved
Exemplo n.º 18
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: Ampoliros.php,v 1.16 2004-07-08 14:49:15 alex Exp $
package('com.solarix.ampoliros.core');
import('carthag.util.Singleton');
class Ampoliros extends Singleton
{
    private $bootstrapped = false;
    private $pid;
    private $state;
    private $mode;
    private $interface;
    private $edition;
    const STATE_SETUP = 1;
    const STATE_DEVELOPMENT = 2;
    const STATE_DEBUG = 3;
    const STATE_PRODUCTION = 4;
    const STATE_UPGRADE = 5;
    const STATE_MAINTENANCE = 6;
Exemplo n.º 19
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: DBLayerFactory.php,v 1.6 2004-07-13 15:20:52 alex Exp $
package('com.solarix.ampoliros.db');
import('com.solarix.ampoliros.db.DBLayer');
global $dbtypes;
$dbtypes = array();
class DBLayerFactory extends Object
{
    public function dBLayerFactory()
    {
        OpenLibrary('configman.library');
        $this->FillDbLayers();
    }
    public function fillDbLayers()
    {
        global $dbtypes;
        $dbtypes = array();
        $dbcfgfile = new ConfigFile(CONFIG_PATH . 'dblayers.cfg', TRUE);
Exemplo n.º 20
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: Group.php,v 1.6 2004-07-08 15:04:23 alex Exp $
package('com.solarix.ampoliros.site.user');
class Group extends Object
{
    public $mrAmpDb;
    public $mrSiteDb;
    public $siteserial;
    public $groupid;
    /*!
       @function Group
      
       @abstract Class constructor
       */
    public function Group(DBLayer $rampDb, DBLayer $rsiteDb, $siteserial, $groupid = 0)
    {
        $this->mrAmpDb = $rampDb;
        $this->mrSiteDb = $rsiteDb;
Exemplo n.º 21
0
<?php

package('blargon.user');
import('blargon.user.User');
class Poster extends User
{
}
Exemplo n.º 22
0
<?php

// This example site.php uses the package "multiSite" to display mutliple sites.
// We recommend using the package "multiSite2" for this.
if (!isset($permittedCall)) {
    echo "Please don't open this page directly!";
    exit;
}
// Include the scriptfile (site.script.php)
include scriptfile();
// Include the packages
include package("ownLog");
include package("multiSite");
include package("tiles");
ownLog_clearLog();
ownLog_writeToLog("This is a test!");
write2logfile("I'm writing to the ownLog log!");
if (multiSite_Site("main")) {
    ?>

Hello <?php 
    echo $api->getSynchroUsername();
    ?>
! You mail is: <?php 
    echo $api->getMail();
    ?>
<br>
This plugin is just a test. 'Real' plugins will come in the future!<br>
Pluginname: <?php 
    echo getValue(readSDB("examplePlugin.sdb"), "NAME");
    ?>
Exemplo n.º 23
0
<?php

package("japha.net");
import("japhax.servlet.http.HttpServletRequest");
/**
 * $Id$
 *
 * This class is the interface to all the requests of the http protocol.
 * Most of the work is actually done by PHP to setup the variables, so this
 * class is just an interface to that PHP layer.
 *
 * @author <a href="mailto:gantt@cs.montana.edu">Ryan Gantt</a>
 * @version $Revision$ $Date$
 * @based on a class by Dan Allen
 */
class HttpURLConnection extends Object implements HttpServletRequest
{
    /**
     * Default port uses for regular (insecure) requests
     * 
     * @access protected
     * @var
     */
    protected $DEFAULT_PORT = 80;
    /**
     * Port of a secure connection
     *
     * @access protected
     * @var
     */
    protected $DEFAULT_SECURE_PORT = 443;
Exemplo n.º 24
0
<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
/**
 * Description of Perro
 *
 * @author ubuntu
 */
require_once Model_php;
package('pack1');
import('Persona');
class Perro extends Model
{
    /** *@var int notnull **/
    private $id;
    /** *@var varchar notnull **/
    private $nombre;
    /** *@var int notnull **/
    private $persona_id;
    function __construct()
    {
        parent::__construct();
    }
    /**
     * 
     * @param Perro $self
     */
    public function constraint($self)
 *    may be used to endorse or promote products derived from this software
 *    without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY MOVINPIXEL AND ITS CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL MOVINPIXEL OR ITS CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 */
package('mango.system.html');
import('mango.system.*');
/**
 * 
 *
 * @author Jader Feijo <*****@*****.**>
 *
 * @license MIT
 *
 * @package mango.system.html
 *
 */
class MHTMLHeaderElementView extends MHTMLElementView
{
    const HTML_HEADER_TYPE_1 = 1;
    const HTML_HEADER_TYPE_2 = 2;
Exemplo n.º 26
0
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 2 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */
// $Id: HuiTheme.php,v 1.8 2004-07-13 15:20:52 alex Exp $
package('com.solarix.ampoliros.hui.theme');
import('com.solarix.ampoliros.datatransfer.cache.CachedItem');
import('com.solarix.ampoliros.db.DBLayer');
import('com.solarix.ampoliros.hui.theme.HuiStyle');
import('com.solarix.ampoliros.hui.theme.HuiIconsSet');
import('com.solarix.ampoliros.hui.theme.HuiColorsSet');
/*!
 @class HuiTheme
 @abstract Hui themes handler.
 @discussion Handles Hui themes.
 */
class HuiTheme extends Object
{
    private $mrAmpDb;
    /*! @var mTheme string - Theme name. */
    private $mTheme;
Exemplo n.º 27
0
		package_edit_metadata();

		require_once(CACTI_BASE_PATH . "/include/bottom_footer.php");
		break;
	case 'remove_graph_template':
		package_remove_graph_template();

		break;
	case 'remove_metadata':
		package_remove_metadata();

		break;
	default:
		require_once(CACTI_BASE_PATH . "/include/top_header.php");

		package();

		require_once(CACTI_BASE_PATH . "/include/bottom_footer.php");
		break;
}

function form_save() {
	if ($_POST["action_post"] == "package_new") {
		header("Location: packages.php?action=edit");
	}else if ($_POST["action_post"] == "package_edit") {
		/* the "Add" associated graph template button was pressed */
		if (isset($_POST["assoc_graph_template_add_y"])) {
			api_package_package_template_add($_POST["package_id"], $_POST["assoc_graph_template_id"]);
			header("Location: packages.php?action=edit&id=" . $_POST["package_id"]);
			exit;
		}
Exemplo n.º 28
0
<?php

package('blargon.util');
import('blargon.factory.ConfigFactory');
import('blargon.factory.DblFactory');
class Entry
{
    protected $config;
    protected $db;
    protected $entryData;
    public function __construct($n)
    {
        $this->config = ConfigFactory::getConfig();
        $this->db = DblFactory::getConn();
        $this->entryData = $this->db->fetchObject($this->db->query('select * from ' . $this->config->get('prefix') . '_news order by id desc limit ' . $n . ',1'));
    }
    public function getTitle()
    {
        return $this->entryData->subject;
    }
    public function getId()
    {
        return $this->entryData->id;
    }
    public function getAuthorName()
    {
        return $this->entryData->user;
    }
    public function getReplacedContent()
    {
        return $this->entryData->news;
Exemplo n.º 29
0
<?php

package("japha.io");
import("japha.io.OutputStream");
/**
 * $Id$
 *
 * This class is the superclass of all classes that filter output streams. 
 * These streams sit on top of an already existing output stream (the underlying output stream) 
 * which it uses as its basic sink of data, but possibly transforming the data along the way 
 * or providing additional functionality. 
 *
 * The class FilterOutputStream itself simply overrides all methods of OutputStream with 
 * versions that pass all requests to the underlying output stream. Subclasses of 
 * FilterOutputStream may further override some of these methods as well as provide 
 * additional methods and fields. 
 *
 * @author <a href="mailto:gantt@cs.montana.edu">Ryan Gantt</a>
 * @version $Revision$ $Date$
 */
class FilterOutputStream extends OutputStream
{
    /**
     * The underlying output stream to be filtered.
     */
    public $out = "";
    /**
     * Creates an output stream filter built on top of the specified underlying output stream.
     *
     * @param out The underlying output stream to be assigned to the field this.out for later use, or null if this instance is to be created without an underlying stream.
     */
Exemplo n.º 30
0
<?php

package("japhax.servlet.jsp");
import("japhax.servlet.Servlet");
/**
 * $Id$
 *
 * The JspPage interface describes the generic interaction that a JSP Page Implementation 
 * class must satisfy; pages that use the HTTP protocol are described by the HttpJspPage 
 * interface. 
 *
 * Two plus One Methods 
 *
 * The interface defines a protocol with 3 methods; only two of them: jspInit() and 
 * jspDestroy() are part of this interface as the signature of the third method: 
 * _jspService() depends on the specific protocol used and cannot be expressed in a 
 * generic way in Java. 
 *
 * A class implementing this interface is responsible for invoking the above methods at the 
 * appropriate time based on the corresponding Servlet-based method invocations. 
 *
 * The jspInit() and jspDestroy() methods can be defined by a JSP author, but the 
 * _jspService() method is defined automatically by the JSP processor based on the contents 
 * of the JSP page. 
 *
 * _jspService() 
 *
 * The _jspService()method corresponds to the body of the JSP page. This method is defined 
 * automatically by the JSP container and should never be defined by the JSP page author. 
 *
 * If a superclass is specified using the extends attribute, that superclass may choose to