1
Vote

Problems hyperlinking an image

description

I'm trying to learn how to hyperlink an image to a URL and also how to hyperlink an image to another slide in my document. Can someone please explain what I'm doing wrong here? (please see bottom line)
// Create a shape (text)
echo date('H:i:s') . ' Create a shape (rich text)'.EOL;
$shape = $currentSlide->createRichTextShape();
$shape->setHeight(200);
$shape->setWidth(600);
$shape->setOffsetX(10);
$shape->setOffsetY(400);
$shape->getActiveParagraph()->getAlignment()->setHorizontal( Alignment::HORIZONTAL_LEFT );
$shape->getHyperlink()->setUrl('http://google.com');

comments