I am trying to add a script to the field in the form SEBLOD, but for some reason this is not working.
I want the lyrics to become a field of another color, for example.
<?php
defined( '_JEXEC' ) or die;
//FORM
$pn=$cck->renderField('asspf_pnome');
$sn=$cck->renderField('asspf_snome');
$cpf=$cck->renderField('asspf_cpf');
$rg=$cck->renderField('asspf_rg');
$ssp=$cck->renderField('asspf_ssp');
$an=$cck->renderField('asspf_aniversario');
$tr=$cck->renderField('asspf_telresidencial');
$tc=$cck->renderField('asspf_telcelular');
$ep=$cck->renderField('asspf_emailp');
$es=$cck->renderField('asspf_emails');
$p=$cck->renderField('asspf_pais');
$cep=$cck->renderField('asspf_cep');
$rua=$cck->renderField('asspf_rua');
$ba=$cck->renderField('asspf_bairro');
$ci=$cck->renderField('asspf_cidade');
$uf=$cck->renderField('asspf_uf');
$cq=$cck->renderField('asspf_cq');
$sub=$cck->renderField('asspf_btsubmeter');
?>
<script type='text/javascript' src='http://code.jquery.com/jquery-1.5.1.min.js'></script>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.min.js"></script>
//MY SCRIPT
<script>
$(document).ready(function() {
document.getElementsByName('<?php echo $cck->get('asspf_cq')->name; ?>').style.backgroundcolor="red";
});
</script>
//IN THE SITE SHOW
<?php
echo $pn;
echo $sn;
echo $cpf;
echo $rg;
echo $ssp;
echo $an;
echo $tr;
echo $tc;
echo $ep;
echo $es;
echo $p;
echo $cep;
echo $rua;
echo $ba;
echo $ci;
echo $uf;
echo $cq;
echo $sub;
//ADICIONANDO GRUPOS AO SISTEMA DE CADASTRO ASSINATURA PESSOA FÍSICA -----------------------------------
/*$db = JFactory::getDBO();
$query = 'SELECT userid FROM mv478_session WHERE client_id=0';
$db->setQuery($query);
$nome_sess = $db->loadResult();
$query = 'INSERT INTO #__user_usergroup_map VALUES ('.$nome_sess.', 13)' ;
$db->setQuery($query);
*/
//--------------------------------------------------------------------------------------------------------
?>