You could add a line in to your code:
include ldap-blue-pill;
That should fix any performance issues ;)
(note, I did try posting earlier with a much funnier reply, but the email was
rejected because of a certain 'v' word!)
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message
(sorry for top post)
As he mentioned using lynx ( and I'm assuming the OS rather than the browser
here, as I'm not aware of the browser having those sorts of capabilities) then
could it be that all the pear packages don't exist?
Mostly, pear packages can just be copied into your app
That won't accept dozens of different types of email addresses. It won't even
match some value domains.
Valid email addresses can contain virtually any character in the local part
(although in the main they will require being inside quotation marks), and the
@ symbol is included in that!
you could use the chown method in php, which should do what you need.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Moses jam...@gmail.com
Date: Tue, Jan 18, 2011 09:44
Subject: [PHP] [PHP]: permission problem www-data
To: php-general@lists.php.net
Hi Everyone,
I
:17
Subject: [PHP] [PHP]: permission problem www-data
To: a...@ashleysheridan.co.uk a...@ashleysheridan.co.uk
Cc: php-general@lists.php.net
I can't think of anything except using top or ps. If you can't guarantee what
process runs what individual script, are you able to just track them all
globally, and check for differences as you start and stop scripts. Perhaps run
certain scripts under different users which should give them
(sorry for top post, still not worked out how not to on phone)
Can you not just code it like you normally would any app that doesn't use a
framework? I've been writing some cli data importers at work. Basic really,
with only classes used that I need, no framework needed (its very simple) and
Sorry for top-post, on phone.
What about mobile phone numbers (cell phones you call them in the US) do they
conform to the same format? I know there have been times myself when I've been
without a landline number leaving me with only my mobile as a means of contact.
Thanks,
Ash
Erm, you say regex is overkill, then use one in your example!
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Al n...@ridersite.org
Date: Fri, Dec 31, 2010 15:53
Subject: [PHP] Re: Regex for telephone numbers
To: php...@lists.php.net, php-general@lists.php.net
On
On a slight tangent, but is that signature why I'm not able to read any of
michelles emails on my phone? For some reason, only her emails get stuck and
won't download, so I have to wait til someone else replies.
To answer the question on this, I've not yet seen a cross platform answer to
this
You've missed a crucial part of php; its not a client-side language, its all
run on the server. So you can't have a music player built in it running in a
web browser. For that you need something like flash or java.
There is a way potentially with html5, but not all support the audio tag
(Apologies for top posting; on my mobile just now.)
Not true. Refactoring code is one of the main tasks of a developer. None of us
produce perfect code, and some code is less perfect than other code. It's
instinct to want to fix bad code when we're maintaining it or having to add new
features
I'm not sure what this line us all about:
if (mysql_num_rows($result) == !'0')
You're basically saying; if the number of rows is equal to the not of the
string 0, what I think you may want in this case is just != 0.
The next line is causing your problem though. You're grabbing the first row
Is your server even set up to recognise .inc files as php? You can't just put
any old extension on and expect the server to know what to do with it.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Tamara Temple tamouse.li...@gmail.com
Date: Sun, Dec 19, 2010 17:07
How are these variables being given their values by php? If you're making use
of register_globals then you're asking for problems.
Perform some sanity checks on your data, like using a regex of /^\d+$/ to check
for numerical values, and turn globals off; its a security breach waiting to
And the obvious difference, print returns true on success. I'm not sure what
would cause an echo it print to ever fail, so it really doesn't make a huge
difference.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Alexandru Patranescu dreal...@gmail.com
Date: Sun,
You need to set it in the header request you make. Putting it in the script
you're using as a spider with ini_set won't do anything because the Target site
doesn't know anything about it.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Ron Piggott
It's always best practice to have a staging server for testing these sorts of
things.
If in doubt, run it in a transaction, but don't commit it, I.e. roll it back.
That way you'll see if it would run but nothing actually changes.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message
Leskovšek legr...@gmail.com
Cc: a...@ashleysheridan.co.uk, HallMarc Websites
sa...@hallmarcwebsites.com, Dotan Cohen dotanco...@gmail.com, David
Mehler dave.meh...@gmail.com, php-general php-general@lists.php.net
On Tue, Nov 16, 2010 at 3:36 PM, Grega Leskovšek legr...@gmail.com wrote:
I tried
What about something like this:
$pos = (strpos(' ', $string, 76))?strpos(' ',$string, 76):strlen($string);
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Ron Piggott ron.pigg...@actsministries.org
Date: Sun, Nov 14, 2010 20:48
Subject: [PHP] Re: String manipulation
Have you checked for any cookies left by that website?
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: 肖晗 xiaohan2...@gmail.com
Date: Fri, Nov 12, 2010 15:14
Subject: [PHP] question about preventing polling for more than once
To: php-general@lists.php.net
I noticed
You could do it using the 1234; type codes, or copy it directly from another
source, like a character map program.
Bear in mind that if you do the latter, you'll need to output a utf 8 meta tag
with the html output too.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
It's not to do with hosting, its an auto reply when you email sascha.braun
which gave the same aware reply to me, and I'm on a Linux box at home!
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Ben Brentlinger b...@benbrent.com
Date: Mon, Nov 1, 2010 08:29
Subject:
What is the code you're using now? You have a syntax error, but without seeing
the code, we are all left to guessing what the problem could be.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Ben Brentlinger b...@benbrent.com
Date: Sun, Oct 31, 2010 03:56
Subject:
This isn't a php question but a mysql one. Take out the lower() part of the sql
statement, as like is case insensitive by default.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Dr Michael Daly g...@holisticgp.com.au
Date: Sun, Oct 31, 2010 04:47
Subject: [PHP]
This can only be done with javascript, as the iframe is client-side, which php
knows nothing about.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Karl DeSaulniers k...@designdrumm.com
Date: Sun, Oct 31, 2010 03:32
Subject: [PHP] include html
To: php-general
If its Apache on Linux (as most hosting will be) then the user will generally
be either apache, www, or http.
Thanks,
Ash
http://www.ashleysheridan.co.uk
message -
From: Ryan Sun ryansu...@gmail.com
Date: Sun, Oct 31, 2010 18:43
Subject: [PHP] a question about user and permission on linux
To: a...@ashleysheridan.co.uk a...@ashleysheridan.co.uk
Then whats the user of php?
On 10/31/2010 2:39 PM, a...@ashleysheridan.co.uk wrote:
If its Apache
Have you tried using the utf8 meta tag rather than using the htmlentities()
function? That should solve the first issue, as I reckon the problem lies with
the way your encoding the filename.
Linux filesystems have far less limitations on filenames, so it could be that
windows is doing
18:22
Subject: [PHP] Character encoding hell
To: a...@ashleysheridan.co.uk a...@ashleysheridan.co.uk
Cc: php-general php-general@lists.php.net
Have you tried using the utf8 meta tag rather than using the htmlentities()
function? That should solve the first issue, as I reckon the problem lies
Bit late to this one, but what about an mvc framework like codeigniter? It's
perfectly acceptable to use if statements and loops in the view, which would
solve your problem. You can set a trigger variable in the controller, and in
the header view, check to see if its set and output your
That's as bad as an if!
What about using settype() on the string? I've not tested it, but it looks like
it should do the trick.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Russell Dias rus...@gmail.com
Date: Thu, Oct 21, 2010 10:51
Subject: [PHP] My truth comes
truth comes out [1]
To: a...@ashleysheridan.co.uk a...@ashleysheridan.co.uk
Cc: php-general@lists.php.net
I'm curious to know why 'thats as bad as an if' ?
It's simple, concise, understandble and does the job. So, I'm curious
to know why exactly its bad?
On Thu, Oct 21, 2010 at 8:01 PM
Steady on now, this thread started as a php question, and has only deviated a
little. Most people on the list don't work purely with php, and I for one dont
mind the odd off-topic thread, especially when the majority of the list is made
of good php threads.
Thanks,
Ash
It's most likely because both cli and web modules are using different php.ini
config files. See what the output of a phpinfo() call in both browser and
command line.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Scott Baker bak...@canbytel.com
Date: Mon, Oct 18,
Linux can be run as a GUI, using a window manager.
Aside from that, have a look at the manual pages on php.net, which give some
good examples of how to use the various mysql functions.
Also, on your development machine, its a good idea to turn on errors, as it can
indicate where these problems
I wouldn't really use a while statement for this, but a for loop instead, as it
needs less code:
?php
echo select;
for($i =1;$i=12;$i++)
{
$dateformat = date(M, mktime(0,0,0, $i,0,0));
echo HTML
option value=$i$dateformat $i/option
HTML;
}
echo /select;
?
The other code
That's probably it then! Some browsers make multiple requests to speed up
rendering of a page.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Alexis phplis...@antonakis.co.uk
Date: Tue, Oct 12, 2010 17:16
Subject: [PHP] Scripts running twice
To:
That's the same query.
One thing I did notice (and I wasn't sure if it was a typo as I saw a few in
the original post) but you've used a period instead of a comma to separate the
values in the query.
It shouldn't produce the error you're seeing, but sometimes you never know!
Thanks,
Ash
How do you mean? Did you want to process payments? Or wad it more of an actual
banking thing you needed? I've not heard of hbci before, so can't offer much
information back.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Stephan Ebelt s...@shared-files.de
Date:
It will only work if your listing supports php, but you should just be able to
put the whole sure up on your hosting, give the upload directory the correct
permissions ( its most likely a more secure Linux hosting than insecure windows
hosting)
Thanks,
Ash
http://www.ashleysheridan.co.uk
Surely it would have been a bit more sensible to work out the time the
programmer had spent on the project and then calculate it as a percentage of
the total time that programmer would spend on it to complete it (which might
not be the whole duration of the project)
Also, counting code lines
To: a...@ashleysheridan.co.uk
Cc: chris h chris...@gmail.com, Gary gp...@paulgdesigns.com,
php-general@lists.php.net
As pointed out echo $insertSQl should help you locate many trivial
problems. But using PDO will avoid these kind of problems
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit
Have you installed the php mysql module? Basically, it tells php how to connect
to mysql.
This question has come up a few times this week, have you tried installing
something like xampp or easyphp rather than the individual software components:
Apache, php mysql.
Thanks,
Ash
Does phpDocumenter not do the trick? I must admit, I've not tried anything
specific to 5.3 (i can imagine the namespace thing would be a major part if the
documentation) but its served me well with other php5 code.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From:
Still hit and miss though, outlook is just one if many email clients out there.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Richard Quadling rquadl...@gmail.com
Date: Tue, Sep 28, 2010 10:17
Subject: [PHP] Php Newsletter script
To: a...@ashleysheridan.co.uk
I'd also like to add to that:
$array = array();
$array[] = 'text';
$array[2] = 123;
$array[] = 'hello';
Would output:
$array(
0 = 'text',
2 = 123,
3 = 'hello',
);
Note the missing index 1, as php makes a numerical index that is one greater
than the highest already in use. As the index 2 was
Suse uses yast2 iirc, which you can use to list and install php modules. Search
for 'php' in yast software manager module.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Patrick Serru patr...@serru.net
Date: Thu, Sep 23, 2010 14:06
Subject: [PHP] module add on Suse
add on Suse 10.3
To: php-general@lists.php.net
Le jeudi 23 septembre 2010, a...@ashleysheridan.co.uk a écrit :
Suse uses yast2 iirc, which you can use to list and install php modules.
Search for 'php' in yast software manager module.
--
Thanks Ash,
I id'nt find any iirc
If you want to prevent certain extensions then just flirt then out from the
$_FILES array before you copy them out of the temp directory, as that is where
they should be uploaded ready for your script to process.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From:
For a month selector, using a loop to output the months is good, as you can
then within the loop check for that value sent and set the selected html
attribute for that select element.
I should warn you that your code will throw a warning when no data has been
posted to it. Consider using
It's object oriented code. $code is an instance of class, and do_command() is a
method if that class. I'd advise reading up on oop php.
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Adam Williams adam_willi...@bellsouth.net
Date: Fri, Sep 10, 2010 19:27
Subject:
Node.js, wouldn't that be javascript rather than java? :P
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Joshua Kehn josh.k...@gmail.com
Date: Fri, Sep 10, 2010 19:32
Subject: [PHP] newbie question about code
To: Bob McConnell r...@cbord.com
Cc: Adam Williams
Could it be that there are connection limits on the remote server?
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: Bob McConnell r...@cbord.com
Date: Wed, Sep 8, 2010 18:24
Subject: [PHP] Broken pipes, time outs, PHP, and mail
To: php-general@lists.php.net
From: Dave
In order to help we really need to have a look at the code in question. You say
the code is derived from another class you downloaded. Are you able to post the
important bits of it in an email, or put it all on a pastebin?
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
PHO won't automatically include a class file by default. You either need to
manually include it with a require, include it or require_once line, or use an
automagical include script. As it stands, you're getting the error because php
doesn't know where your class is.
Thanks,
Ash
I think you should not focus so much on the file extension, as that is mostly
meaningless if someone wanted to attack your system.
Instead, you could wrap a call to the command line 'file' command, which gives
mostly accurate information about a file. Basically it reads the first few
bytes to
: Mon, Sep 6, 2010 16:13
Subject: [PHP] Hi
To: a...@ashleysheridan.co.uk a...@ashleysheridan.co.uk
Cc: Jordan Jovanov jovanovj...@gmail.com, php-general@lists.php.net
On 6 September 2010 15:04, a...@ashleysheridan.co.uk
a...@ashleysheridan.co.uk wrote:
I think you should not focus so much on the file
http://www.bash.org/?quote=76416
Meant to post this on Friday, but it works well here too!
Thanks,
Ash
http://www.ashleysheridan.co.uk
- Reply message -
From: chris h chris...@gmail.com
Date: Sat, Sep 4, 2010 19:42
Subject: [PHP] a test (list is too quite)
To: php-general@lists.php.net
59 matches
Mail list logo