News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Problema aggiunta bottone "HomePortale

Started by pr0xy00, October 10, 2010, 01:01:50 PM

Previous topic - Next topic

pr0xy00

Ragazzi ho aggiunto il bottone per reindirizzare smf sul portale ma non riesco a inserire il link per farlo arrivare sul portale, cioè il link lo riesco a inserire ma ma reindirizza su hxxp:www.sito.it/fourm/www.sito.it [nonactive] e pure ho fatto tutto correttamente.

Questo è il codice del bottone

// Show the [home_portale] button.
   echo ($current_action=='home_portale' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
            <td valign="top" class="maintab_' , $current_action == 'home_portale' ? 'active_back' : 'back' , '">
               <a href="www.sito.it">', "Home Portale" , '</a>
            </td>' , $current_action == 'home_portale' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' :


sapete aiutarmi?

emanuele

Quote from: pr0xy00 on October 10, 2010, 01:01:50 PM
pure ho fatto tutto correttamente.
Se avessi fatto tutto correttamente funzionerebbe... :P ;)

Se in un tag "a" non metti "http://", il link viene interpretato come "relativo" (magari le parole non sono il massimo di tecnicismo (dato che nemmeno io son sicuro di quel che scrivo), ma rendono l'idea) e quindi viene aggiunto all'inizio l'indirizzo della pagina che stai visualizzando, quindi il codice "corretto" può essere:

// Show the [home_portale] button.
   echo ($current_action=='home_portale' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
            <td valign="top" class="maintab_' , $current_action == 'home_portale' ? 'active_back' : 'back' , '">
               <a href="http://www.sito.it">', "Home Portale" , '</a>
            </td>' , $current_action == 'home_portale' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' :


oppure:
// Show the [home_portale] button.
   echo ($current_action=='home_portale' || $context['browser']['is_ie4']) ? '<td class="maintab_active_' . $first . '">&nbsp;</td>' : '' , '
            <td valign="top" class="maintab_' , $current_action == 'home_portale' ? 'active_back' : 'back' , '">
               <a href="/">', "Home Portale" , '</a>
            </td>' , $current_action == 'home_portale' ? '<td class="maintab_active_' . $last . '">&nbsp;</td>' :


Take a peek at what I'm doing! ;D




Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

pr0xy00

Infatti ho risolto mettendo solo "/ " grazie tante

Advertisement: