Jump to content

Change Function name in loop


shogemuk

Recommended Posts

Thanks scootstah for the quick reply.

How would you use either of those functions to change the name of this function in a loop?

 

function createTemplatedSlide(PHPPowerPoint $objPHPPowerPoint)

{

// Create slide

$slide = $objPHPPowerPoint->createSlide();

 

// Add background image

    $slide->createDrawingShape()

          ->setName('Background')

          ->setDescription('Background')

          ->setPath('./images/realdolmen_bg.jpg')

          ->setWidth(950)

          ->setHeight(720)

          ->setOffsetX(0)

          ->setOffsetY(0);

 

    // Add logo

    $slide->createDrawingShape()

          ->setName('PHPPowerPoint logo')

          ->setDescription('PHPPowerPoint logo')

          ->setPath('./images/phppowerpoint_logo.gif')

          ->setHeight(40)

          ->setOffsetX(10)

          ->setOffsetY(720 - 10 - 40);

 

    // Return slide

    return $slide;

}

 

Thanks again

Hi does anyone please know how to solve this.  Please any help in how to change this functions name in a loop.

function createTemplatedSlide(PHPPowerPoint $objPHPPowerPoint)

{

  // Create slide

  $slide = $objPHPPowerPoint->createSlide();

 

  // Add background image

    $slide->createDrawingShape()

          ->setName('Background')

          ->setDescription('Background')

          ->setPath('./images/realdolmen_bg.jpg')

          ->setWidth(950)

          ->setHeight(720)

          ->setOffsetX(0)

          ->setOffsetY(0);

 

    // Add logo

    $slide->createDrawingShape()

          ->setName('PHPPowerPoint logo')

          ->setDescription('PHPPowerPoint logo')

          ->setPath('./images/phppowerpoint_logo.gif')

          ->setHeight(40)

          ->setOffsetX(10)

          ->setOffsetY(720 - 10 - 40);

 

    // Return slide

    return $slide;

}

 

Thanks again

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.