ENXF NET
Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
- Joined
- Nov 13, 2018
- Messages
- 33,772
- Points
- 823
Reputation:
PHP:
This code does assume that field
Read more
Continue reading...
Code:
protected function getContentTypeId($contentType)
{
if (empty($this->session->extra['contentTypeId']))
{
$this->session->extra['contentTypeId'] = $this->sourceDb->fetchPairs("
SELECT class, contenttypeid
FROM contenttype
");
}
return $this->session->extra['contentTypeId'][$contentType];
}
This code does assume that field
class in table contenttype is unique - this is not necessarily the case, it is only guaranteed...Read more
Continue reading...