Typo3 Using typoLink in your own FrontEnd (FE) extension


Using the the typoLink function in your own Typo3 extension is very simple. First you need an instance of the tslib_cObj object. Then setup the config array and call the method. That’s all.
To create the instance you need to include the object first:

include_once(PATH_site.'typo3/sysext/cms/tslib/class.tslib_content.php');

Then create the tslib_cObj:

$cObj=t3lib_div::makeInstance('tslib_cObj');

Setup the config array: (See the typoLink documentation of possible entries)

$conf = array( 'parameter' => 'http://www.bstar.de' );

Call the method:

echo $cObj->typoLink('bstar.de', $conf );


If you don’t want to setup the conf array and don’t need the power of typoLink you can use getTypoLink also:

echo $cObj->getTypoLink('bstar.de', 'http://www.bstar.de' );

If you have any query then feel free to contact me at Jainish Senjaliya

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s