[FX.php List] RE: FX.php_List Digest, Vol 77, Issue 8

Elberta A Donahue ead4 at cornell.edu
Tue Jan 11 07:08:48 MST 2011


remove me from this list please

________________________________________
From: fx.php_list-bounces at mail.iviking.org [fx.php_list-bounces at mail.iviking.org] On Behalf Of fx.php_list-request at mail.iviking.org [fx.php_list-request at mail.iviking.org]
Sent: Thursday, December 23, 2010 2:00 PM
To: fx.php_list at mail.iviking.org
Subject: FX.php_List Digest, Vol 77, Issue 8

Send FX.php_List mailing list submissions to
        fx.php_list at mail.iviking.org

To subscribe or unsubscribe via the World Wide Web, visit
        http://www.iviking.org/mailman/listinfo/fx.php_list
or, via email, send a message with subject or body 'help' to
        fx.php_list-request at mail.iviking.org

You can reach the person managing the list at
        fx.php_list-owner at mail.iviking.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of FX.php_List digest..."


Today's Topics:

   1. RE: [OFF] printable very wide table? (Andrew Denman)
   2. Re: [OFF] printable very wide table? (Joel Shapiro)
   3. Get portals as array (Masayuki Nii)


----------------------------------------------------------------------

Message: 1
Date: Wed, 15 Dec 2010 11:53:10 -0600
From: Andrew Denman <adenman at tmea.org>
Subject: RE: [FX.php List] [OFF] printable very wide table?
To: FX.php Discussion List <fx.php_list at mail.iviking.org>
Message-ID: <94A602F7D7242349A5B8846DEC4A5F8B2944F26DA8 at mail>
Content-Type: text/plain; charset="us-ascii"

We've been using "page-break-after: always;" for a few years now with great success.  If all you want is a normal page break, this should work in all browsers.

Andrew Denman

-----Original Message-----
From: fx.php_list-bounces at mail.iviking.org [mailto:fx.php_list-bounces at mail.iviking.org] On Behalf Of Dale Bengston
Sent: Tuesday, December 14, 2010 10:11 PM
To: FX.php Discussion List
Subject: Re: [FX.php List] [OFF] printable very wide table?

In my experience, and I last smashed my head on this last week, css page-break attributes are not well supported by browsers. They work in Firefox and that's about it.

With HTML tables, though, I don't think you really have to worry. They break pretty reliably between rows.

Dale

On Dec 14, 2010, at 9:42 PM, Tim 'Webko' Booth wrote:

> Dear Joel,
>>
>> That's a clever idea.  Thanks!
>>
>> I'll be testing the CSS page-breaks once I can dive back into this project.  If it's not near-foolproof, I'll be going w/ PDFs.
>
> Which might be interesting as well... I'm kinda intrigued now, so I fiddled with FPDF for a few minutes...
>
> http://apachescricket.com/table_pdf_A4.php
> Is set to A4 portrait, making the table off the right edge - only prints the left hand page
>
> http://apachescricket.com/table_pdf_custom.php
> Is set to a custom width, with the table fitting inside - also doesn't print properly...
>
> YMMV
>
> Webko
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list

_______________________________________________
FX.php_List mailing list
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list


------------------------------

Message: 2
Date: Wed, 15 Dec 2010 15:49:46 -0800
From: Joel Shapiro <jsfmp at earthlink.net>
Subject: Re: [FX.php List] [OFF] printable very wide table?
To: "FX.php Discussion List" <fx.php_list at mail.iviking.org>
Message-ID: <ECF233D9-EF25-42D5-9F9D-F66294B51DE1 at earthlink.net>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes

Thanks Andrew & Dale for your experiences.  I'll report back on mine
once I'm back to working on this project (currently in estimate/
proposal mode... yuck)

-Joel


On Dec 15, 2010, at 9:53 AM, Andrew Denman wrote:

> We've been using "page-break-after: always;" for a few years now
> with great success.  If all you want is a normal page break, this
> should work in all browsers.
>
> Andrew Denman
>
> -----Original Message-----
> From: fx.php_list-bounces at mail.iviking.org [mailto:fx.php_list-bounces at mail.iviking.org
> ] On Behalf Of Dale Bengston
> Sent: Tuesday, December 14, 2010 10:11 PM
> To: FX.php Discussion List
> Subject: Re: [FX.php List] [OFF] printable very wide table?
>
> In my experience, and I last smashed my head on this last week, css
> page-break attributes are not well supported by browsers. They work
> in Firefox and that's about it.
>
> With HTML tables, though, I don't think you really have to worry.
> They break pretty reliably between rows.
>
> Dale
>
> On Dec 14, 2010, at 9:42 PM, Tim 'Webko' Booth wrote:
>
>> Dear Joel,
>>>
>>> That's a clever idea.  Thanks!
>>>
>>> I'll be testing the CSS page-breaks once I can dive back into this
>>> project.  If it's not near-foolproof, I'll be going w/ PDFs.
>>
>> Which might be interesting as well... I'm kinda intrigued now, so I
>> fiddled with FPDF for a few minutes...
>>
>> http://apachescricket.com/table_pdf_A4.php
>> Is set to A4 portrait, making the table off the right edge - only
>> prints the left hand page
>>
>> http://apachescricket.com/table_pdf_custom.php
>> Is set to a custom width, with the table fitting inside - also
>> doesn't print properly...
>>
>> YMMV
>>
>> Webko
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list



------------------------------

Message: 3
Date: Sat, 18 Dec 2010 17:46:32 +0900 (JST)
From: Masayuki Nii <msyk at msyk.net>
Subject: [FX.php List] Get portals as array
To: fx.php_list at mail.iviking.org
Message-ID: <132863590.0.1292661992984.JavaMail.msyk at msyk.net>
Content-Type: text/plain; charset=UTF-8

Hi everyone,

I've implemented new method RemainAsArray and committed to SF.net as Revision
9. I've posted my conclusion as a preliminary to "http://msyk.net/fmp/fx_ja/
trial.html."

I will explain how to work the method, suppose the following a simple layout
and fields. The starting "-" line means one field.

========================In Layout
Fields out side of portal:
- name
- telephone

Portal: contact_list
- contact_list::date
- contact_list::person

Portal: payment_list
- payment_list::date
- payment_list::price
========================In Layout

You call the FlattenInnerArray method and the RemainAsArray method as following.
If you set the 3rd parameter of DoFxAction method, You don't need to call the
FlattenInnerArray method. As for the RemainAsArray method, you should write
the portal name (i.e. TOC name) as  parameters. You can specify from 1 to 12
parameters, and at least one, but you can increase up to 12.

$fx = new FX('127.0.0.1', '80', 'FMPro7', 'HTTP');
.... set various parameters ....
$fx->FlattenInnerArray();// This is same effect for 3rd paramter of DoFxAction
$fx->RemainAsArray( 'payment_list', 'contact_list' );
$result = $fx->DoFxAction( FX_ACTION_FIND, TRUE, FALSE, 'full' );

I will a sample of the contents of $result variable below. You don't need to
specify the [0] after ["name"]. Otherwise the field in the portal will be retrieve
as like without calling the FlattenInnerArray method. You need numeric index
after portal field ["contact_list::date"].

array(YY)       {
        ["data"]=>
        array(XX)       {
                ["1.5"]=>
                array(6)        {
                        ['name']=>
                        string(NN) "string string"
                        ['telephone']=>
                        string(NN) "string string"
                        ['contact_list::date']=>
                        array(2)        {
                                [0]=>
                                string(N) "string string"
                                [1]=>
                                string(N) "string string"
                        }
                        ['contact_list::person']=>
                        array(2)        {
                                [0]=>
                                string(N) "string string"
                                [1]=>
                                string(N) "string string"
                        }
                        ['payment_list::date']=>
                        array(3)        {
                                [0]=>
                                string(N) "string string"
                                [1]=>
                                string(N) "string string"
                                [2]=>
                                string(N) "string string"
                        }
                        ['payment_list::price']=>
                        array(3)        {
                                [0]=>
                                string(N) "string string"
                                [1]=>
                                string(N) "string string"
                                [2]=>
                                string(N) "string string"
                        }
                }
        :
        :


Furthermore, the RemainAsArray method can affect with different result. If the
parameter of the RemainAsArray function is array, the portal will expand to
array. At least one parameter is array, it will affect all portal results.

$fx = new FX('127.0.0.1', '80', 'FMPro7', 'HTTP');
.... set various parameters ....
$fx->FlattenInnerArray();// This is same effect for 3rd paramter of DoFxAction
$fx->RemainAsArray( array('payment_list'), array('contact_list') );
$result = $fx->DoFxAction( FX_ACTION_FIND, TRUE, FALSE, 'full' );

This is a sample result.

array(YY)       {
        ["data"]=>
        array(XX)       {
                ["1.5"]=>
                array(4)        {
                        ['name']=>
                        string(NN) "string string"
                        ['telephone']=>
                        string(NN) "string string"
                        ['contact_list]=>
                        array(2)        {
                                [0]=>
                                array(2)        {
                                        ["contact_list::date"]=>
                                        string(N) "string string"
                                        ["contact_list::person"]=>
                                        string(N) "string string"
                                }
                                [1]=>
                                array(2)        {
                                        ["contact_list::date"]=>
                                        string(N) "string string"
                                        ["contact_list::person"]=>
                                        string(N) "string string"
                                }
                        }
                        ['payment_list]=>
                        array(3)        {
                                [0]=>
                                array(2)        {
                                        ["payment_list::date"]=>
                                        string(N) "string string"
                                        ["payment_list::price"]=>
                                        string(N) "string string"
                                }
                                [1]=>
                                array(2)        {
                                        ["payment_list::date"]=>
                                        string(N) "string string"
                                        ["payment_list::price"]=>
                                        string(N) "string string"
                                }
                                [2]=>
                                array(2)        {
                                        ["payment_list::date"]=>
                                        string(N) "string string"
                                        ["payment_list::price"]=>
                                        string(N) "string string"
                                }

                        }
                }
        :
        :

I don't check with heavy database, but the overhead of these program will be
small thing. Anyway if you use these methods, you don't worry about trailing [0].

_______________________________________________________________
Masayuki Nii/Masayuki Nii <msyk at msyk.net> <msyk at mac.com>:iChat Ready
Web Site <http://msyk.net> / INTER-Mediator [for Web App] http://msyk.net/im
OME [Email] http://mac-ome.jp / Tutoring Sevice http://msyk.net/tutoring.html



------------------------------

_______________________________________________
FX.php_List
FX.php_List at mail.iviking.org
http://www.iviking.org/mailman/listinfo/fx.php_list

End of FX.php_List Digest, Vol 77, Issue 8
******************************************


More information about the FX.php_List mailing list