php-general Digest 22 Jun 2010 14:22:54 - Issue 6810
Topics (messages 306302 through 306303):
Re: Website content question
306302 by: Ernie Kemp
Warning messages on web page.
306303 by: Mike Davies
Administrivia:
To subscribe to the digest, e-mail:
php-general Digest 23 Jun 2010 03:59:06 - Issue 6811
Topics (messages 306304 through 306325):
Re: Warning messages on web page.
306304 by: Jim Lucas
306305 by: Shreyas Agasthya
306306 by: Daniel P. Brown
306307 by: Paul M Foster
Stripping Characters
Hello,
This is my first post to this list and I am a novice at php coding. I
can generally follow the code but not good at writing from scratch.
I have recently been trying to add to a website which was originally
developed by someone else and is written in php and mysql. I am trying
to add a
Mike Davies wrote:
Hello,
This is my first post to this list and I am a novice at php coding. I
can generally follow the code but not good at writing from scratch.
I have recently been trying to add to a website which was originally
developed by someone else and is written in php and
Mike,
A couple of things that I could understand reading carefully at the error.
1. reset takes an array as the input and perhaps your $thumbsarray is *not *an
array? Reset will set the internal pointer to the start of the array.
2. Warning # 2 is very closely related to #1 since you can
On Tue, Jun 22, 2010 at 10:17, Mike Davies m...@integrawebdesign.co.uk wrote:
[snip!]
Warning: reset() [function.reset]: Passed variable is not an array or
object in /home/b23aadf/public_html/news/details.php on line 72
[snip!]
Is anyone able to help resolve this? If you let me know what
On Tue, Jun 22, 2010 at 03:17:53PM +0100, Mike Davies wrote:
Hello,
This is my first post to this list and I am a novice at php coding. I
can generally follow the code but not good at writing from scratch.
I have recently been trying to add to a website which was originally
developed
Hello List.
I need to remove characters from a string and replace them with and
underscore.
So instead of having something like:
$moditem = str_replace(--,_,$mystring);
$moditem = str_replace(?,_,$mystring);
$moditem = str_replace(!,_,$mystring);
etc.
For every possible character I can
Hello,
can this resolve your problem?
$trans = array(
from = to,
another = to);
$moditem = StrTr($moditem, $trans);
-- http://cz.php.net/manual/en/function.strtr.php
David
-Original Message-
From: Rick Dwyer [mailto:rpdw...@earthlink.net]
Sent: Tuesday, June 22, 2010 5:41 PM
To:
On Tue, 2010-06-22 at 11:40 -0400, Rick Dwyer wrote:
Hello List.
I need to remove characters from a string and replace them with and
underscore.
So instead of having something like:
$moditem = str_replace(--,_,$mystring);
$moditem = str_replace(?,_,$mystring);
$moditem =
Perhaps, ereg_replace(your regex, replacement_string, String
$variable).
Regards,
Shreyas
On Tue, Jun 22, 2010 at 9:10 PM, Rick Dwyer rpdw...@earthlink.net wrote:
Hello List.
I need to remove characters from a string and replace them with and
underscore.
So instead of having something
On 22 June 2010 16:44, Ashley Sheridan a...@ashleysheridan.co.uk wrote:
On Tue, 2010-06-22 at 11:40 -0400, Rick Dwyer wrote:
Hello List.
I need to remove characters from a string and replace them with and
underscore.
So instead of having something like:
$moditem =
On Tue, Jun 22, 2010 at 9:40 AM, Rick Dwyer rpdw...@earthlink.net wrote:
Hello List.
I need to remove characters from a string and replace them with and
underscore.
So instead of having something like:
$moditem = str_replace(--,_,$mystring);
$moditem = str_replace(?,_,$mystring);
Then, when does one use ereg_replace as against preg_replace? I read from
one the forums that preg_* is faster and ereg_* is if not faster but
simpler.
Is that it?
Regards,
Shreyas
On Tue, Jun 22, 2010 at 9:58 PM, Richard Quadling rquadl...@gmail.comwrote:
A word character is any letter or
Thanks to everyone who responded.
Regarding the myriad of choices, isn't Ashley's, listed below, the one
most like to guarantee the cleanest output of just letters and numbers?
--Rick
On Jun 22, 2010, at 11:44 AM, Ashley Sheridan wrote:
On Tue, 2010-06-22 at 11:40 -0400, Rick Dwyer
On Tue, 2010-06-22 at 13:35 -0400, Rick Dwyer wrote:
Thanks to everyone who responded.
Regarding the myriad of choices, isn't Ashley's, listed below, the one
most like to guarantee the cleanest output of just letters and numbers?
--Rick
On Jun 22, 2010, at 11:44 AM, Ashley
Shreyas Agasthya wrote:
Then, when does one use ereg_replace as against preg_replace? I read from
one the forums that preg_* is faster and ereg_* is if not faster but
simpler.
BUT, all the ereg_* has been depricated. DO NOT USE THEM if you want your code
to work in the future. :)
Is that
Hey everyone,
I have a question about logins. Let's say that I want to allow each
user account to login only once at a time. I would then need some kind
of locking mechanism to make sure that the same user can't login again
somewhere else until first logging off. What's a good way to achieve
-Original Message-
From: James Colannino [mailto:ja...@colannino.org]
Sent: Tuesday, June 22, 2010 2:29 PM
To: php-general@lists.php.net
Subject: [PHP] Question about logins and locking
Hey everyone,
I have a question about logins. Let's say that I want to allow each user
Hello again list.
My code for stripping characters is below. I'm hoping to get feedback
as to how rock solid it will provide the desired output under any
circumstance:
My output must look like this (no quotes):
This-is-my-string-with-lots-of-junk-characters-in-it
The code with string
On Tue, 2010-06-22 at 20:03 -0400, Rick Dwyer wrote:
Hello again list.
My code for stripping characters is below. I'm hoping to get feedback
as to how rock solid it will provide the desired output under any
circumstance:
My output must look like this (no quotes):
Very good.
Thank you.
--Rick
On Jun 22, 2010, at 8:14 PM, Ashley Sheridan wrote:
On Tue, 2010-06-22 at 20:03 -0400, Rick Dwyer wrote:
Hello again list.
My code for stripping characters is below. I'm hoping to get
feedback
as to how rock solid it will provide the desired output under
Hello everybody :)
I'm really intrigued on something... In what real-world applications could
an extension of a class be really useful?
Let's say I have this code:
class foo {
function hello_world($a) {
echo 'foo hello world';
}
function bye_world() {
echo 'foo bye world';
}
}
Tommy Pham wrote:
1) Set an encrypted (to prevent hijacking and eavesdropping) cookie to
expire when browser closes
2) Have a table in the DB backend to keep track if the user is logged in or
not and when was the last time the validated user access your site (this
gets updated when the user
24 matches
Mail list logo