hello
is it possible to pass parameter to a zikula script with the command line of PHP ?
thanks in advanced
Watch
GitHub Core
Show your support for Zikula! Sign up at Github account and watch the Core project!
GitHub Modules
- internetking created topic »password problem« 25. May
- mesteele101 responded to »ERR (3): E_USER_ERROR: Smarty error: [in pagesvar:pagesitem2en line XXX]…« 25. May
- mazdev responded to »Pages 2.5.0 and updating - Page not found« 25. May
- ehdwma created topic »Hide "Register new account" and change template to 3 col« 25. May
- mesteele101 responded to »Zikula 1.3.3 - Selecting a category in Pages not working« 25. May
- mdee created topic »How to implement returnpage ?« 25. May
- nestormateo responded to »Fillters in Clip« 24. May
Zikula Blog
- Anatomy of Open Source Projects on Mar 07
- Continuous Review on Mar 01
- Not Invented Here on Feb 24
- How to Contribute Your Code at Github on Jan 13
- 10 Steps to Coding-Nirvana: Tips for Successful Module Writing on Nov 12
- Submitting Bug Report Tickets That Get Results on Aug 17
- Cozi Tricks #1: Syntax Highlighting on Aug 07
Login
command line with php
-
- Rank: Developer
- Registered: May 17, 2004
- Last visit: Apr 08, 2010
- Posts: 386
-
- Rank: Team Member
- Registered: May 03, 2004
- Last visit: May 31, 2010
- Posts: 511
-
- Rank: Developer
- Registered: May 17, 2004
- Last visit: Apr 08, 2010
- Posts: 386
no, i don't know how it can be done, for the moment i m using a wget , but i would like to avoid to pass by the http server. -
- Rank: Team Member
- Registered: Jul 15, 2008
- Last visit: Sep 26, 2009
- Posts: 23
I believe it's impossible because GET parameters are only available in GET/POST requests. All passed command line arguments are available through $argv (not through $_GET).
Idea:
Copy the index.php to mymodule_cmd.php and add somthing like
Code
$_GET['module'] = 'mymodule';
$_GET['type'] = 'user';
$_GET['func'] = 'bar';
after the <?PHP
edited by: planetenkiller, Apr 27, 2009 - 06:34 PM -
- Rank: Developer
- Registered: May 17, 2004
- Last visit: Apr 08, 2010
- Posts: 386
planetenkiller, i was hoping for a hidden "command line" module which i didn't know about, which allow you to do this, (indeed as it's possible to hook on "systeminithooks", if a "systeminit" hook check for argv, it can be possible to run the specified command somehow)
thanks anyway, your trick fit me well too :)
- Moderated by:
- Support
Users on-line
- 0 users
This list is based on users active over the last 60 minutes.
