Zikula: A Flexible Open Source Content Management System
home | forum | international support | contact us

Support Forum

Start ::  Developers Corner ::  Module Development ::  pnDBGetConn() under 0.726

Moderated by: Support Team

Bottom
pnDBGetConn() under 0.726

  • Link to this postingPosted: 24.02.2005, 05:11
    Profile
    sbszine
    rank:
    Freshman Freshman
    registered:
     January 2005
    Status:
    offline
    last visit:
    14.02.06
    Posts:
    33
    In the Example module, the recommended way of getting an ADODB connection object under 0.75x is by reference, i.e. something like:
    Code
    $goDatabase =& pnDBGetConn( true );

    The old way in the Template module is by value:
    Code
    list( $loDatabase ) = pnDBGetConn();

    The module I'm writing is for 0.726, so I'm doing things the old way. My question is, is there any reason to get the ADODB connection by value under 0.726, or can I get it by reference and save myself some overhead, e.g.:
    Code
    list( $loDatabase ) =& pnDBGetConn();

    Perhaps the reference would then point to something local in the list function and be counter-productive?

Start ::  Developers Corner ::  Module Development ::  pnDBGetConn() under 0.726

Main Menu

Extensions Database

Documentation

Development

Login





 


 Log in Problems?
 New User? Sign Up!

Donate to Zikula