Hi all,
At the moment I'm doing this to escape all special regular expression
characters from my regex string:
$badwordtest = str_replace(/,,$badwordtest);
$badwordtest = str_replace(\\,,$badwordtest);
$badwordtest = str_replace(^,\^,$badwordtest);
$badwordtest =
Andrey Hristov [EMAIL PROTECTED] wrote in message
053801c1c9d0$5b4da400$0b01a8c0@ANDreY">news:053801c1c9d0$5b4da400$0b01a8c0@ANDreY...
In PHP 4.0.5 and later, every parameter to str_replace() can be an
array.If search and
Thank you for pointing that out :)
I've now changed my code from the
Hi all,
I have a global array $mtxt that is created in my script.
I have a function from which I want to access a value from that array:
$mtxt[1] = Test;
$text = $GLOBALS['mtxt[1]'];
Except that gives me the Warning Undefined index;
I can use $GLOBALS['mtxt'] to access a global variable
Mike Ford [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
$GLOBALS['mtxt'][1]
Fantastic :)
That's totally illogical but it works a treat.
PHP has some weird syntax rules sometimes!
Cheers,
Rich
--
Fatal Design
http://www.fatal-design.com
Atari / DarkBASIC /
Rasmus Lerdorf [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
I don't understand why you think it is illogical. How else would you
dereference a multi-dimensional array?
Because in my mind (which I know is totally wrong in this instance, I'm just
explaining
Hi all,
I've been having a wonderful night trying to solve this one, but I'm going
to throw in the towel and see if anyone else can shed some light on it. The
scenerio is quite simple, I'm parsing some form input from a user and
looking for the following:
[details]...[/details]
where the
John Holmes [EMAIL PROTECTED] wrote in message
000a01c21e45$92b64270$b402a8c0@mango">news:000a01c21e45$92b64270$b402a8c0@mango...
Wouldn't you want to use preg_match() before you replace it?
In this instance, no I don't think so. I've already performed the task I
needed with the tags in
Hi,
I am wondering if there is any tangible difference between the following two
commands:
$x = $foo[status];
$x = $foo['status'];
The part in question being the use of ' or around the status element of
the array $foo.
Both have the same end result in my case, I'm just purely wondering which
Austin Marshall [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
It all depends on what you use as a key... you just follow the normal
string standards. If you want a variable evaluated within the key, then
you must use s if you purely use text then you just
Hi Tedd,
Friday, May 25, 2007, 2:42:34 PM, you wrote:
At 3:28 PM +0100 5/23/07, Richard Davey wrote:
if ($_POST['status_code'] == 'C')
^^
Read-up on the if/else structure and comparison operators. You'd never
use a single equals sign in this example.
Rich:
Read
Hi Tijnema,
Friday, May 25, 2007, 5:58:46 PM, you wrote:
On 5/25/07, Robert Cummings [EMAIL PROTECTED] wrote:
Very. Each directory contains very specific types of code/content.
Tracking down where any given function, class, custom tag, behaviour,
etc is defined is extremely simple.
Cheers,
Hi Rafael,
Saturday, May 26, 2007, 12:38:15 AM, you wrote:
Hello does anyone know the correct way to install PHP and APACHE (last
versions both of them) on WinXP???, Im doing it with the installers and I
cannot even run phpinfo(); script, I see apache's error log and it says that
i cant find
Hi all,
Just a quick straw-poll really:
What is your take on using 'return' when you end a function, if you
don't actually need to return a value?
If you have to return say a true/false as the result of an operation,
then it's an obvious choice. But what if all the function does is
perform an
Hi Dave,
Wednesday, May 30, 2007, 12:20:48 PM, you wrote:
If there is no need to return a value then I don't do so. However, the
function is going to process something, and surely you should check that the
processing has succeeded or failed?
I have exception and error handling dealt with
Hi Chris,
Wednesday, May 30, 2007, 1:17:39 PM, you wrote:
If there is no need to return a value then I don't do
so. However, the function is going to process something,
and surely you should check that the processing has
succeeded or failed?
This is precisely the point I was going to
Hi Paul,
Wednesday, May 30, 2007, 4:07:00 PM, you wrote:
I demur at your final point: If we don't use exit() and the function
performs non-aborting error handling, it's going to return to the
calling function which in most cases will need to know whether its
child function succeeded or
Hi Jared,
Wednesday, May 30, 2007, 4:10:45 PM, you wrote:
[snip]
I think putting return; at the end of every function is probably a healthy
practice, but is it best practice? If it's poorly written and/or poorly
factored code, it doesn't make any difference if they have returns on
Hi Dave,
Monday, June 4, 2007, 3:25:25 PM, you wrote:
No, you should check the ini setting in your code and react accordingly.
Sorry, I don't quite follow you here. If I turn magic quotes off on both
my testing environment and my server, as is preferable according to
the manual, then my
Hi,
Wednesday, June 6, 2007, 11:41:19 AM, you wrote:
I want to force users to insert landscape rather portrait images. I don't
want to be too pedantic about it but they do need to have an approximate 4x3
aspect ratio.
You can't really be 'approximate' when coding. You need to set some
hard
Hi Burn,
Wednesday, June 6, 2007, 3:55:21 PM, you wrote:
Here's how I do it, for 1 single table though.. you'll have to write
yourself the mod to check on more tables. If you plan to have 10
millions records make sure the maxrand is higher.
When the do loop exits you have a unique id.
Hi Burn,
Wednesday, June 6, 2007, 4:39:05 PM, you wrote:
Worst thing that can happen is having mysql throw an error while trying
to insert an ID that's already present in the database. It gets more
complicated and unpredictable if the field isn't required to be unique
at database design
Hi Brad,
Wednesday, June 6, 2007, 5:04:41 PM, you wrote:
Yes, that's basically what my code already does.
The problem is that what if the url is http://yahoo.co.uk/; (note the lack
of a subdomain)
Your script thinks that the domain is co.uk. Just like my existing code
does.
So we can't
Hi Crayon,
Friday, June 8, 2007, 6:08:30 PM, you wrote:
On Friday 08 June 2007 22:17, tedd wrote:
Wednesday, June 6, 2007, 11:41:19 AM, you wrote:
I want to force users to insert landscape rather portrait images.
I don't want to be too pedantic about it but they do need to have
Hi Robert,
Friday, June 8, 2007, 7:21:39 PM, you wrote:
Precisely defined limits are not the same as precisely defined values. I
might precisely define the amount of entropy on a random value as being
some formula based on the current temperature of my CPU. The formula is
quite precise, but
Hi Robert,
Friday, June 8, 2007, 7:47:17 PM, you wrote:
On Fri, 2007-06-08 at 19:35 +0100, Richard Davey wrote:
Hi Robert,
Friday, June 8, 2007, 7:21:39 PM, you wrote:
Precisely defined limits are not the same as precisely defined values. I
might precisely define the amount of entropy
Hi Nathan,
Friday, June 8, 2007, 9:47:22 PM, you wrote:
I have a php script that gets a url from a GET query parameter. I have
been running this script on PHP 5.2.2 on Ubuntu Linux, and everything
works as expected. I have just installed PHP 5.2.3 on OS X via
MacPorts, and the same query
Hi all,
Can anyone think of a more elegant way of achieving the following?
?php
$flags = array();
if ($allow_fraction)
{
$flags[] = FILTER_FLAG_ALLOW_FRACTION;
}
if ($allow_thousand)
{
$flags[] = FILTER_FLAG_ALLOW_THOUSAND;
}
if ($allow_scientific)
{
$flags[] =
Hi Zoltán,
Wednesday, June 13, 2007, 2:21:18 PM, you wrote:
2007. 06. 13, szerda keltezéssel 14.13-kor Richard Davey ezt írta:
Hi all,
Can anyone think of a more elegant way of achieving the following?
?php
$flags = array();
if ($allow_fraction)
{
$flags
Hi Tijnema,
Wednesday, June 13, 2007, 2:42:28 PM, you wrote:
Nice one, but you could also do it like this:
?php
$filter['flags'] = FALSE;
if ($allow_fraction)
{
$filter['flags'] = $filter['flags'] | FILTER_FLAG_ALLOW_FRACTION;
}
if ($allow_thousand)
{
$filter['flags'] =
Hi Zoltán,
Wednesday, June 13, 2007, 3:09:16 PM, you wrote:
2007. 06. 13, szerda keltezéssel 15.42-kor Tijnema ezt írta:
On 6/13/07, Richard Davey [EMAIL PROTECTED] wrote:
Hi Zoltán,
Wednesday, June 13, 2007, 2:21:18 PM, you wrote:
2007. 06. 13, szerda keltezéssel 14.13-kor Richard
Hi Robert,
Wednesday, June 13, 2007, 3:15:39 PM, you wrote:
It's terribly verbose and inefficient...
?php
$filter['flags'] = 0;
if( $allow_fraction )
{
$filter['flags'] |= FILTER_FLAG_ALLOW_FRACTION;
}
if( $allow_thousand )
{
$filter['flags'] |= FILTER_FLAG_ALLOW_THOUSAND;
Hi Robert,
Wednesday, June 13, 2007, 3:37:38 PM, you wrote:
Personally I hate constants (can't use non-scalar values so why get used
ot them... also they're just another point for name collision) so if it
were my own code I'd do something more like the following:
Sure, but the filter
Hi Richard,
Wednesday, June 13, 2007, 6:44:55 PM, you wrote:
if ($allow_fraction)
//Should we warn you that $allow_fraction is not actually defined?...
Should I warn you that to save everyone's sanity I only posted what was
needed from the code? ;) $allow_fraction came from a function
Hi Javier,
Thursday, June 14, 2007, 9:23:25 AM, you wrote:
I've received a job offer from a London zone 1 based
company as Senior PHP developer.
I'm really interested but I live in Spain an have no
idea about UK salaries so I wonder if somebody could
give me a clue.
How much money is a
Hi Daniel,
Thursday, June 14, 2007, 7:40:52 PM, you wrote:
I gross ~$2,400 per month.
[snip]
So, with bills alone, it costs me a minimum of $2,700. That
leaves me with about $900 extra which then goes to repaying loans
I'm curious.. how does $2,400 - $2,700 = $900 left over
Hi Daevid,
Thursday, June 14, 2007, 9:26:44 PM, you wrote:
We had an employee (a friend of mine) start a UK office, and due to
corporate legal reasons, and taxes, etc, he got paid in US DOLLARS.
Aside from even more legal/tax issues he personally had to face, his
salary was almost halved, as
Hi Tijnema,
Friday, June 15, 2007, 12:10:56 AM, you wrote:
It's actually 1 USD = 0.50 GBP.
Ohh nice :)
Yeah, it makes buying software from the US a dream at the moment. Same
goes for domain names, server hosting, etc. Of course it means SELLING
software into the US is a complete bitch, but
Hi Crayon,
Friday, June 15, 2007, 2:06:47 AM, you wrote:
On Friday 15 June 2007 07:39, Richard Davey wrote:
Yeah, it makes buying software from the US a dream at the moment.
Huh? When software comes across the pond they usually markup at 1USD=1GBP
Sure, bastards like Adobe rip us off
Hi,
Friday, June 15, 2007, 9:53:24 PM, you wrote:
I know very little about PHP ... however, I am hoping that there is some
kind of preset open source php code that I might be able to use.
There is the Pear pagination package which can do this, although not
quite in the way you want it done
Hi Ross,
Friday, June 15, 2007, 10:00:53 PM, you wrote:
I have this
$img_url=http://www.xxx.co.uk/images/ENbb24469/room1.JPG;;
echo img src=\common/display_image.php?img_url='$img_url'\ width=\200\
height=\100\ /;
and on the display image page I have:
$img_url= $_GET['img_url'];
Hi Ross,
Friday, June 15, 2007, 10:40:37 PM, you wrote:
Any ideas how to save the imagecopyresampled() to the folder?
Call imagepng (or imagejpeg or whatever) and pass it a filename to
save the image instead of output it. Check the help files for examples.
Cheers,
Rich
--
Zend Certified
Hi tedd,
Saturday, June 16, 2007, 1:18:58 PM, you wrote:
How about?
switch (1)
{
case $allow_fraction:
$filter['flags'] = FILTER_FLAG_ALLOW_FRACTION;
break;
case $allow_thousand:
$filter['flags'] = FILTER_FLAG_ALLOW_THOUSAND;
Hi all,
Ok it's 2am, my brain has gone to mush and I am having trouble
figuring out an easy way to do this, can anyone shed some light?
Take a peek at the following code:
// START
pre
?php
print_r($_POST);
$userparam = test['sam'][];
// How to check if $userparam exists in
Hi Larry,
Tuesday, June 19, 2007, 2:55:07 AM, you wrote:
Perhaps you're looking for in_array()?
If only it was that simple! But pray tell how an in_array search is
going to find:
$userparam = test['bob'][];
within:
Array
(
[test] = Array
(
['bob'] = Array
Hi Stut,
Tuesday, June 19, 2007, 10:16:02 AM, you wrote:
If you can't control $userparam and it has to look like you have it then
you're parsing of it is a little more involved, but still fairly simple.
What are you actually trying to do? Where will $userparam actually come
from? There is
Hi Stut,
Tuesday, June 19, 2007, 12:09:12 PM, you wrote:
If you have no control over what the fields in the form will be, what
are you doing with the data? Surely if you're writing logic that
requires you to know what the fields are called, you need to have
control over it.
Here, this
Hi Stut,
Tuesday, June 19, 2007, 1:16:54 PM, you wrote:
The problem is finding a way to expand the input name (which is a
string) into a format that $_POST can be searched for. Or do the
reverse, iterate through $_POST to find a match for the input name and
get that value.
Try this overly
Hi Al,
Tuesday, June 19, 2007, 1:46:47 PM, you wrote:
preg_grep() or
foreach($_POST as $value){
if(empty($value)) continue;
$good_stuff[] = $value;
}
A classic case of not reading the post fully methinks.
Cheers,
Rich
--
Zend Certified Engineer
http://www.corephp.co.uk
Hi Stut,
Tuesday, June 19, 2007, 1:49:53 PM, you wrote:
Very nice, thank you. I was hoping there would be a way to do it
without resorting to eval(), but if even you can't figure out how, I'm
not going to waste any more time trying to either :)
You probably could by breaking it into each
Hi Jim,
Tuesday, June 19, 2007, 5:06:47 PM, you wrote:
DON'T USE SINGLE QUOTES IN YOUR NAME= ATTRIBUTE
Hate to piss on your bonfire but a single quote is a perfectly valid
(if somewhat stupid choice of) character for inclusion in an array key.
Cheers,
Rich
--
Zend Certified Engineer
Hi Jim,
Tuesday, June 19, 2007, 5:29:55 PM, you wrote:
Richard Davey wrote:
Hi Jim,
Tuesday, June 19, 2007, 5:06:47 PM, you wrote:
DON'T USE SINGLE QUOTES IN YOUR NAME= ATTRIBUTE
Hate to piss on your bonfire but a single quote is a perfectly valid
(if somewhat stupid choice
Hi Jim,
Tuesday, June 19, 2007, 5:47:29 PM, you wrote:
Jim Lucas wrote:
$userparam = test['sam'][];
then what you are saying it that this HAS to be your search string?
Heck no, it doesn't *have* to be. Feel free to remove the quotes from
it and then attempt my original question
Hi,
Tuesday, June 19, 2007, 5:17:29 PM, you wrote:
I have a integer that is submitted by the user and i need it to always
contain 5 digits.
If the user submitted 45, i need it to be 00045.
If the user submitted 4595, i need it to be 04595.
How can i do this?
Given PHPs type switching
Hi Jim,
Tuesday, June 19, 2007, 6:21:25 PM, you wrote:
let me try this again.
in the submitted $_POST array, you are looking for a key (test) that contains
a given $username
that may or may not have any values set?
Correct?
Sorry not even close.
Here, let me try again...
$param =
Hi Robin,
Tuesday, June 19, 2007, 8:28:50 PM, you wrote:
On 19/06/07, Richard Davey [EMAIL PROTECTED] wrote:
$userparam = test['sam'][];
// How to check if $userparam exists in the $_POST array
// and get all the values from it?
full_key_exists(test['sam'][], $_POST
Hi,
I've written a short regexp which will *count* how many capital letters
are in a given string (the woefully simple: '/[A-Z]/')
Although it's an English language web site, I'm curious how you'd
count capital letters that span beyond just the standard A-Z.
For example characters such as the
Hi all,
Just wanting to pick your collective brains on this one:
How do you go about implementing a swear / bad-word filter in PHP?
Reasons for needing one aside, I'm just wondering if you favour a
regexp, a substr_count, or what? Do you like to *** out the bad words,
or just error back to the
Hi Andrew,
Wednesday, July 4, 2007, 4:23:38 PM, you wrote:
Avoid the O'Reilly one as it is flawed.
In what way?
Its written by Chris Shiflett, isn't that enough reason?
No, not really. The errata are clearly published online, and while you
could argue that some of them shouldn't have
Hi Andrew,
Wednesday, July 4, 2007, 8:29:51 PM, you wrote:
I have no doubt he is a great bloke and a great public speaker / PR
for PHP application level security, I apologise if it sounded like
FUDing (why does that sound dirty?). I just don't like / agree with
his book or some of the
Hi Bruce,
Thursday, July 5, 2007, 1:26:01 AM, you wrote:
Thanks. Sorry, I should have mentioned I'm using MS Sql Server and
I don't see a mssql equivalent to that function.
MSSQL treats '' as an escaped ', not \' like MySQL does.
So you can't addslashes it. Perform your own ' to ''
Thanks. Sorry, I should have mentioned I'm using MS Sql Server and
I don't see a mssql equivalent to that function.
MSSQL treats '' as an escaped ', not \' like MySQL does.
So you can't addslashes it. Perform your own ' to '' conversion.
And to reply to my own reply :) ...
If you can, use
Hi k,
Tuesday, July 10, 2007, 11:59:42 PM, you wrote:
I'm trying to make a button execute some php code when the button is
clicked. I'm not sure if it is the button i'm coding wrong or the php code.
Here is the code I am using.
?php
echo button action='?php
Hi Grant,
Saturday, July 14, 2007, 8:07:43 PM, you wrote:
Previously I had PHP on my older computer using IIS 5.1 it worked fine. But
I'm on my new computer using IIS 7 and features like include or completely
normal scripts that use to work no longer work. I have try to see if it's
the web
Hi Crayon,
Monday, July 16, 2007, 4:22:14 PM, you wrote:
I think no matter which way you dice it, sending 1 email is a lot more
energy efficient than printing 1 book. Just because the tree itself is
renewable, the *energy* used in cutting it down, turning it into paper,
turning the paper
Hi Jochem,
Monday, July 16, 2007, 6:11:12 PM, you wrote:
no personal attack is intended here ... I hope you don't mind if I
rebutt/discuss, I find it a rather interesting topic :-)
Not at all, my original post wasn't meant personally towards you
specifically, just in general.
did you look
Hi John,
Tuesday, July 17, 2007, 1:02:15 PM, you wrote:
Really? Did you cite and pay every source you used in your book? And
what about those of us who downloaded books that we've bought?
Neither of these things apply to my rant, don't quote me out of
context.
Seriously, I think you need
Hi John,
Tuesday, July 17, 2007, 2:01:42 PM, you wrote:
So it isn't as black and white as you say. There apparently is a
place where you can not only copy, but redistribute, and as long as
you gave proper credit, you don't have to pay.
Citing a reference in a book to another is not the same
Hi John,
Tuesday, July 17, 2007, 3:27:16 PM, you wrote:
Citing a reference in a book to another is not the same as
reproducing that ENTIRE book wholesale, page for page, illustration
for illustration.
All right, supposing I do a cut copy paste on a section of a book,
not the whole thing,
Hi Crayon,
Monday, July 23, 2007, 4:09:57 PM, you wrote:
On Monday 23 July 2007 22:26, Larry Garfield wrote:
So when does Rasmus Lerdorf and the Deathly Hallows open in theaters?
They've got to make Rasmus Lerdorf and the Order of the PHP first.
Or even Rasmus Lerdorf and the Order of
Hi php-general collective,
I'm building up some image data in my PHP script (ready for output to
the browser). Having to do some complex per pixel manipulation, which
is fine - but I'm just wondering is there a quicker / more efficient
way of storing the pixel data than in an array?
At the
Hi Robert,
Monday, July 23, 2007, 6:00:50 PM, you wrote:
What kind of data? Can't you just store it in the image? Or a working
copy of the image?
Afraid not, I'm performing deformation on the data that requires a
temporary location before rendering to the final image. If this was a
straight
Hi Daniel,
Tuesday, July 24, 2007, 2:34:06 PM, you wrote:
In order to enable cURL on a Windows box, you have to copy
libeay32.dll and ssleay32.dll from the DLL folder of the PHP/ binary
package to the SYSTEM folder. (to be safe, you may want to do both
C:\WINDOWS\SYSTEM\ and
Hi Daniel,
Tuesday, July 24, 2007, 3:57:11 PM, you wrote:
On 7/24/07, Richard Davey [EMAIL PROTECTED] wrote:
*Never* put PHP DLLs into the Windows System folder.
It's neither required, nor sensible.
Keep them where they belong - in your PHP folder.
Heh which is why I prefer
Hi Dave,
Tuesday, July 24, 2007, 4:45:13 PM, you wrote:
No I don't have a local certificate created.
I'm only need to do a post using xml-rpc and I have SSLVerifyPeer turned
off. This turns off client certificate authentication
$xmlrpc_client-setSSLVerifyPeer(0);
What does your PHP error
Hi Richard,
Wednesday, July 25, 2007, 5:20:32 AM, you wrote:
It's possible, maybe, that using imagecolorat and imagesetcolor (or
whatever it is) would be faster than array access...
In the end I implemented RLE on the image data, and depending on the
image in question it is saving sometimes
Hi Erfan,
Wednesday, July 25, 2007, 9:39:35 AM, you wrote:
The site I'm working on has a lot of notice warnings, thousands. And
they are all about: (Notice: Undefined variable..)
I was wondering if I set the php.ini file to not log these in file or
display them, does all of these notice
Hi Patrik,
Wednesday, July 25, 2007, 11:30:56 PM, you wrote:
Dear my friends...
I create a very simple script in html and php as a first step. I use suse,
apache2, mysql and php.
I wonder why this script does not work:
!DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
html
Hi Joey,
Thursday, July 26, 2007, 1:36:37 PM, you wrote:
Hi everyone,
I'mt trying to do the below query which itself works correctly, but when I
add a order by statement just bombs.
$query = select * from articles where ( {$now} BETWEEN startdate
AND enddate) and categoryid = 1
Hi,
I'm calling a MySQL Stored Procedure via PDO (PHP 5.2.3)
$stmt = $dbh-prepare('CALL forum_post(?, ?, ?, ?, ?, @status, @thread_id,
@message_id)');
At the moment in order to get the values of status, thread_id and
message_id I need to issue a second query:
$sql = SELECT @status AS status,
Hi M.,
Thursday, July 26, 2007, 2:09:47 PM, you wrote:
Richard Davey wrote:
Hi,
I'm calling a MySQL Stored Procedure via PDO (PHP 5.2.3)
$stmt = $dbh-prepare('CALL forum_post(?, ?, ?, ?, ?, @status, @thread_id,
@message_id)');
At the moment in order to get the values of status
Hi Chris,
Wednesday, July 25, 2007, 5:36:29 PM, you wrote:
I'm running PHP 5.2.0 on windows XP SP2 lately when it starts I
have been getting the an error when it tries to load the mysqli dll.
It loads the standard mysql dll fine and all the dlls are in the
same place the path and php
Hi Davis,
Saturday, July 28, 2007, 1:54:22 AM, you wrote:
Hi! I am trying to use the imagestring() function to put a string of
Chinese characters from a $_GET variable onto an image. However, the
characters do not display right (English is fine). Is there a way I can
fix this or it is the
Hi,
Monday, July 30, 2007, 7:40:52 PM, you wrote:
I'm not sure that there's actually anything you'd need to access in
the server registry (and certainly no registry in Linux if you're
also transitioning from Windows to Linux). And depending on what the
ActiveX control your ASP pages accessed
Hi Carlton,
Tuesday, July 31, 2007, 2:27:46 PM, you wrote:
I have an array like this:
$chance = array(lowercase = 27, uppercase = 62, integer = 46);
The values for each of the keys are randomly generated. I want to
find the key name of the one which has the highest value. Currently, I'm
Hi Greg,
Tuesday, August 7, 2007, 9:52:28 PM, you wrote:
PHP is the absolute worst language to do any sort of OO programming
in.
Ignoring the digg user mentality of that statement, try ASP if you
want to see OO suck *royally*
Cheers,
Rich
--
Zend Certified Engineer
http://www.corephp.co.uk
Hi Faither,
Friday, August 10, 2007, 5:16:09 PM, you wrote:
I'm kind of lost with how str_replace , preg_replace, ereg_replace or
even explode are handling a \n-ewline.
I have a text string from a form and am trying to replace the \n or
chr(10) or however you might call the newline with a
Hi Tony,
Friday, August 10, 2007, 5:23:28 PM, you wrote:
I have to write some PHP backend code for a threaded message board.
The db has a message table, and each message has a parent id.
Does anyone have any advice for someone whos never done this in PHP?
I'm currently thinking that I
Hi Stut,
Friday, August 10, 2007, 4:44:14 PM, you wrote:
On my production servers error_reporting is set to E_ALL,
display_errors is off and log_errors is on. I get an email from each
server containing the contents of the error log from the previous
day and my first task each day is to go
Hi Robert,
Friday, August 10, 2007, 4:13:02 PM, you wrote:
On Fri, 2007-08-10 at 11:00 -0400, Daniel Brown wrote:
Remember to clean that input before you sit down at the table, there,
boy!
It's safe to ignore the `Undefined index` notices. That will just
appear if a variable is
Hi Kevin,
Friday, August 10, 2007, 7:26:30 PM, you wrote:
I doubt this, but is there any way to determine via PHP if a browser
was refreshed automatically via a META tag vs the person clicking the
refresh button?
You could dynamically generate the meta tag, so it refreshes to your
page
Hi Richard,
Friday, August 10, 2007, 11:10:21 AM, you wrote:
This is off topic so feel free to reply off list.
My question is how much is it reasonable to charge for the following:
1. Building a very small website (you can see it here:
http://www.cleardebtadvice.co.uk)
2. Hosting it
Hi Dan,
Wednesday, September 5, 2007, 3:24:43 PM, you wrote:
Opening this file is proving to be a pain. I have a folder that contains a
PHP page and a text file. I am trying to open the contents of the txt file
using file() but it keeps erroring out. Below is the code I'm using to try
and
Hi Brian,
Thursday, October 4, 2007, 4:50:09 PM, you wrote:
I'm running the following code:
$query3 = DELETE FROM table1 WHERE referer=$referer ORDER BY
creation LIMIT $numtodelete;
$result3 = mysql_query($query3);
$string = $total found, $n kept, $numtodelete extras removed
Hi Brian,
Friday, October 5, 2007, 1:28:35 PM, you wrote:
This is indeed the complete code, I did not cut anything out for
brevity, which is why this appears to be so impossible.
eAccelerator is activated, could something be corrupt? Could a
corrupt index cause this?
In table1,
Hi Brian,
Friday, October 5, 2007, 2:10:32 PM, you wrote:
I definitely misunderstood what you guys are saying about the length.
That's clearly a problem for a lot of my values.
I can switch them both to bigint. One table has 34,000,000 records
and it's OK if this is hung up for a few
,
Richard Davey
--
http://www.launchcode.co.uk - PHP Development Services
I do not fear computers. I fear the lack of them. - Isaac Asimov
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
with a file once it hits the server, if you want to check files
client side before they're uploaded, you need a client side language.
Best regards,
Richard Davey
--
http://www.launchcode.co.uk - PHP Development Services
I do not fear computers. I fear the lack of them. - Isaac Asimov
--
PHP General
,
Richard Davey
--
http://www.launchcode.co.uk - PHP Development Services
I do not fear computers. I fear the lack of them. - Isaac Asimov
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
of
circumstances, this isn't really one of them and doesn't solve the
original posters problem.
Best regards,
Richard Davey
--
http://www.launchcode.co.uk - PHP Development Services
I do not fear computers. I fear the lack of them. - Isaac Asimov
--
PHP General Mailing List (http://www.php.net
dumping out the whole of $_GET to see if you are receiving
anything at all:
?php
print_r($_GET);
?
Best regards,
Richard Davey
--
http://www.launchcode.co.uk - PHP Development Services
I do not fear computers. I fear the lack of them. - Isaac Asimov
--
PHP General Mailing List (http
1 - 100 of 1004 matches
Mail list logo