|
omgwtfnoway posted:I'm trying to use exec() in a php script to add and commit some files to SVN. I don't know how it works on windows, but in UNIX I wouldn't expect changing directories this way (via exec) to work. Try chdir: http://us2.php.net/manual/en/function.chdir.php Also exec returns the last line of output from the thing you're trying to run. Do you get anything in your example? Do you have safe_mode disabled? If it's enabled, you can only exec in certain directories.
|
# ¿ Apr 3, 2008 01:16 |
|
|
# ¿ Apr 30, 2024 16:49 |
|
genericadmin posted:code I would suggest this. Your problem is a good application for a class factory. Have a class (the factory) that does the expensive sql and add methods on it to get instances of the chunks of your big class that you've created. Have the chunks take a reference to the factory (so they can get at the stored results of the expensive SQL). You run the queries once and can produce different objects that can get at one copy of the results.
|
# ¿ Apr 8, 2008 07:29 |