Re: [PHP] clean url problem .htaccess

2009-07-31 Thread Andrew Ballard
On Sat, Aug 1, 2009 at 2:11 AM, A.a.k wrote: > Hi > I'm trying to use clean urls in my application: > lets say convert http://mysite/article.php?id=3   to > http://mysite/article/3/ > my problem is to use /article act as it was /article.php > here is mt .htacess : > > ForceType application/x-httpd

Re: [PHP] Can a range be passed to a query?

2009-07-31 Thread Andrew Ballard
On Fri, Jul 31, 2009 at 5:55 PM, Phpster wrote: > What about > > $sql = "SELECT DISTINCT ID, name, address FROM restaurants WHERE > left(name, 1) between 0 and 9"; > > > > > Bastien > > Sent from my iPod You need to wrap the 0 and the 9 in single quotes, or else it returns everything. $sql = "SEL

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Andrew Ballard
On Fri, Jul 31, 2009 at 4:51 PM, Miller, Terion wrote: > //Show all restaurants that start with $letter not > between "A" and "Z" > > $other = ctype_digit($letter); > > foreach(range('0','9') as $other) { > > $sql = "SELECT DISTINCT ID, name, address > FROMrestaurants >

[PHP] clean url problem .htaccess

2009-07-31 Thread A.a.k
Hi I'm trying to use clean urls in my application: lets say convert http://mysite/article.php?id=3 to http://mysite/article/3/ my problem is to use /article act as it was /article.php here is mt .htacess : ForceType application/x-httpd-php on php code parsing string from $_SERVER['PHP_SELF']

[PHP] Problem: Writing into Files?

2009-07-31 Thread Parham Doustdar
Hi there, I've written a counter for my blog, which keeps the count of visitors in a file. However, when the visitors get too many, it resets to zero. Why? Here's the piece of code: [code] $f = $dir . '/view_counter' .EXT; $fp = fopen($f, "r"); $count =fgets($fp, 1024); fclose($fp); $fw = fopen(

Re: [PHP] Script to Compare Database Structures

2009-07-31 Thread Paul M Foster
On Fri, Jul 31, 2009 at 05:38:44PM -0400, Matt Neimeyer wrote: > I know I CAN hack something together but I hate to reinvent the wheel. > > I want to be able to compare the structure of two different clients > databases that might be on different servers that are firewalled away > from each other

Re: [PHP] Can a range be passed to a query?

2009-07-31 Thread Paul M Foster
(Sorry, forgot to send this to the whole list.) On Fri, Jul 31, 2009 at 05:24:45PM -0400, Miller, Terion wrote: > I'm still struggling with using ranges... Can they be passed to a query > somehow... > > I have this so far but it pulls nothing: > > //Show all with $letter not between "A"

Re: [PHP] Script to Compare Database Structures

2009-07-31 Thread German Geek
have you tried mysqldiff? ++Tim Hinnerk Heuer++ http://www.ihostnz.com (should be .org) Sponsors welcome to put ads under a linked to page. This is not automated just yet. Only image, swf or preferably text or short html ads, no animations please. Price negotiable. 2009/8/1 Matt Neimeyer > I

Re: [PHP] Re: Clean break.

2009-07-31 Thread Paul Halliday
I was trying to stay away from regex as much as possible due to the overhead? I might be wrong here. This script will be parsing a lot of requests/sec. Thousands, maybe more, which it also needs to toss into a DB. I want to try and keep it as fast as possible. This is tricky when you don't know wh

[PHP] Re: Clean break.

2009-07-31 Thread Ollisso
On Sat, 01 Aug 2009 00:22:21 +0300, Paul Halliday wrote: Whats the cleanest (I have a really ugly) way to break this: [21/Jul/2009:00:00:47 -0300] into: date=21/jul/2009 time=00:00:47 ... Why not just use regexp ? For example: $string = "long text.. multiply lines... [21/Jul/20

Re: [PHP] Can a range be passed to a query?

2009-07-31 Thread Phpster
On Jul 31, 2009, at 5:24 PM, "Miller, Terion" > wrote: I'm still struggling with using ranges... Can they be passed to a query somehow... I have this so far but it pulls nothing: //Show all with $letter not between "A" and "Z" if ($ $result = mysql_query($sql) or die(mysql_error

[PHP] Script to Compare Database Structures

2009-07-31 Thread Matt Neimeyer
I know I CAN hack something together but I hate to reinvent the wheel. I want to be able to compare the structure of two different clients databases that might be on different servers that are firewalled away from each other. Given the two structures it will list all the SQL commands needed to mak

Re: [PHP] Clean break.

2009-07-31 Thread Phpster
On Jul 31, 2009, at 5:22 PM, Paul Halliday wrote: Whats the cleanest (I have a really ugly) way to break this: [21/Jul/2009:00:00:47 -0300] into: date=21/jul/2009 time=00:00:47 Caveats: 1) if the day is < 10 the beginning of the string will look like "[1/... 2) the "-0300" will d

[PHP] Can a range be passed to a query?

2009-07-31 Thread Miller, Terion
I'm still struggling with using ranges... Can they be passed to a query somehow... I have this so far but it pulls nothing: //Show all with $letter not between "A" and "Z" if ($selectedLetter = "#") { $other = range('0','9'); $sql = "SELECT DISTINCT ID, na

[PHP] Clean break.

2009-07-31 Thread Paul Halliday
Whats the cleanest (I have a really ugly) way to break this: [21/Jul/2009:00:00:47 -0300] into: date=21/jul/2009 time=00:00:47 Caveats: 1) if the day is < 10 the beginning of the string will look like "[1/... 2) the "-0300" will differ depending on DST or TZ. I don't need it though, it just ha

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
-snip--- So I'm almost almost there, but now when I click the # it shows me all records, is my foreach range not right? //Create array with letters AND number sign $letters = range('A','Z');array_push($letters, '#');

Re: [PHP] Re: Regex Problem

2009-07-31 Thread Shawn McKenzie
Shawn McKenzie wrote: > Igor Escobar wrote: >> No no, i need to make an regex to "match" the bold areas in my string. >> Anything between single quotes or double quotes (including quotes and >> double quotes). Understand? >> >> >> Regards, >> Igor Escobar >> Systems Analyst & Interface Designer >>

Re: [PHP] Re: Regex Problem

2009-07-31 Thread Shawn McKenzie
Igor Escobar wrote: > No no, i need to make an regex to "match" the bold areas in my string. > Anything between single quotes or double quotes (including quotes and > double quotes). Understand? > > > Regards, > Igor Escobar > Systems Analyst & Interface Designer > > + http://blog.igorescobar.com >

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
On 7/31/09 3:08 PM, "Bastien Koert" wrote: On Fri, Jul 31, 2009 at 3:10 PM, Miller, Terion wrote: > > > > On 7/31/09 2:00 PM, "Miller, Terion" wrote: > > > > > On 7/31/09 1:56 PM, "Bastien Koert" wrote: > > $letters = ''; > > Nope still gives the same error: Notice: Undefined index: letter

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 3:10 PM, Miller, Terion wrote: > > > > On 7/31/09 2:00 PM, "Miller, Terion" wrote: > > > > > On 7/31/09 1:56 PM, "Bastien Koert" wrote: > > $letters = ''; > > Nope still gives the same error:  Notice: Undefined index: letter > > Well getting closer with this but now my out

[PHP] Re: Regex Problem

2009-07-31 Thread Shawn McKenzie
Igor Escobar wrote: > The solution don't need to be with regex, if anyone can solve this with > other way will be very helpfull . > > > Regards, > Igor Escobar > Systems Analyst & Interface Designer > > + http://blog.igorescobar.com > + http://www.igorescobar.com > + @igorescobar (twitter) > >

[PHP] Re: Regex Problem

2009-07-31 Thread Igor Escobar
The solution don't need to be with regex, if anyone can solve this with other way will be very helpfull . Regards, Igor Escobar Systems Analyst & Interface Designer + http://blog.igorescobar.com + http://www.igorescobar.com + @igorescobar (twitter) On Fri, Jul 31, 2009 at 2:23 PM, Igor Esco

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
On 7/31/09 2:00 PM, "Miller, Terion" wrote: On 7/31/09 1:56 PM, "Bastien Koert" wrote: $letters = ''; Nope still gives the same error: Notice: Undefined index: letter Well getting closer with this but now my output menu is not a clickable link?

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
On 7/31/09 1:56 PM, "Bastien Koert" wrote: $letters = ''; Nope still gives the same error: Notice: Undefined index: letter -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 2:51 PM, Miller, Terion wrote: > > > > --snip--- > > -- > Well I almost have it with this, I keep getting an undefined index $letter > error though and then it outputs the $menu how do I fix that > >  //Create array with letters AND number sign                           > $

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
--snip--- -- Well I almost have it with this, I keep getting an undefined index $letter error though and then it outputs the $menu how do I fix that //Create array with letters AND number sign $letters = range('A','Z'); array_push($letters,

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Shawn McKenzie
Miller, Terion wrote: > > > On 7/31/09 12:43 PM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 1:40 PM, Miller, > Terion wrote: >> >> >> On 7/31/09 12:27 PM, "Bastien Koert" wrote: >> >> $letter = isset($_GET['letter']) ? $_GET['letter'] :""; >> >> echo ''; >> >> foreach(range('A','Z')

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
On 7/31/09 12:43 PM, "Bastien Koert" wrote: On Fri, Jul 31, 2009 at 1:40 PM, Miller, Terion wrote: > > > > On 7/31/09 12:27 PM, "Bastien Koert" wrote: > > $letter = isset($_GET['letter']) ? $_GET['letter'] :""; > > echo ''; > > foreach(range('A','Z') as $c){ > ($letter == $c) ? printf('%s

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 1:40 PM, Miller, Terion wrote: > > > > On 7/31/09 12:27 PM, "Bastien Koert" wrote: > > $letter = isset($_GET['letter']) ? $_GET['letter'] :""; > >  echo ''; > >  foreach(range('A','Z') as $c){ >   ($letter == $c) ? printf('%s ',$c) : printf(' href="browse.php?letter=%s">%s 

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
On 7/31/09 12:27 PM, "Bastien Koert" wrote: $letter = isset($_GET['letter']) ? $_GET['letter'] :""; echo ''; foreach(range('A','Z') as $c){ ($letter == $c) ? printf('%s ',$c) : printf('%s ',$c,$c); } echo ''; //Other $bNumberShown = false; foreach(range('0','9') as $n){ if($le

Re: [PHP] ForEach Range Problems

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 12:53 PM, Miller, Terion wrote: > > > > > I have this script that works, just a couple tweeks needed... > > 1. I don't want it to default to A being selected > 2. I need the number range part to only display one # sign not 10 of them, > somehow I have to have it pull any rec

[PHP] Regex Problem

2009-07-31 Thread Igor Escobar
Hi Folks, I have a serious problem. must create a regular expression against all that is between single quote or double quotes. Easy? Ok, i know, but i need that "everything" must to be too an single quote or double quote. If i have this SQL command: SELECT * FROM TSTRENIC.MEI_ACESSO WHERE UPPER

[PHP] Namespace resolution performance implications

2009-07-31 Thread Andrew Mason
Hi Guys / Girls, We are transitioning our framework to use the namespaces which are available in php 5.3. I found an explanation of the resolution rules here : http://www.sitepoint.com/blogs/2009/07/14/php-namespaces-import-alias-resolution/ ( also listed below) and I was wondering what the perfo

[PHP] ForEach Range Problems

2009-07-31 Thread Miller, Terion
I have this script that works, just a couple tweeks needed... 1. I don't want it to default to A being selected 2. I need the number range part to only display one # sign not 10 of them, somehow I have to have it pull any record that does not start with alpha '; fo

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Jim Lucas
Miller, Terion wrote: > > > On 7/31/09 11:03 AM, "Miller, Terion" wrote: > > > > > On 7/31/09 10:54 AM, "Jim Lucas" wrote: > > Miller, Terion wrote: >> >> On 7/31/09 10:14 AM, "Bastien Koert" wrote: >> >> On Fri, Jul 31, 2009 at 10:59 AM, Miller, >> Terion wrote: >>> >>> On 7/31/09 9:53 A

Re: [PHP] 2 ifs embedded? (RESOLVED)

2009-07-31 Thread Miller, Terion
On 7/31/09 10:54 AM, "Jim Lucas" wrote: Miller, Terion wrote: > > > On 7/31/09 10:14 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:59 AM, Miller, > Terion wrote: >> >> >> On 7/31/09 9:53 AM, "Bastien Koert" wrote: >> >> On Fri, Jul 31, 2009 at 10:28 AM, Miller, >> Terion wrote: >

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
On 7/31/09 11:03 AM, "Miller, Terion" wrote: On 7/31/09 10:54 AM, "Jim Lucas" wrote: Miller, Terion wrote: > > > On 7/31/09 10:14 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:59 AM, Miller, > Terion wrote: >> >> >> On 7/31/09 9:53 AM, "Bastien Koert" wrote: >> >> On Fri, Ju

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
On 7/31/09 10:54 AM, "Jim Lucas" wrote: Miller, Terion wrote: > > > On 7/31/09 10:14 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:59 AM, Miller, > Terion wrote: >> >> >> On 7/31/09 9:53 AM, "Bastien Koert" wrote: >> >> On Fri, Jul 31, 2009 at 10:28 AM, Miller, >> Terion wrote: >

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Jim Lucas
Miller, Terion wrote: > > > On 7/31/09 10:14 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:59 AM, Miller, > Terion wrote: >> >> >> On 7/31/09 9:53 AM, "Bastien Koert" wrote: >> >> On Fri, Jul 31, 2009 at 10:28 AM, Miller, >> Terion wrote: >>> >>> >>> On 7/31/09 8:58 AM, "m0s" wrot

[PHP] Re: This isn't infinitely recursive is it?

2009-07-31 Thread Matt Neimeyer
I like it... Thanks! On Thu, Jul 30, 2009 at 8:04 PM, Ben Dunlap wrote: >> I don't THINK I need to worry about circular mappings... but I'm not >> sure how to check for it if I did... > Would the following work? It avoids recursion entirely and also checks for > circular mappings. You can plug in

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
On 7/31/09 10:14 AM, "Bastien Koert" wrote: On Fri, Jul 31, 2009 at 10:59 AM, Miller, Terion wrote: > > > > On 7/31/09 9:53 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:28 AM, Miller, > Terion wrote: >> >> >> >> On 7/31/09 8:58 AM, "m0s" wrote: >> >> (!empty($row['notes']) && Is

RE: [PHP] String to Date Conversion Problem

2009-07-31 Thread Alice Wei
Looks like what I did by using mm/dd/ was extra, which was probably why it didn't work. Thanks, looks like this is up and running now. Alice > CC: php-general@lists.php.net > From: stu...@stuconnolly.com > To: aj...@alumni.iu.edu > Subject: Re: [PHP] String to Date Conversion Problem >

RE: [PHP] 2 ifs embedded?

2009-07-31 Thread Chrome
> On 7/31/09 9:53 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:28 AM, Miller, > Terion wrote: > > > > > > > > On 7/31/09 8:58 AM, "m0s" wrote: > > > > (!empty($row['notes']) && IsAlpha($row['notes'])) > > > > I tried that and this one: > > > > If (!empty($row['notes']) && ctype_alph

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 10:59 AM, Miller, Terion wrote: > > > > On 7/31/09 9:53 AM, "Bastien Koert" wrote: > > On Fri, Jul 31, 2009 at 10:28 AM, Miller, > Terion wrote: >> >> >> >> On 7/31/09 8:58 AM, "m0s" wrote: >> >> (!empty($row['notes']) && IsAlpha($row['notes'])) >> >> I tried that and this

[PHP] unsubscription not working

2009-07-31 Thread Luke
Trying to unsubscribe from the list, send the email and get this response: 'Acknowledgment: The address tinmach...@googlemail.com was not on the php-general mailing list when I received your request and is not a subscriber of this list.' Where I'm sure that is the address I'm subscribed

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
On 7/31/09 9:53 AM, "Bastien Koert" wrote: On Fri, Jul 31, 2009 at 10:28 AM, Miller, Terion wrote: > > > > On 7/31/09 8:58 AM, "m0s" wrote: > > (!empty($row['notes']) && IsAlpha($row['notes'])) > > I tried that and this one: > > If (!empty($row['notes']) && ctype_alpha($row['notes'])) > > It

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Bastien Koert
On Fri, Jul 31, 2009 at 10:28 AM, Miller, Terion wrote: > > > > On 7/31/09 8:58 AM, "m0s" wrote: > > (!empty($row['notes']) && IsAlpha($row['notes'])) > > I tried that and this one: > > If (!empty($row['notes']) && ctype_alpha($row['notes'])) > > It didn't display the notes at all... > > And this

Re: [PHP] String to Date Conversion Problem

2009-07-31 Thread Stuart Connolly
Hi Alice, Based on the string format that you mentioned (DD MMM YY - DAY) you should be able to transform to any other date using the following: $parts = explode(' ', '23 JUL 09 - THURSDAY'); echo date('m/d/Y', strtotime("{$parts[1]} {$parts[0]} {$parts[2]}")); Cheers Stuart On 31 Jul 200

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
On 7/31/09 8:58 AM, "m0s" wrote: (!empty($row['notes']) && IsAlpha($row['notes'])) I tried that and this one: If (!empty($row['notes']) && ctype_alpha($row['notes'])) It didn't display the notes at all... And this one...doesn't display if the field has a 0 in it but I still need it to? I

Re: [PHP] Freeing Memory

2009-07-31 Thread Nisse Engström
On Fri, 31 Jul 2009 07:54:13 -0400, Dan Shirah wrote: >> >> How does that work considering that mysql_query() only >> returns true or false on INSERT? I'd expect the script >> to fail on $result not being a valid resource. >> > > I don't know about mysql as I work with MSSQL Server and Informix,

[PHP] String to Date Conversion Problem

2009-07-31 Thread Alice Wei
Hi, Guys: I am trying to turn a prepared line into a date format, and the string looks something like this: 23 JUL 09 - THURSDAY, and I am trying to change the string to a mm/dd/ format that looks like 07/23/2009. I tried to use strtotime() but it gave me nothing. Here is the cod

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread m0s
Miller, Terion wrote: > I need this to say : If row notes is not empty and is alpha echo notes > > How do I get the is alpha part in here; > > If (!empty($row['notes'])) { > > > echo(" $trimNotes "); > > } > > I tried. > > If (IsAlpha($row['notes'])) { > > > echo(" $trimNotes ");

Re: [PHP] 2 ifs embedded?

2009-07-31 Thread Ashley Sheridan
On Fri, 2009-07-31 at 06:53 -0700, Miller, Terion wrote: > I need this to say : If row notes is not empty and is alpha echo notes > > How do I get the is alpha part in here; > > If (!empty($row['notes'])) { > > > echo(" $trimNotes "); > > } > > I tried. > > If (IsAlpha($row['note

Re: [PHP] PHPBB Speed Issues

2009-07-31 Thread Ashley Sheridan
On Fri, 2009-07-31 at 11:27 +0100, David Otton wrote: > 2009/7/31 Paul Scott : > > -1. Measure everything. No point implementing a change that slows > things down. Implement low-hanging-fruit first (eg a CDN) > 0. Optimise your existing setup before adding more layers > > 1. Cache as much as you c

[PHP] 2 ifs embedded?

2009-07-31 Thread Miller, Terion
I need this to say : If row notes is not empty and is alpha echo notes How do I get the is alpha part in here; If (!empty($row['notes'])) { echo(" $trimNotes "); } I tried. If (IsAlpha($row['notes'])) { echo(" $trimNotes "); } But it broke the whole script. --Terion

Re: [PHP] Freeing Memory

2009-07-31 Thread Dan Shirah
> > How does that work considering that mysql_query() only > returns true or false on INSERT? I'd expect the script > to fail on $result not being a valid resource. > I don't know about mysql as I work with MSSQL Server and Informix, but for me it works like this: $insert = ifx_prepare("INSERT

RE: [PHP] preg_match too greedy

2009-07-31 Thread Ford, Mike
> -Original Message- > From: b [mailto:p...@logi.ca] > Sent: 30 July 2009 03:17 > > > > > >>> 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 th

Re: [PHP] Freeing Memory

2009-07-31 Thread Nisse Engström
On Thu, 30 Jul 2009 10:42:26 -0400, Dan Shirah wrote: > I don't know what version of SQL you are using, but I have found that using: > > mysql_free_result($result); > mssql_free_result($result); > ifx_free_result($result); > > Helped my queries run much faster and use less resources. I had somet

Re: [PHP] PHPBB Speed Issues

2009-07-31 Thread David Otton
2009/7/31 Paul Scott : -1. Measure everything. No point implementing a change that slows things down. Implement low-hanging-fruit first (eg a CDN) 0. Optimise your existing setup before adding more layers > 1. Cache as much as you can (everything) > 2. Minimise HTTP requests > 3. Use an opcode cac

Re: [PHP] PHPBB Speed Issues

2009-07-31 Thread Paul Scott
Ashley Sheridan wrote: > I've optimised the images in the template, enabled the GZ compression, > and it's only improved the speed by a mere fraction. I have noticed that > the page itself doesn't display until after this delay, so I was > guessing that I could maybe force the buffer to flush at ke

[PHP] PHPBB Speed Issues

2009-07-31 Thread Ashley Sheridan
Hi Guys, I know this is maybe a bit specific for the general list, but thought I'd throw it out there anyway as I reckon a lot of you have had experience with PHPBB at some point or another. We've got an existing installation of the forum here, that's been active for a couple of years and is fairl

Re: [PHP] Extract an element from XML

2009-07-31 Thread Aschwin Wesselius
Aschwin Wesselius wrote: Angelo Zanetti wrote: Hi all, I have the following segment of XML: 165432 Now I want to get the value of the BookingReference where the ReferenceSource = "api". In other words I want to get the value 165432. I have the following code: $ItemConfirmationReference2 = $x

Re: [PHP] Extract an element from XML

2009-07-31 Thread Aschwin Wesselius
Angelo Zanetti wrote: Hi all, I have the following segment of XML: 165432 Now I want to get the value of the BookingReference where the ReferenceSource = "api". In other words I want to get the value 165432. I have the following code: $ItemConfirmationReference2 = $xpath->query('BookingR

Re: [PHP] fileinfo returning wrong mime type for Excel files

2009-07-31 Thread Ashley Sheridan
On Thu, 2009-07-30 at 21:26 -0400, b wrote: > 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 l

Re: [PHP] Better Formatting Options?

2009-07-31 Thread Richard Heyes
Hi, >        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 can shorten it. Personally, I would advise against trying to cram as much as possible into the least amount of space as possible, and instead going for verbosi

Re: [PHP] Ridiculous ..won't print or echo ...(RESOLVED)

2009-07-31 Thread ej S(ibr(ina
I'm sorry for this post. It's only testing. Thanks for understand. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Ridiculous ..won't print or echo ...(RESOLVED)

2009-07-31 Thread ej S(ibr(ina
Just testing message Miller, Terion napsal(a): > Yep I forgot about escaping the $ > > > > On 7/29/09 10:51 AM, "Ford, Mike" wrote: > >> -Original Message- >> From: Miller, Terion [mailto:tmil...@springfi.gannett.com] >> Sent: 29 July 2009 16:36 >> >> Ok in my output to Quark I need t

Re: [PHP] Asterisk anyone?

2009-07-31 Thread Per Jessen
Nathan Nobbe wrote: > 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 no

[PHP] Extract an element from XML

2009-07-31 Thread Angelo Zanetti
Hi all, I have the following segment of XML: 165432 Now I want to get the value of the BookingReference where the ReferenceSource = "api". In other words I want to get the value 165432. I have the following code: $ItemConfirmationReference2 = $xpath->query('BookingReference ReferenceSource'