ions.info/ or any of the numerous other
sites with regex info :)
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
BeWelcome/Couchsurfing: Fake51
Twitter: http://twitter.com/kafe15
--
PHP General Mailing List (http://www.php.net/)
To
task, but there's no
way around it.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
BeWelcome/Couchsurfing: Fake51
Twitter: http://twitter.com/kafe15
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
/line 40
You're lacking the starting delimiter '/'
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
BeWelcome/Couchsurfing: Fake51
Twitter: http://twitter.com/kafe15
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi Tanel,
1. only letters
$str = 'helloworld';
if(preg_match("/^[a-zA-Z]*$/",$str))
echo "only letters";
else
echo "failed";
2. only letters and spaces
$str = 'hello world';
if(preg_match("/^[a-zA-Z\s]*$/",$str))
echo "only letters and spaces";
else
echo "failed";
Regards
Peter.M
Tanel T
On 1 June 2010 17:33, Ashley Sheridan wrote:
> On Tue, 2010-06-01 at 16:31 +0100, Richard Quadling wrote:
>
>> $re1 = '/^[a-z]++$/i';
>> $re2 = '/^[a-z ]++$/i';
>>
>>
>>
>> --
>> -
>> Richard Quadling
>> "Standing on the shoulders of some very clever giants!"
>> EE : http://www.experts-exchang
On 1 June 2010 15:58, Paul M Foster wrote:
> On Tue, Jun 01, 2010 at 09:52:54AM +0200, Peter Lind wrote:
>
>> Just wondering: seems there's a bit of a misunderstanding going on
>> here. Are you talking about storing credit card information in a way
>> such
fill in the details on a monthly basis?
If 1) then the above points apply and you should not store the data,
period. If 2) then I would assume the situation is somewhat different
- though, not knowing the laws from the US I wouldn't really know.
Regards
Peter
--
WWW: http://plphp.dk / http:
don't. It's downright stupid to do
so, because it's a huge risk for very little gain. 3) farm out risks
like these to companies that specialize in dealing with them - you
will with 100% certainty not be able to do as good a job as these.
The question to ask is not: how to store cr
On 27 May 2010 18:21, la...@garfieldtech.com wrote:
> On 5/27/10 11:13 AM, Peter Lind wrote:
>
>>> I'm overriding the method because I want to change the *implementation*.
>>> The *interface* of it, which is documented in the docblock, should not
>>> chang
On 27 May 2010 17:57, la...@garfieldtech.com wrote:
> On 5/27/10 10:43 AM, Peter Lind wrote:
>
>> You're overriding the function. IDEs should *not* show the parent
>> documentation, because the parent function does *not* get called. It
>> only gets called if you do a
ernative I'm missing that
> doesn't suck? What do most people do to deal with this trainwreck?
>
Personally, I think this issue stems from a wrong way of thinking
about methods and overriding them. You're either not documenting the
overriding methods properly or overriding met
On 25 May 2010 21:50, Bruce Gilbert wrote:
> yea, not sure why my Query isn't returning a value though? If I don't
> use date(), what should I use?
The output of strtotime() is an int - specifically a number of
seconds. Subtract two number of seconds from each other and what do
you get? Furthermo
ng at. The first is the null value
you're getting, which will invalidate the whole thing. The second
problem is that you were looking for output along the lines of "60
minutes" but you're using date() which as the second parameter expects
a unix timestamp - not two timestamps subtra
uot;])/60)
> . "";
>
No. Assuming that your timestamp is of the -mm-dd HH:ii:ss form,
you need to do (strtotime(["submit_timestamp"]) -
strtotime($row["login_timestamp"]))/60.
Regards
Peter
>
> On Tue, May 25, 2010 at 10:01 AM, Peter Lind wrote
do the job:
http://dev.mysql.com/doc/refman/5.1/en/date-and-time-functions.html#function_timediff
Otherwise, just do strtotime(endtime) - strtotime(starttime) / 60.
That's the difference in minutes.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.co
On 21 May 2010 10:47, Lester Caine wrote:
> Peter Lind wrote:
>>>
>>> The problem here is that PHP still does not know how to handle UTF8
>>> > properly
>
>> It's not*just* that PHP isn't handling utf8 perfectly. Encoding
>> between dat
ot *just* that PHP isn't handling utf8 perfectly. Encoding
between database and server is a rather complex issue, you're dealing
with:
* database encoding
* database connection encoding
* php internal encoding
* output encoding
Messing up just *one* of these will give bad output -
"text/javascript"',
> 'language="vbscript\"',
> 'type="text/vbscript"',
> 'language="vbscript"',
> 'type="text/tcl"',
> "error_reporting\(0\)",//Most hacks I've seen make certai
should consider using form tokens, so you don't
get caught by double submits and cross site form posts, etc.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
-
ouble to read!
>
> Regards,
> Ferdi
>
Easiest is (if you're on *nix) to setup an MTA like postfix or exim to
relay emails from the localhost. Then get a good mail library like
Swiftmailer and point that to the local MTA. Typically, that's about
the setup you need to do (if you
On 18 May 2010 13:43, Ashley Sheridan wrote:
>
> On Tue, 2010-05-18 at 13:46 +0200, Peter Lind wrote:
>
> On 18 May 2010 13:32, Ashley Sheridan wrote:
> >
> > On Tue, 2010-05-18 at 13:09 +0200, Peter Lind wrote:
> >
> > On 18 May 2010 12:35, Andre
On 18 May 2010 13:32, Ashley Sheridan wrote:
>
> On Tue, 2010-05-18 at 13:09 +0200, Peter Lind wrote:
>
> On 18 May 2010 12:35, Andre Polykanine wrote:
> > Hello Peter,
> >
> > Hm... I see I need to specify what I'm really doing. Actually, I need
> >
On 18 May 2010 12:35, Andre Polykanine wrote:
> Hello Peter,
>
> Hm... I see I need to specify what I'm really doing. Actually, I need
> to change the letters in the text. It's a famous and ancient crypting
> method: you divide the alphabet making two parts, then you ch
7;');
>>
>> echo preg_replace
>> ($patterns, $replacements, $text);
>> ?>
>>
>> Output:
>> We want to replace > with the <>tag> and with
>> the
>>
>> Look what happend with BOLD.
>>
>> Is there an
Unable to select
> database:".mysql_error());
>
>
> }
> ?>
>
> that will not work on my rss feed. But it does work on my main page which
> uses the dbconnect script. The only error that I'm getting is the one set in
> my dbconnect call... "Could not con
is, to most people, means coming up with a meaningful way of naming
files and classes so you can parse the class name and then know where
to grab the file from (Zend naming for instance:
Zend_Db_Table_Abstract gets parsed to Zend/Db/Table/Abstract.php). So
no, you don't have to stress the server
You need to remove the space after & (you're constantly inserting
blank spaces in your string for no reason) as I'm guessing you don't
have any spaces inside the data you're dealing with.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.l
ctually what you are doing with "data". The browser may be just
> deleting the +. Not positive.
>
> & lastname="+ lastname +"
>
> needs to be
>
> &lastname="+lastname+"
>
As it's javascript, those spaces are not in string: they'
gt; ));
> } else return chaseToReference($array[$path[0]], array_slice($path, 1));
> } else {
> return goodResult($array);
> }
> }
>
> function result(&$r) {
> return $r['result'];
> }
>
> function goodResult(&$r) {
> $r2
ses :(
>
Don't rely on IP addresses staying the same for a user, it's not safe
in any way and not needed anyway. Karls method is probably the best
bet - just remember to record "last accessed time" so anyone not
accessing for more than 15-20 minutes will succeed if trying to log
to match is dynamic or in a
dynamic string. When you know what the output will be and can match
it, the str* functions are much better as they are much more
efficient.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/
for rewriting and it does it well. Doing the same job in
PHP is likely to use more resources and be more complex.
In short: using mod_rewrite for url rewriting is not "overkill" - it's
using the proper tool for the job.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.d
On 12 May 2010 17:07, Paul M Foster wrote:
>
> Because your public internet server disables its use.
>
And once more I'm reminded of just how happy I am with my VPS and my
dedicated server.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedi
you're asking then.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Output looks pretty typical for something encrypted/obfuscated. As the
script will run, it needs to unpack itself ... so you can write
automated unpackers for this kind of thing if you want.
Best go with Phpsters advice of the contract, you'd be a lot better
off (assuming the court system works).
; somesite.com/scriptname/var1/var2/var3
>
> that seems to work well with no use of the rewrite module.
>
And why wouldn't you want to use mod_rewrite? It's an extremely
powerful tool that does the job really well.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: htt
it doesn't.
I doubt anyone is proposing the "one script with all classes and
functions" approach. Several files is obviously a preferable method.
How you structure the code is completely different though: do you
allow a user to run blog.php directly or do you funnel everything
throu
tact page.
> Far easier to keep everything a bit more modular. That way, if you need
> to update something, you update only a small part of the site rather
> than some huge core file.
>
> But, if your needs are even more simple, say it's just a very small
> brochure website y
st
>> Innovation distinguishes bet ... ... (ask Steve Jobs the rest)
>>
>
>
> I have to ask, why do you want to do that? Wouldn't it be easier to
> offer your application as a system that only you host. That way, the
> end-user never gets to see your PHP code.
&
On 9 May 2010 23:56, Nathan Nobbe wrote:
> On Sun, May 9, 2010 at 3:25 PM, Peter Lind wrote:
>>
>> On 9 May 2010 23:21, Daniel Kolbo wrote:
>> > Hello,
>> >
>> > I've defined a __call() method inside a class. Within the __call()
>> > meth
e same
object is going to result in ... your __call() method getting called
again. You need to map the $method to whichever class methods you
*actually* want to call, instead of blindly trying to reissue the
call.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www
ied everything, based on an xpath from
> Firebug (Firefox plugin), but kept getting NULL.
>
try //table//font - that should give you all the font elements in
table elements. Given your layout, you're then looking for
$list->item(3)
Regards
Peter
--
WWW: http://plphp.dk / http
On 8 May 2010 00:39, Nathan Nobbe wrote:
>
> hmm, both the strings seem to work fine on my laptop:
>
+1. Have no problem with either string
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchs
d rather have it in UTF-8. But
> utf8_de/encode won't help me there, I'm afraid.
>
http://dk2.php.net/manual/en/function.mb-convert-encoding.php might be of help.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://
On 6 May 2010 10:47, Auto-Deppe C. Hänsel wrote:
> Hi guys and girls,
>
> okay, this is a dumbnut question I wouldn't bother asking but I really
> did hit a spot now where I am totally wedged up in my head and can't think
> straight anymore... so the, I bet easy, answer to my question escapes
ng the middle tier object
> 24. $this->mBoCatalog = new BoCatalog();
> 25. //if ProductID exists in the query string, we're viewing a
> product.
> 26. if(isset($_GET['ProductID']))
> 27. $this->mSelectedProduc
r single letter: "g" or "h,k" or "r,s,t" or whatever - all the same
> result.
>
This was discusses a little while ago, have a look at
news.php.net/php.general/303839/Logical-reason-for-strtotime-east-and-strtotime-west-returningvalid-results.html
and the respon
gt; I did something like this in VBA, but I want to create something for PHP.
>>
>> How can extract an am or pm from the input string, convert to 24 hours for
>> calculations, then convert back to 12 hour am/pm format in PHP?
>>
Consider the DateTime class, might suit your needs.
http
n't be any problems using a classes constants in the definition
of an array in the same class. However, to avoid possible extra work
down the line, I wouldn't use Pg_Error::YOUR_CONSTANT inside the
class, I'd use self::YOUR_CONSTANT
Regards
Peter
--
WWW: http://plphp.dk / http://pli
uniqueness constraint violated',
> Pg_Error::getMessage(Pg_Error::INTEGRITY_CONST_UNIQUE));
> and I can't see what I've done wrong :(
>
In your code snippet, you do not declare
Pg_Error::INTEGRITY_CONST_UNIQUE - and equally to the point, in the
class you only use I
On 27 April 2010 18:21, tedd wrote:
> At 4:31 PM +0200 4/27/10, Peter Lind wrote:
>>
>> While I love to rant at stupid users, the truth is probably that
>> programmers are the ones who should take courses in how users think.
>> In the end, if I fail to understand my u
On 27 April 2010 16:24, Paul M Foster wrote:
> On Tue, Apr 27, 2010 at 04:13:20PM +0200, Peter Lind wrote:
>
>> On 27 April 2010 16:07, Paul M Foster wrote:
>> > On Tue, Apr 27, 2010 at 03:41:04PM +0200, Peter Lind wrote:
>> >
>> >> On 27 April 2010 1
On 27 April 2010 16:07, Paul M Foster wrote:
> On Tue, Apr 27, 2010 at 03:41:04PM +0200, Peter Lind wrote:
>
>> On 27 April 2010 15:36, Paul M Foster wrote:
>> > On Tue, Apr 27, 2010 at 10:42:03AM +0200, Gary . wrote:
>> >
>> >> How do you guy
that, I'd get
mighty annoyed with the software, and after a while would definitely
look for alternatives. Whether or not there's a coding problem, you
have to look at the situation from the point of the user: a complete
failure with no information is like a BSOD/TSOD ... and we all know
the
other part of the block, I receive so many
> echo's as iterations the while do ( this is logical ). However I don't
> understand why the echo is printed above the while even when I put it
> after the while and out of the while's block.
>
Check your html for broken html table code.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
r without confusing. There's
nothing worse than "This didn't work, sorry" - why didn't it work??
Was it my fault? Can I get it to work somehow?
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.fl
On 26 April 2010 18:58, Michelle Konzack wrote:
> Hello Pete,
>
> Am 2010-04-26 17:04:32, hacktest Du folgendes herunter:
>> Is it possible that the space is a new-line (or a carriage-return) ?
>
> grmpf! -- That it was...
>
>> preg_replace('/\s+$/','',$FILE);
>
> Works now!
Consider a trim,
On 26 April 2010 13:23, Ashley Sheridan wrote:
>
> On Mon, 2010-04-26 at 13:20 +0200, Peter Lind wrote:
>
> On 26 April 2010 12:52, Ashley Sheridan wrote:
> > I've been thinking about this problem for a little while, and the thing
> > is, I can think of ways of d
I could do, or do you think I'm
> seeing problems where there are none?
Use htmltidy or htmlpurifier to clean up things. I.e. grab the amount
of content you want, then use one of the tools to repair and clean the
html.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http:
but the stuff with
>
> is_file($isfile)
>
> is not working... If I enter the file in place of $isfile, then it is
> working. Quoting of $isfile does not work too.
>
> What have a overseen?
var_dump($isfile);
Don't make assumptions of what the value is, just ch
oping the setup is the same under Vista as *nix)
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On 23 April 2010 18:26, Ashley Sheridan wrote:
>
> On Fri, 2010-04-23 at 12:25 -0400, Adam Richardson wrote:
>
> On Fri, Apr 23, 2010 at 12:21 PM, Peter Lind wrote:
>
> > On 23 April 2010 18:10, Ashley Sheridan wrote:
> > > I think for now I'll just resort
set are fine, as long as you don't use them
for everything (i.e. 5 magic calls per request will do very, very
little to your app, whereas 1000 per request will have some
significance on a site with lots of users).
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linked
php.net/curl should be able to do what you want.
file_get_contents with a proper stream context should also work (have
a look at functions like http://dk.php.net/manual/en/context.http.php
)
Regards
Peter
On 23 April 2010 17:18, Robert P. J. Day wrote:
>
> i'm sure this isn't
s (it's also directed at getting Zend
certified, so it's covering the stuff you need to know for that, not
connected things).
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake5
On 22 April 2010 17:05, Ashley Sheridan wrote:
>
> On Thu, 2010-04-22 at 17:06 +0200, Peter Lind wrote:
>
> On 22 April 2010 12:14, Ashley Sheridan wrote:
> > I believe Dan Brown mentioned a very good reason why this is not as
> > simple an issue as just changing the re
ether or not a 'reply-to'
is used.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Thu, 22 Apr 2010 10:49:11 -0400
Peter van der Does wrote:
>
> My take on it:
>
> $Items=1252398;
> $MaxInGroup=30;
> for ($x=$MaxInGroup; $x>1;$x--) {
> $remainder=$Items % $x;
> // Change 17 to the max amount allowed in the last group
> if
ot;\n";
echo $remainder;
break;
}
}
--
Peter van der Does
GPG key: E77E8E98
IRC: Ganseki on irc.freenode.net
Twitter: @petervanderdoes
WordPress Plugin Developer
Blog: http://blog.avirtualhome.com
Forums: http://forums.avirtualhome.com
Twitter: @avhsoftware
--
PHP Gen
tp://helpme.att.net/pdf/uverse/uverse_hsi_qsg_english.pdf
>> >
>> >
>> >
>> > I thought with PEAR, you don't need to do that anymore. Or, am I wrong?
>> >
>>
>> Read the PEAR documentation:
>> http://pear.php.net/manual/en/package.ma
df
>
>
>
> I thought with PEAR, you don't need to do that anymore. Or, am I wrong?
>
Read the PEAR documentation:
http://pear.php.net/manual/en/package.mail.mail.factory.php
You can use other backends than just 'mail' - try using the smtp and
fill in your smtp settings
On 21 April 2010 20:09, Michelle Konzack wrote:
> Hello Peter Lind,
Hi Michelle
> Am 2010-04-21 15:47:54, hacktest Du folgendes herunter:
>> And waste time every single time you post to the list ... why do
>> people become programmers/developers again? To end creating tech
of choice": well, where's my freedom
of choice? I can't use 'reply' as I want to, so it's effectively
reduced *my* freedom).
Quick guess is by now, the majority of people clicking "reply" *mean*
to reply to the list but in effect reply to the OP
On 21 April 2010 15:41, Dan Joseph wrote:
> When you hit reply all, just take out all the other addresses and leave the
> list one in there. The list was setup like this years ago on purpose, and
> they've stated in the past they don't want to change it..
And waste time every single time you pos
On 21 April 2010 14:38, Hans Åhlin wrote:
> Why change the way that has been around for years and adopted by
> multiple e-mail lists?
> It feels like it's more problem to change the way for thousands of
> users just to satisfy a couple of few.
David was venting based on a discussion in another th
On 21 April 2010 12:38, David McGlone wrote:
> Maybe it's not how the list is set up, but instead how people are
> replying to the list.
One would think that in a tech world where most programmers/developers
try to minimize the workload and "a good programmer is lazy" is seen
as meaningful and/or
On 21 April 2010 04:25, Alice Wei wrote:
> Well, from my experience with Ubuntu, looks like that it does not do that.
> Unless, I am doing it wrong?
So did you try using the 'smtp' backend and passing all the connection
details rather than 'mail'?
--
WWW: http://plphp.dk / http://plind.dk
Link
all, mail servers keep log files. You should look for the
>> log files to see if the mail server has sent your mail properly or is
>> experiencing problems (those may not feed back into PHP).
>>
>> Regards
>> Peter
>>
>> --
>>
>> WWW: http://plphp.
>> Adam
>>
>
> Are Perl, JSP, Ruby, etc. able to ignore the dir ownership and write
> permissions on a Linux/Apache system?
>
I've seen an install of Trac hacked by a file-upload - it managed to
write a cron job, which then wrote to other files. It's not ju
On 19 April 2010 17:40, Andrew Ballard wrote:
> On Mon, Apr 19, 2010 at 11:14 AM, Peter Lind wrote:
>> On 19 April 2010 17:00, Andrew Ballard wrote:
>>> On Mon, Apr 19, 2010 at 9:45 AM, Manolis Vlachakis
>>>> 1. $save=split("[|;]",$listOfItems);
>>
ten when outputting csv, I usually do something like this:
>
>
> $fp = fopen('php://output', 'w') or die('Could not open stream');
>
> foreach ($data as $row) {
> // Assumes that $row will be an array.
> // Manipulate the data in $row if
On 19 April 2010 16:18, Gary . wrote:
> On Mon, Apr 19, 2010 at 2:37 PM, Peter Lind wrote:
>> On 19 April 2010 14:24, Gary wrote:
>>> On Mon, Apr 19, 2010 at 10:36 AM, Peter Lind wrote:
>
>>>> So no, you shouldn't be able to do that.
>>>
>>&
On 19 April 2010 12:54, Andre Polykanine wrote:
> Hello Peter,
>
> Regarding the URL switching suggested by you and Michiel, how do I do
> this if I have a rather complicated .htaccess file? For instance, a
> blog entry URL is formed as follows:
> http://oire.org/menelion/e
to have a look at http://pl2.php.net/_
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On 19 April 2010 14:24, Gary . wrote:
> On Mon, Apr 19, 2010 at 10:36 AM, Peter Lind wrote:
>> On 19 April 2010 10:30, Gary wrote:
>>> Should I be able to do this:
>>>
>>> class X
>>> {
>>> const FOO = 'foo';
>>> const FOO
On 19 April 2010 10:30, Gary . wrote:
> Should I be able to do this:
>
> class X
> {
> const FOO = 'foo';
> const FOOBAR = X::FOO . 'bar';
>
> ...
> }
>
> ?
>
> Because I can't. I get "syntax error, unexpected '.', expecting ',' or
> ';'". I assume this is because the constants are like statics
Most, if not all, mail servers keep log files. You should look for the
log files to see if the mail server has sent your mail properly or is
experiencing problems (those may not feed back into PHP).
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in
Consider checking out http://php.net/gettext - it's the set of
functions in PHP for i18n.
With regards to language switching, you should consider using a url
hierarchy for it, instead of just serving all pages with changing
content.
Regards
Peter
--
WWW: http://plphp.dk / http://pli
ould have the email reader
> interpret that code correctly
>
> Bastien
Another option would be to use mysql_real_escape_string and make sure
that your code and the database are using utf-8. Then when the email
is sent, make sure that uses utf-8 as well.
Regards
Peter
--
WWW: http://plphp.dk / http://plind.dk
LinkedIn: http://www.linkedin.com/in/plind
Flickr: http://www.flickr.com/photos/fake51
BeWelcome: Fake51
Couchsurfing: Fake51
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
There's a limit to how deep var_dump goes, at least if you're using
xdebug. Compare the output with that of print_r which is not limited
in the same way.
On 16 April 2010 16:15, Ashley Sheridan wrote:
> I'm seeing some strange behaviour with var_dump. Is there a limit to how
> many levels deep th
On 16 April 2010 13:54, Ashley Sheridan wrote:
> On Fri, 2010-04-16 at 12:50 +0100, Paulo-WORK wrote:
>
>> Hello and thanks for any replies that this message may get.
>> I have a issue to solve regarding PHP.
>> My website relies heavlly on jquery and does not dowgrade properly.
>> I use codeigni
Javascript is client-side - only way to detect it is to have a page
send back information (post/get). What might work easiest is to have
jquery look for a given cookie upon page render, and if it doesn't
find it, then do an ajax call to the server. On the server side,
initiate a session for the use
On 13 April 2010 17:27, Paul M Foster wrote:
> On Tue, Apr 13, 2010 at 03:20:23PM +0200, Merlin Morgenstern wrote:
>
>> Hello everybody,
>>
>> I have form where users enter data to be saved in a db.
>>
>> How can I make php save the form data into a session before the user
>> leaves the page witho
On 13 April 2010 15:20, Merlin Morgenstern wrote:
> Hello everybody,
>
> I have form where users enter data to be saved in a db.
>
> How can I make php save the form data into a session before the user leaves
> the page without pressing the submit button? Some members leave the page and
> return a
On 13 April 2010 00:04, Gary wrote:
> For those that were looking to see a solution, this is what I have come up
> with. It was pointed out on another board (MySQL) that inserting multiple
> in one script is probably prohibited because of security reasons.
>
> What I did was open the connection,
with sender authorization, bad ports, etc.
>
Along these lines: there's a chance that sending a mail from yourself,
to yourself, through PHP like this, will cause mail servers to think
it's spam. For testing email sending, normal scenarios are better
(i.e. send an email to another account)
On 9 April 2010 23:08, Merlin Morgenstern wrote:
>
> Am 09.04.2010 22:58, schrieb Peter Lind:
>>
>> On 9 April 2010 22:20, Merlin Morgenstern wrote:
>>
>>>
>>> This sounds like the best solution to me. The only problem is that my
>>>
On 9 April 2010 22:20, Merlin Morgenstern wrote:
> This sounds like the best solution to me. The only problem is that my regex
> knowledge is pretty limited. The command:
> RewriteRule ^(.+) /subapp_members/search_user.php
>
The above rule will try to redirect everything to
/subapp_members/search
On 9 April 2010 12:20, Rene Veerman wrote:
> lolz :)) u try to be nice, and this is what u get?!?! :-D
>
Rene, it's nice of you to post messages on the availability of some OS
tools. However, you should also be aware that it's a minority of
people on this list that use those tools - which in
On 8 April 2010 16:30, David Otton wrote:
> On 8 April 2010 15:21, Juan wrote:
>
>> The structure is pretty easy to understand, however I'm not able to
>> solve this. Could you tell me why I'm not able to run this code.
>
> Your else has a condition on it
>
> } else (empty($b) and empty($c)) {
>
201 - 300 of 1886 matches
Mail list logo