UPDATE with multiple WHERE and SELECT condition - MySql
Your query (while removing PHP code and formatting) looks like

UPDATE ativos  
SET ativo = ?, 
    comentario = ?, 
    data_aquisicao = ?, 
    localizacao = ?, 
    fabricante = ?, 
    modelo = ?, 
    imei = ?,         
    numero_serie = ?, 
    ativo_sap = ?, 
    anexo_a = ?, 
    evento = ?, 
    data_evento = ?, 
    SELECT id_colaborador 
    FROM colaboradores 
    WHERE nome = ? 
    AND WHERE id_ativo = ?


It is syntactically incorrect. Use Multiple-table UPDATE syntax. Final query must look near

UPDATE ativos a
  JOIN colaboradores c 
/* next line maybe wrong, question is not clear */
    ON a.id_ativo = c.id_colaborador 
SET a.ativo = ?, 
    a.comentario = ?, 
    a.data_aquisicao = ?, 
    a.localizacao = ?, 
    a.fabricante = ?, 
    a.modelo = ?, 
    a.imei = ?,         
    a.numero_serie = ?, 
    a.ativo_sap = ?, 
    a.anexo_a = ?, 
    a.evento = ?, 
    a.data_evento = ?
/* next line maybe wrong, question is not clear */
WHERE c.nome = ?