Como pegar o apelido do artigo?

  • allanppss
  • Avatar de allanppss Autor do Tópico
  • Offline
  • JCB! Estagiário
  • JCB! Estagiário
Mais
16 anos 4 semanas atrás #15637 por allanppss
allanppss created the topic: Como pegar o apelido do artigo?
eu to precisando pegar o apelido do artigo atual mas não to conseguindo achar o nome da variável responsavel, alguem sabe?

tipo, pra pegar o id do usuário logado é:
[color=#0000FF:2x40638t]$user->id;[/color:2x40638t]

então pra pegar o apelido do artigo seria:
[color=#0000FF:2x40638t]$article->title;[/color:2x40638t]

???

tentei assim mas não deu, alguem sabe o nome da variável?

se alguem puder me ajudar eu agradeço

Please Entrar ou Registrar to join the conversation.


  • allanppss
  • Avatar de allanppss Autor do Tópico
  • Offline
  • JCB! Estagiário
  • JCB! Estagiário
Mais
16 anos 4 semanas atrás #15640 por allanppss
allanppss replied the topic: Re: Como pegar o apelido do artigo?
to tentando e ainda não achei...

se alguem puder ajudar

Please Entrar ou Registrar to join the conversation.

  • allanppss
  • Avatar de allanppss Autor do Tópico
  • Offline
  • JCB! Estagiário
  • JCB! Estagiário
Mais
16 anos 4 semanas atrás #15656 por allanppss
allanppss replied the topic: Re: Como pegar o apelido do artigo?
ou pelo menos pegar o ID do artigo? alguem ajuda ae <!-- s:? --><img src="{SMILIES_PATH}/icon_e_confused.gif" alt=":?" title="Confuso" /><!-- s:? -->

eu tentei:
$id_artigo = $_GET;

só que ta puxando um valor errado =/

Please Entrar ou Registrar to join the conversation.

Mais
16 anos 4 semanas atrás #15659 por Uriel
Uriel replied the topic: Re: Como pegar o apelido do artigo?
acho que quem pode te ajudar
é o Elvis Vinicius
ele sabe mecher nessa area !!
abraço

Please Entrar ou Registrar to join the conversation.

Mais
16 anos 3 semanas atrás #15734 por elvisvinicius
elvisvinicius replied the topic: Re: Como pegar o apelido do artigo?

allanppss escreveu: ou pelo menos pegar o ID do artigo? alguem ajuda ae <!-- s:? --><img src="{SMILIES_PATH}/icon_e_confused.gif" alt=":?" title="Confuso" /><!-- s:? -->

eu tentei:
$id_artigo = $_GET;

só que ta puxando um valor errado =/


Do jeito tradicional:
<?php
if ($_GET&#91;'option'&#93; == "com_content" && $_GET&#91;'view'&#93; == "article") {
	$id_artigo = (int) $_GET&#91;'id'&#93;;
}
?>

Do jeito "Joomla!":
<?php
$get = JRequest::get('get');

if ($get&#91;'option'&#93; == "com_content" && $get&#91;'view'&#93; == "article") {
	$id_artigo = (int) $get&#91;'id'&#93;;
}
?>

Se estiver colocando código no template e o método 2 falhar, use o 1.
Se estiver desenvolvendo extensões, use o método 2.
Se estiver desenvolvendo plugin de conteúdo, me avisa que tem um jeito correto de lidar com artigos.

( ^ ^)

Please Entrar ou Registrar to join the conversation.