Re: syntax woes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2009-04-02 at 15:47 -0700, aurfalien@xxxxxxxxx wrote:
> > aurfalien@xxxxxxxxx wrote:
> >> Hi all,
> >> I'm unsure how to describe this but I'll try.
> >> The following code works fine in its own PHP script;
> >> $mkdircmd = '/bin/mkdir /homes/'.$uid;
> >> exec($mkdircmd);
> >> But when placed in a larger PHP script being part of the  
> >> ldap_provisioning module in Drupal, the Drupal GUI is blank until I  
> >> do;
> >> $mkdircmd = "'/bin/mkdir /homes/'.$uid";
> >> ... were I surrounded the variable with "", which causes it to not  
> >> work.
> >
> > $mkdircmd = "/bin/mkdir /homes/$uid";
> > or
> > $mkdircmd = "/bin/mkdir /homes/${uid}";
> >
> > Should fix the syntax.
> >
> > I guess you've already solved the permissions problem on the /homes/  
> > folder (normally the web server would not be able to create such a  
> > path because of permission issues).
> >
> > Blank GUI - no idea. Anything in the error logs (php or apache) ?
> >
> > Maybe asking on a drupal specific list would be a better idea for  
> > that one.
> >
> > -- 
> > Postgresql & php tutorials
> > http://www.designmagick.com/
> 
> Thanks Chris.
> 
> I appreciate the response.  I was hoping my description wasn't too  
> vague because I don't really understand what I'm doing.
> 
> - aurf
> 
> 
> 
This might sound stupid because I've not played with Drupal, but what's
wrong with using the mkdir command in PHP instead of the exec call?


Ash
www.ashleysheridan.co.uk


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux