Hi all
I have start a shell script and I want to use ncurses.
It was a quite difficulty to get it working, but now I'm done to start
to develop.
I have already search on sf.net and phpclasses and found a couple, but
I'm looking more stable or with a better OO design.
Do you know any set of class
On 07/30/2009 10:15 AM, Ashley Sheridan wrote:
On Thu, 2009-07-30 at 07:12 -0700, Christoph Boget wrote:
>>
You could email it to me, which I presume is better if you replied
back just to me and not the list?
Just copying the list back on in this one now. I don't know of any
places that you c
\n";
}
wont this do ?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On 07/30/2009 06:29 PM, Skip Evans wrote:
Jim Lucas wrote:
Skip Evans wrote:
Hey all,
Am I brain fading or what? I'm so used to formatting text in tables for
HTML display I can't think of how to do it for a plain text file.
I just need to create a columned table of names and addresses type
st
Is there a more efficient way to write the following?
itemid='ABC1'",$db);
printf("List: %s\n", money_format('$%i',
mysql_result($result,0,"priceList"))); ?>
I have many products per page and this code pulls the list price and
formats it. It works fine, but I'd like to know if I c
> while (isset($FieldMap[$Field]) {
Oops, left out the final close-parenthesis. I always do that with isset() for
some reason.
Ben
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Wed, Jul 29, 2009 at 1:18 PM, Skip Evans wrote:
> Hey,
>
> I've been asked to write a simple couple of public pages that would let an
> Asterisk customer modify their account configuration, but the client has no
> idea how Asterisk stores its data, apparently not in MySQL.
>
> Anyone know of a
> I don't THINK I need to worry about circular mappings... but I'm not
> sure how to check for it if I did...
>
> Any suggestions? Thanks!
Would the following work? It avoids recursion entirely and also checks for
circular mappings. You can plug in your own code where the comments are to do
whate
Hi,
Well, you will have an infinite recursion there if the mapping has
cycles, something like A->B, B->C, C->A would generate an invite
recursion.
Checking if the mapping has cycles is pretty simple: you have to
create a directed graph and then go through the graph in DFS marking
each visited nod
I'm cleaning up some inherited code in our data import module. For a
variety of reasons we have to support old standards of the import
format. Since some of those old versions were created we have since
renamed some fields in our data structure. So right now I've a hard
map for some field names...
Skip Evans wrote:
Jim Lucas wrote:
Skip Evans wrote:
Hey all,
Am I brain fading or what? I'm so used to formatting text in tables for
HTML display I can't think of how to do it for a plain text file.
I just need to create a columned table of names and addresses type
stuff... sprintf?
or a li
Jim Lucas wrote:
Skip Evans wrote:
Hey all,
Am I brain fading or what? I'm so used to formatting text in tables for
HTML display I can't think of how to do it for a plain text file.
I just need to create a columned table of names and addresses type
stuff... sprintf?
or a little str_pad on ea
Skip Evans wrote:
> Hey all,
>
> Am I brain fading or what? I'm so used to formatting text in tables for
> HTML display I can't think of how to do it for a plain text file.
>
> I just need to create a columned table of names and addresses type
> stuff... sprintf?
or a little str_pad on each vari
Hey all,
Am I brain fading or what? I'm so used to formatting text in
tables for HTML display I can't think of how to do it for a
plain text file.
I just need to create a columned table of names and addresses
type stuff... sprintf?
--
Skip Evans
Big Sky
I'm looking at this page now that shows working with the
database through socket type stuff, but now the ball is in the
client's court what they want to do. Not sure, so I'm just
reading up.
http://www.voip-info.org/tiki-index.php?page=Web+based+Asterisk+Database+maintenance
But thanks all fo
Merlin Morgenstern wrote:
> Hi there,
>
> I am trying to filter out content that is not ascii. Can I do this with
> regex? For example:
>
> $regex = '[AZ][09]';
> if (preg_match($regex, $text)) {
> return TRUE;
> }
> else {
> return FALSE;
> }
>
> The reason I
Merlin Morgenstern wrote:
> Hi there,
>
> I am trying to filter out content that is not ascii. Can I do this with
> regex? For example:
>
> $regex = '[AZ][09]';
> if (preg_match($regex, $text)) {
> return TRUE;
> }
> else {
> return FALSE;
> }
>
> The reason I
Jim Lucas wrote:
> Miller, Terion wrote:
>> I Figured it out using this:
>>
>> if ($_SERVER['SCRIPT_FILENAME'] = "browse.php" ) {
>> $default = "A";
>> } else {
>> $default = "";
>> }
>>
>> $letter = isset($_GET['letter'])? $_GET['letter'] :"$default" ;
>
> unless you are doing more then w
Miller, Terion wrote:
> I Figured it out using this:
>
> if ($_SERVER['SCRIPT_FILENAME'] = "browse.php" ) {
> $default = "A";
> }
I Figured it out using this:
if ($_SERVER['SCRIPT_FILENAME'] = "browse.php" ) {
$default = "A";
}
Hi Merlin,
I think the pattern you're looking for is '/[a-zA-Z0-9]/' which will
match all alphanumeric characters.
Cheers
Stuart
On 30 Jul 2009, at 19:13, Merlin Morgenstern wrote:
Hi there,
I am trying to filter out content that is not ascii. Can I do this
with regex? For example:
http://72.47.28.125:8080/phpinfo.php not working
ERROR:
The website cannot display the page
HTTP 500
IIS 5.1, PHP 5.3 XP Prof SP3 + all updates
PHP 5.2.8 worked great and took a few minutes to install
phpinfo.php is in C:\inetpub\wwwroot
php.ini has:
doc_root = "C:\inetpub\wwwroot" // fo
Hi there,
I am trying to filter out content that is not ascii. Can I do this with
regex? For example:
$regex = '[AZ][09]';
if (preg_match($regex, $text)) {
return TRUE;
}
else {
return FALSE;
}
The reason I need to do thi
Ben Dunlap wrote:
> have -- "($x != false)" -- will be true whether $x is 0, NULL, an empty
> string,
[8<]
> But "$x !== false" will only be true in the last case.
Sorry, replace "be true" with "be false" above.
-Ben
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http
echo (preg_match($pattern, $test) != false)
>>
>> The " != false " here is redundant.
>
> Understood. But what you think is redundancy is, to me, clarity in
> programming. I happen to think that boolean tests shouldn't ride on
> whether or not an array returned from a function is empty or not
MEM wrote:
>> By the way, there are many reasons for creating objects inside of other
>> objects. This should not be considered an exception. I don't know where
>> this code belongs to, so I can't clear out if it is good or bad OOP
>> style.
>
> I do not intend to public judge the author, but the
>
> How would you go about ensuring the memory is not exhausted when running a
> script ?
>
> I have a script, which to make it basic ... reads values from files, I
> create an array of values per file then with a foreach insert values into a
> table, I have added a line to echo the memory use aft
Skip Evans wrote:
> Per Jessen wrote:
>> Depends on which data we're talking about. Asterisk is very
>> flexible.
>>
>
> For example, the first screen they want people to be able to
> change data on is:
>
> call waiting,do not disturb
> and then it looks like numbers (forwarding?)
> unconditio
On Thu, 2009-07-30 at 07:12 -0700, Christoph Boget wrote:
> Well, I didn't want to upload a file to the list. Putting it in a
> central location where those interested parties could access it would
> be a much better option.
>
>
> thnx,
> Chris
>
>
> ___
From: Christoph Boget
>> Have you tried using 'file -i' from the command line: after all you
are looking
>> for a MIME type with your fileinfo...
>> Having said that, with file -i on my system, Word documents are
>> 'application/msword' and Excel files are 'application/octet-stream'
>
> $ file -i
> The xls file I am using was generated with Excel (of Office 2007) for
> the Mac. So either you have a different magic file (assuming that's
> what the file command uses) than I do or different versions of excel
> contain different information.
I just tried using an excel spreadsheet saved using
On Thu, 2009-07-30 at 09:51 -0400, Christoph Boget wrote:
> >> Having said that, with file -i on my system, Word documents are
> >> 'application/msword' and Excel files are 'application/octet-stream'
> > Fedora11 (2.6.29.6-213.fc11.i586)
> > $ file excel.xls
> > excel.xls: CDF V2 Document, Little E
>> Having said that, with file -i on my system, Word documents are
>> 'application/msword' and Excel files are 'application/octet-stream'
> Fedora11 (2.6.29.6-213.fc11.i586)
> $ file excel.xls
> excel.xls: CDF V2 Document, Little Endian, Os: Windows, Version 5.1, Code
> page: 1252, Author:
> Have you tried using 'file -i' from the command line: after all you are
> looking
> for a MIME type with your fileinfo...
> Having said that, with file -i on my system, Word documents are
> 'application/msword' and Excel files are 'application/octet-stream'
$ file -i excel.xls
excel.xls: applic
On 07/30/2009 08:53 AM, Peter Ford wrote:
Have you tried using 'file -i' from the command line: after all you are looking
for a MIME type with your fileinfo...
Having said that, with file -i on my system, Word documents are
'application/msword' and Excel files are 'application/octet-stream'
Christoph Boget wrote:
>>> /usr/share/file/magic
>> /usr/share/file/magic has lots of rules to know its type and its just
>> matching it.
>
> I know it has a lot of rules. Grepping it for excel shows that there
> are rules in it for those types of files as well.
>
>> Maybe your file is quite str
How would you go about ensuring the memory is not exhausted when running a
script ?
I have a script, which to make it basic ... reads values from files, I
create an array of values per file then with a foreach insert values into a
table, I have added a line to echo the memory use after each array
> > /usr/share/file/magic
> /usr/share/file/magic has lots of rules to know its type and its just
> matching it.
I know it has a lot of rules. Grepping it for excel shows that there
are rules in it for those types of files as well.
> Maybe your file is quite strange . have you tried with other x
> By the way, there are many reasons for creating objects inside of other
> objects. This should not be considered an exception. I don't know where
> this code belongs to, so I can't clear out if it is good or bad OOP
> style.
I do not intend to public judge the author, but the original article is
Hi there,
I am currently struggling in forcing Word to show a UTF-8 encoded document. The
generated document is a normal web page with generated content from a mysql
database.
When I remove the header commands, the document with proper russian characters
is displayed fine in the browser, but wh
Hello Márcio,
stdClass is simply an empty class, without any properties or methods.
The object in the code sample is used to return multiple values at once. He
could also have used an associative array to achieve that, but by choosing an
object, he shows his affinity to the object oriented prog
Hello everybody,
In this class sketch:
total_pages = $total_pages;
$pagi_obj->offset = $offset;
$pagi_obj->limit = $limit;
$pagi_obj->page;
return $pagi_obj;
}
}
Why do the author used a stdClass ?
What are the advantages of using
On Wednesday 29 July 2009 10:18:08 pm Skip Evans wrote:
> Hey,
>
> I've been asked to write a simple couple of public pages that
> would let an Asterisk customer modify their account
> configuration, but the client has no idea how Asterisk stores
> its data, apparently not in MySQL.
>
> Anyone know
43 matches
Mail list logo