ge the permissions on the directory so the group has write
permissions:
sudo chmod -R 2775 /home/username/path/to/uploads
4. Then try the script again.
See if that works.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Tue, Mar 29, 2011 at 8:21 PM, Ethan Rosenberg wrote:
> At 05:33 PM 3/29/2011, Adam Richardson wrote:
>
>> >
>> > Thanks.
>> >
>> > What do you see if you run this? "Can't open or create file!"
>> >
>> > Ethan
>&g
th PHP.net. And, on the rare occasion you would need more speed than
your PHP script is providing, you'll be able to write you're own extension
to PHP using it's older brother, C.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
sed or custom), all requests should run over https instead of
http.
- Escape output according to context (html, attribute, or url.)
If you google the above topics, you'll find some great sites/blogs that
address these topics in detail.
Adam
P.S. - Or, you can just use my one-file
/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
I'm not sure what you're asking, but you can set the values of the POST
array directly within a script, for instance:
$_POST['new_key'] = 'new_value';
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
ork for managing the flow of the application, and I just
include the specific Zend files needed in a particular page.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
$puzzle[$i] = $puzzle_filler[mt_rand(0, ($puzzle_filler_length - 1))];
}
}
return $puzzle;
}
echo fill_puzzle($puzzle = "%ECARBME%TIPLUP%%%E%%", $puzzle_filler =
"ABCDEFGHIJKLMNOPQRSTUVWXYZ");
Happy Easter :)
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
hi, then use this.
> if (current_user_can('level_10')) : ?>
> http://www.google.com\"; target=\"_self\">My Link";
> ?>
>
>
>
>
>
hope this helps
Adam
On 2 May 2011, at 17:49, Michael Simiyu wrote:
> hello,
>
> i wa
Hi,
im building a cms and im currently thinking of a way to build an add page
function.
any one got some ideas on the best way to achieve this?
cheers
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
ope this is a better explanation for you guys.
cheers
On 2 May 2011, at 18:12, Ashley Sheridan wrote:
> On Mon, 2011-05-02 at 17:59 +0100, Adam Preece wrote:
>>
>> Hi,
>>
>> im building a cms and im currently thinking of a way to build an add page
>> function.
>
ystem.
if you have the time could you please tell me more how i could achieve a
modular template system?
cheers
On 2 May 2011, at 18:52, Ashley Sheridan wrote:
> On Mon, 2011-05-02 at 18:43 +0100, Adam Preece wrote:
>>
>> Hi,
>>
>> sure i will try to be more s
gt; At 7:19 PM +0100 5/2/11, Adam Preece wrote:
>> the reason, why i don't want to use word press and any other open source
>> solution, is that i want to learn how it is all done. im sure i can figure
>> it out myself but i would like to ask others and see how they would
-07 06:49:39 [image] => [user_access_id]
=> 1 )
How do i access each array within the array and throw out the data for each one.
im pretty confused on this one.
any help would be appreciated.
Adam
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
rray['row']
>
> Foreach($array['row'] as $key=>$values)
> {
> Echo $values.PHP_EOL;
> }
>
>
>
>
> Richard L. Buskirk
>
> -Original Message-
> From: Adam Preece [mailto:a...@blueyonder.co.uk]
&g
Hi,
> get_currentuserinfo();
>
> echo 'Welcome ' . "".$current_user->user_firstname . "."\n";
> echo '' ". $current_user->user_lastname . "".\n";
> ?>
On 7 May 2011, at 18:42, Michael Simiyu wrote:
> hey,
>
> some php 101 here guys :)
>
> i want to bold the first name and la
se nuanced differences will eventually enhance the experience
of those who are using screen readers.
So, while I don't necessarily recommend using a lot of and tags now,
it's likely that in the near future their use will again be encouraged as
HTML5 becomes better supported.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
e learned much from your posts, and
this discussion does not detract from that. However, I want to make sure the
developers subscribing to the list will consider the use of the and
tags as recommended by the W3C in (X)HTML5.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
Hi Ash,
I want to clarify a couple points.
On Tue, May 10, 2011 at 2:27 PM, Ashley Sheridan
wrote:
> On Tue, 2011-05-10 at 13:46 -0400, Adam Richardson wrote:
>
> Hi Tedd,
>
> How's it going? I'm very pleased with the emphasis on accessibility you
> bring to th
>
> On Sun, May 15, 2011 at 7:48 PM, tedd wrote:
At 1:46 PM -0400 5/10/11, Adam Richardson wrote:
>
>> The rest of the list does show you've read a fair amount in the past month
>> (just as others on this list, including me), but what does it do to
>> sp
On Wed, May 18, 2011 at 6:42 PM, Michelle Konzack <
linux4miche...@tamay-dogan.net> wrote:
> Hello ad...@buskirkgraphics.com,
>
> since YOU ARE an ADMIN, you should real know abut,
> HOW TO WRITE A NEW MESSAGE and not to hijack a SPAM thread...
>
What?
--
Nephtali: A simple, flexible, fast, an
l:* Don't rush. Carefully deliberate on the context, both in terms of
the expectations for input AND the nature of output. If you do this, you
eventually will get the level of security you're after (that, and fuzz the
heck out of something before you send it to Rasmus :)
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Wed, May 18, 2011 at 10:46 PM, Adam Richardson wrote:
>
> I'm a security expert by any means, as I've made mistakes in the past that
> have provided education the hard way!
>
Just to be very clear, this is a mistake (as the rest of the sentence
implies), and it should h
chieve higher levels of
security.
That said, you made some really nice points, and I'm hopeful Tedd considers
them carefully. His site is a nice resource for many PHP developers already
(especially those just starting out), and these changes can only make it
better.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Thu, May 19, 2011 at 8:51 PM, Alex Nikitin wrote:
> Hey Adam :)
>
> I devoted entire 3 minutes to glimpsing over the code and showing simple
> ways to fix them, you make excellent points, i simply didnt even look into
> them. You are absolutely correct in saying that sha1 a
cking it in
>> JavaScript. You need AJAX for that, don't you?
>>
>
> AJAX = JavaScript.
>
>
Well, no, Ajax is the combination of multiple technologies:
http://www.w3schools.com/ajax/default.asp
<http://www.w3schools.com/ajax/default.asp>Adam
--
Nephta
TF-8 and look for improper
encodings.
As far as a PHP function that already does this, I'm not aware of it, but
you could make a system call to "file" if your on Linux, as it tries to
automatically determine the encoding:
http://linux.die.net/man/1/file
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
PHP_SELF (dangerous)
$_SERVER['SCRIPT_FILENAME']
$_SERVER['REQUEST_URI'] (dangerous)
__FILE__
basename(__FILE__)
basename($_SERVER['SCRIPT_NAME'])
Try to enter the attack vector and you'll see PHP_SELF could be terrible,
but the basename option for script_filename and __FILE__ are immune.
Again, sorry for the confusion.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
hi all,
is it possible to dynamically build a key value pair array in php from a
database result?
if so how?
kind regards
Adam
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
=>category 1 [1] => 3=>category 2 [2] => 4=>category 3 [3] =>
5=>category 4 [4] => 6=>category 5 [5] => 7=>category 6 [6] => 8=>category 7
[7] => 9=>category 8 [8] => 10=>category 9 [9] => 11=>category 10
hope this makes sense?
kind rega
ns,
$replacement = $re_replaces, $subject = $php)) !== null) ? $temp_php: $php;
I'm confident you can easily use PHP to do this, and hopefully this info is
enough to get you started.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
d, if you wanted to write an extension to facilitate long
polling, you could, but given the natural latencies for these requests, I'm
not sure you'd find a significant benefit.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Fri, Jun 3, 2011 at 2:20 AM, 李白|字一日 wrote:
> is there an efficient way to hold the requests while loop is an expensive
> way in most cases.
You can call sleep(number_of_seconds_to_sleep) within the while loop to
lower the cost, so to speak.
> and i don't know how to notify the holding conn
On Fri, Jun 3, 2011 at 3:43 AM, 李白|字一日 wrote:
>
>
> 2011/6/3 Adam Richardson
>
>> On Fri, Jun 3, 2011 at 2:20 AM, 李白|字一日 wrote:
>>
>>> is there an efficient way to hold the requests while loop is an expensive
>>> way in most cases.
>>
>>
&g
Hi,
I'm running a site for which I need an authentication system. I have
already my own (that is too simplistic and not very secure).
I want some advice here. I checked PEAR, but as there are several
options there, I was not sure which one to choose. Here are my needs:
- Some sections of the site
Hi,
I can't set correctly the error display and reporting properties. I
don't know what i'm doing wrong.
Here is the section that i modified in php.ini:
-
display_errors = On
; Default Value: On
; Development Value: On
; Production Value: Off
display_startup_errors = On
; Default V
Hi,
When I try using DOMDocument I get the following error:
Fatal error: Class 'DOMDocument' not found in ...
I guess something has to be fixed in my php.ini?
Here is my php version:
# php -version
PHP 5.3.6 (cli) (built: Mar 17 2011 20:58:15)
Copyright (c) 1997-2011 The PHP Group
Zend Engine v2
d] => 10 [main_nav]
=> true [cat_name] => material range )
is it possible to build an array and use the [cat_name] as the key and assign
all the pages to that cat_name?
what im trying to achieve is a category of pages but i want the cat_name as the
key to all the pages associated to it
h
e_cat_id]
=> 9 [main_nav] => true ) [1] => Array ( [name] => metric iso threads [id] =>
29 [page_cat_id] => 9 [main_nav] => true )] ?
hope this makes sense
Adam
On 7 Jun 2011, at 22:25, Jasper Mulder wrote:
>
>
>> From:
ard L. Buskirk
>
> -Original Message-
> From: Adam Tong [mailto:adam.to...@gmail.com]
> Sent: Monday, June 06, 2011 9:49 PM
> To: php-general@lists.php.net
> Subject: [PHP] Can't use class "'DOMDocument"
>
> Hi,
>
> When I try using DOMDocument I get the
, David Nicholls wrote:
> On 23/06/11 12:23 AM, Adam Balogh wrote:
>
>> hi,
>>
>> you have a PM(/AM) in your date ($d[0]), so put an "A" (Uppercase Ante
>> meridiem and Post meridiem) format char to your $format variable.
>>
>> b3ha
>>
&g
.
CAT NAME
PAGE NAME ASSOCIATED TO THE
CAT NAME
and i cannot think of how i can structure an array to pass in to achieve this
and/or is it even possible :-/.
i hope this makes sense.
i'm truly stuck!
kind regards
Hi,
I wanted tu use php filters for validation to avoid regular expresions.
Is it possible that FILTER_VALIDATE_URL only checks if the string has
http:// and do not check for the format domain.something?
$url = 'http://wwwtestcom';
$url = filter_var($url,FILTER_VALIDATE_URL);
echo $url;
-
I'll try it on my PHP 5.3 web framework later today. Thanks for working on
this project!
Adam
2011/6/29 Ondřej Nešpor
> Hi everybody!
>
> We'd like to introduce you our documentation generator - ApiGen 2. We use
> it as a replacement for PhpDocumentor (that is not be
ut the example will NOT work via the web browser on my Apache 2
> (2.2.17) / PHP (5.3.5) Web Server!
>
>
Did you reload or restart apache after making the edits to php.ini? For
example:
$ /etc/init.d/apache2 restart
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
e. That
said, when you need more precision than PHP's standard handling of floating
points (http://php.net/manual/en/language.types.float.php), you can use
PHP's BC Math functions to enforce arbitrary precision:
http://www.php.net/manual/en/ref.bc.php
<http://www.php.net/manual/en/ref.bc
es.postgresql.org/pgsql-general/2008-05/msg00979.php>Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
de like that below:
function error_handler($errno, $errstr, $errfile, $errline)
{
// must take into account error suppressor (@) and not do anything with them
(they equal 0)
// http://framework.zend.com/issues/browse/ZF-3829
// check against current error_reporting bitmasks
if (!(\error_reporting
hi,
try to use print_r or var_dump to echo compound data type
/manual/en/intro.xmlreader.php
In terms of dealing with various forms of compression, I believe you con use
the compression streams to handle this:
http://stackoverflow.com/questions/1190906/php-open-gzipped-xml
http://us3.php.net/manual/en/wrappers.compression.php
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
ool though.
>
>
Well, Daniel,
I'll bet you never thought that your "Friday Distraction" would elicit such
a broad range of responses AND keep the commentary coming right through to
the next Friday.
Nice :)
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
ombination of set_error_handler() and within the handler using
error_log() works very well.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
think
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Make sure PHP has the permissions needed to delete and create files in the
directory.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
Hi,
*Heres the documentation:*
http://phpexcel.codeplex.com/releases/view/45412#DownloadId=212183
In user doc:
*4.2 Reading Only Named WorkSheets from a File*
*
*
and you can get all the sheet names:
http://www.auditbureau.org.au/a/Documentation/API/PHPExcel/PHPExcel.html#methodgetSheetNames
reverse order of operations using a decrypt function, I'd just like to
double check it before commenting.) By the way, I wouldn't recommend using
ECB mode unless you have a special circumstance:
http://www.quora.com/Is-AES-ECB-mode-useful-for-anything
Adam
(Sorry for the duplicate, Rick, I forgot to reply all the first time.)
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
>
> Can you post your decrypt function too?
>
> You create a random IV here, don't you need that IV to decrypt too?
>
>
You're normally right, Matijn,
However, ECB mode doesn't use an IV, so even though he's generating an IV,
it's not being used (and, the b
On Wed, Nov 30, 2011 at 4:25 PM, Matijn Woudt wrote:
> On Wed, Nov 30, 2011 at 10:18 PM, Adam Richardson
> wrote:
> > On Wed, Nov 30, 2011 at 4:14 PM, Matijn Woudt wrote:
> >
> >> On Wed, Nov 30, 2011 at 9:57 PM, Rick Dwyer
> wrote:
> >> > Hello a
on't change code that uses another convention, as I think
it's most beneficial to stay with the established conventions in any
codebase (unless you're establishing a new convention and refactoring the
entire code base.) This is just my general preference, and I don't believe
there is consensus as to the most appropriate.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
ly handles output escaping, input validation:
http://nephtaliproject.com/documentation/examples/contact.php
- And lots of other features that coincide with the general focus of
your words.
Given that work, I think it's fair to say that I do agree with several of
your general points f
ttps://bugs.php.net/bug.php?id=39968
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
Hi,
I am trying to read variables from input method.
I am using this tuorial:
http://www.lornajane.net/posts/2008/Accessing-Incoming-PUT-Data-from-PHP.
Here is my code:
I am using the firefox extension "poster" to run this example. GET
works fine but when using PUT, file_get_contents("php://inp
>
Yep, can be different:
http://stackoverflow.com/questions/279966/php-self-vs-path-info-vs-script-name-vs-request-uri
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Sun, Jan 29, 2012 at 11:38 AM, Tedd Sperling wrote:
> On Jan 27, 2012, at 12:45 PM, Adam Richardson wrote:
>
> > On Fri, Jan 27, 2012 at 12:09 PM, Tedd Sperling
> wrote:
> > On Jan 11, 2012, at 9:24 PM, tamouse mailing lists wrote:
> >
> > > Is there ev
Hi,
While not purely focused on PHP, I toss this out to the group because I
believe there are some novel, interesting points regarding the potential
benefits of using the goto construct as implemented in PHP:
http://adamjonrichardson.com/2012/02/06/long-live-the-goto-statement/
Adam
On Mon, Feb 6, 2012 at 4:07 AM, Tim Streater wrote:
> On 06 Feb 2012 at 07:47, Adam Richardson wrote:
>
> > While not purely focused on PHP, I toss this out to the group because I
> > believe there are some novel, interesting points regarding the potential
> > be
On Mon, Feb 6, 2012 at 4:25 AM, Adam Richardson wrote:
> On Mon, Feb 6, 2012 at 4:07 AM, Tim Streater wrote:
>
>> On 06 Feb 2012 at 07:47, Adam Richardson wrote:
>>
>> > While not purely focused on PHP, I toss this out to the group because I
>> > believe ther
On Mon, Feb 6, 2012 at 10:05 AM, Robert Cummings wrote:
> On 12-02-06 04:07 AM, Tim Streater wrote:
>
>> On 06 Feb 2012 at 07:47, Adam
>> Richardson>
>> wrote:
>>
>> While not purely focused on PHP, I toss this out to the group because I
>>>
tc.) and what
restrictions the language places on the construct. Again, the PHP version
of the construct is beneficially quite restrictive. For instance, some
people don't like giving programmers access to pointers just because you
can get into so much trouble with them, but I wonder if they'd be concerned
about Go's pointers, which don't allow pointer arithmetic, limiting one are
of potential trouble:
http://golang.org/doc/go_for_cpp_programmers.html#Conceptual_Differences
Interesting.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
at was probably a lot of work! Interesting that C++ was not allowed.
Thanks for the background information,
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
On Mon, Feb 6, 2012 at 11:58 AM, Tim Streater wrote:
> On 06 Feb 2012 at 09:48, Adam Richardson wrote:
>
> > On Mon, Feb 6, 2012 at 4:25 AM, Adam Richardson >wrote:
> >
> >> On Mon, Feb 6, 2012 at 4:07 AM, Tim Streater
> wrote:
>
> >> I disagr
of the time
creating designs that adapt accordingly.)
All this to say, I don't use PHP to handle this aspect of the development.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
n
>
> Good code uses Exceptions and try catch for that kind of scenarios.
>
Marco,
Do you know of any research (Human Factors, Bug Analysis, etc.) that
supports this? I'm certainly not saying that your assertion is incorrect.
However, I'm starting to compile relevant research
On Mon, Feb 6, 2012 at 3:50 PM, Adam Richardson wrote:
> On Mon, Feb 6, 2012 at 12:58 AM, Paul M Foster wrote:
>
>> This is sort of obliquely related to PHP.
>>
>> I don't have a smart phone, but I need to know a couple of things:
>>
>> 1) Do smart phones
c, hmvc,
> factory, commander etc..
Higher-order functions:
http://programmers.stackexchange.com/questions/72557/how-do-you-design-programs-in-haskell-or-other-functional-programming-languages
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
r checks to see what issues curl may be having:
$str = curl_exec($ch);
$error_no = curl_errno($ch);
curl_close ($ch);
if ($error_no != 0)
throw new Exception('There was an error retrieving the string contents
of the url \''.$url.'\'. CURL error number:'.$error
/simplexmlelement.construct.php
It is pretty convenient that SimpleXMLElement allows you to grab URL's, but
curl allows me to manually set a timeout limit (along with many other
things, although they're not necessarily needed in Rob's example), so I
tend to use curl in this type si
Saw this on the Clojure list and thought it was worth sharing here, too:
http://vimeo.com/36579366
Worth the hour of time to watch it, as it has some great ideas for
improving the experience of developers.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http
t I can't seem to find the
> perfect solution. :(
>
> Many thanks in advance for the help!
>
> Cheers,
> Micky
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Out of curiosity, why are yo
p
>
>
I tend to set up a custom error handler that throws exceptions
(set_error_handler()), then set up an exception handler
(set_exception_handler()) that logs the backtrace (or saves it to a db)
available using debug_backtrace().
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
ESSION[$key] : null;
} else {
return $_SESSION[$key] = $val;
}
}
Then, you can just write:
$first_name = s('first_name', p('first_name'));
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framework
http://nephtaliproject.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
ot;pass","description":{"hair":"brunette","eyes":"hazel","build":"petite"}}}
>
> jslint.com verifies this as good JSON (although I thought there had to be
> square brackets around child arrays).
Speaking to your belief
es of .62, .20, and .21 respectively.
> "
>
> http://www.coverity.com/html/press/open-source-code-quality-on-par-with-proprietary-code-in-2011-coverity-scan-report.html
Very nice! Thanks for sharing, Kirk.
Adam
--
Nephtali: A simple, flexible, fast, and security-focused PHP framewo
foreach( $images as $k => $v ) {
$k++; // increment k since it starts at 0, instead of 1
if ( strlen( trim( $v ) ) ) {
echo "http://www.theverseoftheday.info/store-images/";
. $v . "\" title=\"Image " . $k . "\">Image " . $k . "\r
Synopsis: I am writing a management system for a MSSql database driven
game, and I've run into an issue. The community site is located on a
remote webserver, to protect the actual server from any possible
vulnerabilities in the community application/forum application (as we
all have seen the re
r web hosting company before my site just goes away.
>
> Stanley G. Martin
> System Administrator
> Sprint - EAS Business Intelligence
> [EMAIL PROTECTED]
--
Adam Voigt
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi, I have a form where I have a user entering in the date in a numeric
string. For today they would enter 04212004 and so on...I'm working on
this date within mysql server, and mssql server handles dates as
04-21-2004 when you use convert(varchar,field,110). So how in PHP can I
change a vari
defined at http://us2.php.net/manual/en/ref.exec.php and none
> seem to have the desired effect.
>
> $tailed = shell_exec('tail -f /path/to/log');
> //$tailed = exec('tail -f /path/to/log');
> //$tailed = system('tail -f /path/to/log');
> print
>
> P.S. Stop top posting too.
--
Adam Voigt
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi, I have a randon group of numbers I need the average of. When I add
them up and divide by how many there are and print the result, I get a
lot of decimal places. The number comes out to look like 29.3529411765,
but I don't need that many decimal places. rounding to one decimal place
will
On Mon, 10 May 2004, Richard Davey wrote:
> Hello Adam,
>
> Monday, May 10, 2004, 7:03:36 PM, you wrote:
>
> AW> Hi, I have a randon group of numbers I need the average of. When I add
> AW> them up and divide by how many there are and print the result, I get a
> AW&g
Any recommendations?
>
> Thanks!
> Amanda
--
Adam Voigt
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
d a
copy:
$d = $MyArray;
If you only want $d to be an array when there is more than one entry
left do this instead:
if (count($MyArray) == 1) {
$d = array_shift($MyArray);
} else {
$d = $MyArray;
}
[1] http://www.php.net/array_shift
--
Adam Bregenzer
[EMAIL PROTECTED]
http://adam.bregenzer.net/
I've also heard the Perl Zealots claim the P could or does stand for
Perl, but ignore there Jedi mind tricks.
On Fri, 2004-05-07 at 11:00, Jay Blanchard wrote:
> [snip]
> Anyone know what LAMP stand for
> [/snip]
>
>
> All of us but you.
>
> Linux Apache MyS
ames for the buttons, for example:
--
Adam Voigt
[EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
";
> }
> }
$this->$a should be $this->a
same with '$b': $this->$b should be $this->b
--
Adam Bregenzer
[EMAIL PROTECTED]
http://adam.bregenzer.net/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
there. Thanks for any pointers, ideas, advice or help you may have.
-Adam R.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
lternatively you could do:
print "$item_1$item_2$item_4$item_5\n";
if ($i % 8 == 7) {
print "\n";
}
which would keep them the same color and add a blank row after every
eighth; again adjust $i as necessary to fit.
--
Adam Bregenzer
[EMAIL PROTECTED]
http://adam.bregenze
call was made from
> the parent script to the subroutine.
>
> I know that I can get the line number of the current script, but that
> doesn't tell me where the function was called from...
debug_backtrace[1] should get you everything you want and then some.
[1] http://ww
g about signed versus unsigned integers? What I really
> would like to do is convert that negative number (-71788), which I
> suppose is unsigned to a signed integer (3961595508) without having to
> convert it to hex, then back to decimal.
>
> Rene
--
Adam Voigt
[EMAI
Hi, I have a variable that is created using the date command:
$date = date("Ymd");
but its not working in my database this way (when I explicity enter
20040614 in my database, it works though). so I think PHP is making $date
a character variable, so how can I force or change the caste of $date
eh nevermind, I found settype();
:) thanks
On Mon, 14 Jun 2004, Adam Williams wrote:
> Hi, I have a variable that is created using the date command:
>
> $date = date("Ymd");
>
> but its not working in my database this way (when I explicity enter
> 20040614 in
901 - 1000 of 1427 matches
Mail list logo