|
Open a newsletter in a new page or a popup |
|
|
|
|
The aim of this tutorial is to show you how to open a newsletter (an archive) in a new page or a popup.
Edit the file mailings.acajoom.html.php from the directory "<Joomla>/administrator/components/com_acajoom" and from line 141 to 148, you will see the parameter $show['index'] several times : if ( function_exists('sefRelToAbs') AND $GLOBALS[ACA.'use_sef'] ) { $link = sefRelToAbs($show['index'].'.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id . $item ); } else { $link = $show['index'].'.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id . $item; } } else { $link = $show['index'].'.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id .$item; }
If you replace each $show['index'] by 'index2.php', that will do the job : if ( function_exists('sefRelToAbs') AND $GLOBALS[ACA.'use_sef'] ) { $link = sefRelToAbs('index2.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id . $item ); } else { $link = 'index2.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id . $item; } } else { $link = 'index2.php?option=com_acajoom&act=' . $action . '&task=view&listid='.$mailing->list_id.'&mailingid=' .$mailing->id .$item; }
After editing these lines, go to the line 163 : <td align="left"><a href="<?php echo $link; ?>" >
And replace it by : - If you want to open in a new page :
<td align="left"><a href="<?php echo $link; ?>" target="_blank" >
- If you want to open in a popup :
<td align="left"><a href="#" onClick="window.open('<?php echo $link; ?>', 'Detail', 'toolbar=0,scrollbars=1,location=0,statusbar=1,menubar=0,resizable=1,width=600,height=500');" >
Save the file. |
|
Last Updated ( Friday, 09 May 2008 )
|