• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Lack of interest XenForo_Helper_Url::getTitle

R

ragtek

Guest
#1
IMO the second parameter (text) should get a default value, and if it's not set, return the url and if it's set return text (in the excpeption):)

$pageTitle = XenForo_Helper_Url::getTitle($link['url']);
is shorter & nicer as
$pageTitle = XenForo_Helper_Url::getTitle($link['url'], $link['url']);
 
R

ragtek

Guest
#2
next suggestion:


pls include a 3. parameter for options!
XenForo_Helper_Http::getClient accepts options as second parameter.
Sometimes it's necessary to send own option params in getTitle to receive the real title.

One way would be to use a own Zend_Http_Client instance, but IMO it's not necessary because xenforo is already providing the factory ( XenForo_Helper_Http::getClient )for the Zend_Http_Client object