PHP:
скопировать код в буфер обмена
скопировать код в буфер обмена
- private function getAlias(string $id, string $table) : string
- {
- try
- {
- $this->queryBuilder->clear();
- $this->queryBuilder->select('alias')
- ->from($this->db->quoteName($table))
- ->where($this->db->quoteName('id') . ' = ' . (int) $id);
- $this->db->setQuery($this->queryBuilder);
- return (string) $this->db->loadResult();
- }
- catch (Exception $e)
- {
- echo $e->getMessage();
- return '';
- }
- }