function __construct($id) { if (is_numeric($id)) { $wallet_row = get_wallet($id); $this->build($wallet_row); } }
* * 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., 51 Franklin Street, Fifth Floor, Boston, * MA 02110-1301, USA. * * */ require_once __DIR__ . "/../../../../session.php"; require_once __DIR__ . "/../../../../moneyio.php"; require_once __DIR__ . "/../../../../mio-wallet/update/wallet_func.php"; open_session(); if (isset($_SESSION) && !empty($_SESSION)) { $user_id = $_SESSION["mio-username_id"]; $wallet_id = $_GET["wallet_id"]; $wallet_info = get_wallet($wallet_id, $user_id); ?> <!DOCTYPE html> <html> <head> <meta charset="utf8"> <meta keywords="user"> <meta author="netSys"> <meta description="This example test"> <title>Create wallet </title> </head> <body> <form action="../../../../mio-wallet/update/wallet.php?wallet_id=<?php echo $wallet_id; ?>
* * 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., 51 Franklin Street, Fifth Floor, Boston, * MA 02110-1301, USA. * * */ require_once __DIR__ . "/../../session.php"; require_once __DIR__ . "/../../moneyio.php"; open_session(); if (isset($_SESSION["mio-username"]) && !empty($_SESSION["mio-username"]) && isset($_SESSION["mio-username_id"]) && !empty($_SESSION["mio-username_id"]) && isset($_SESSION["mio-pic"]) && !empty($_SESSION["mio-pic"])) { $wallet_user_id = $_POST["wallet_user_id"]; $wallet_name = $_POST["name"]; $wallet_descr = $_POST["descr"]; $wallet_balance = $_POST["balance"]; if (isset($wallet_name) && !empty($wallet_name) && isset($wallet_descr) && !empty($wallet_descr) && isset($wallet_balance) && !empty($wallet_balance) && isset($wallet_user_id) && !empty($wallet_user_id)) { require_once __DIR__ . "/wallet_func.php"; if (get_wallet($wallet_name, $wallet_user_id)) { echo get_message("wallet_exists"); } else { create_wallet($wallet_name, $wallet_descr, $wallet_user_id); $new_wallet_info = get_wallet_new_exist($wallet_name, $wallet_user_id); $wallet_new_id = $new_wallet_info->wallet_id; create_balance($wallet_balance, $wallet_new_id); echo get_message("wallet_added"); } } } else { echo get_message("no_session"); }