Brauche Hilfe beim Einbinden eines iframes ins Portal...

Du hast Probleme beim Einbau oder bei der Benutzung eines Mods? In diesem Forum bist du richtig.
Forumsregeln
phpBB 2.0 hat das Ende seiner Lebenszeit überschritten
phpBB 2.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 2.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf phpBB 3.0, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
Antworten
Webgiant
Mitglied
Beiträge: 32
Registriert: 16.07.2004 04:42

Brauche Hilfe beim Einbinden eines iframes ins Portal...

Beitrag von Webgiant »

Hallo,

habe ein großes Problem... Mal wieder... :oops: 8) :lol:
Und zwar will ich über ein Iframe die Newsseite meines Boards auf dem Portal anzeigen lassen...
Leider wird aber gar kein Frame im Portal angezeigt, nicht mal ein Kasten. Als ob es gar keinen Quellcode dafür gäbe...

Hier der Quellcode...

Code: Alles auswählen

<!-- ################################################# CENTER START ################################################# -->

<!-- ##### WELCOME START ##### -->

<!-- BEGIN welcome_text -->
<table width="100%" cellpadding="3" cellspacing="1" border="0" class="forumline">
<tr>
<th>{SITENAME}</th>
</tr>
<tr>
<td class="row1" align="left"><p class="genmed"><br><p>Hallo und herzlich willkommen auf www.whs2004.de<br>
Dies ist die interaktive Commnunity des Willy Hellpach Gymnasiums...<br><p>
</p></td>
</tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" class="tbl"><tr><td class="tbll"><img src="images/spacer.gif" alt="" width="8" height="4" /></td><td class="tblbot"><img src="images/spacer.gif" alt="" width="8" height="4" /></td><td class="tblr"><img src="images/spacer.gif" alt="" width="8" height="4" /></td></tr></table>
<br />
<!-- END welcome_text -->

<!-- ##### WELCOME END ##### -->



<!-- ##### NEWS START ##### -->

<!-- BEGIN news_text -->
<table width="100%" cellpadding="3" cellspacing="1" border="0" class="forumline">
<tr>
<th>{SITENAME}</th>
</tr>
<tr>
<td align="left"> <iframe src="http://www.whs2004.de/news_index.php" width="100%" height="100%" frameborder="1" allowTransparency="true"></iframe>
</td>
</tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" class="tbl"><tr><td class="tbll"><img src="images/spacer.gif" alt="" width="8" height="4" /></td><td class="tblbot"><img src="images/spacer.gif" alt="" width="8" height="4" /></td><td class="tblr"><img src="images/spacer.gif" alt="" width="8" height="4" /></td></tr></table>
<br />
<!-- END news_text -->

<!-- ##### NEWS END ##### -->




<!-- ################################################# CENTER END ################################################# -->
Vielleicht kann mir ja kurz jemand weiterhelfen. Die Table oben drüber mit der Begrüßung wird zum Beispiel angezeigt...
Ach ja benutze den Intro + Portal MOD - Version 1.50a...


Gruß Helge 8)
Wissen ist Macht, wenn man es nutzt.
Benutzeravatar
Markus67
Ehrenadmin
Beiträge: 28346
Registriert: 12.01.2004 16:02
Wohnort: Neuss
Kontaktdaten:

Beitrag von Markus67 »

Hi ...

entferne ...

Code: Alles auswählen

<!-- ##### NEWS START ##### --> 

<!-- BEGIN news_text --> 
und

Code: Alles auswählen

<!-- END news_text --> 

<!-- ##### NEWS END ##### -->
Markus
Webgiant
Mitglied
Beiträge: 32
Registriert: 16.07.2004 04:42

Beitrag von Webgiant »

Hey... Perfekt... Kannst du mir nach sagen wieso das mit den Kommentaren nicht ging.
Weil bei der Tabelle oben drüber gings ja auch mit Comments... :oops: :P :-?


Ein Problemchen habe ich dich noch...
Und zwar habe ich im iframe die Seite ttp://www.whs2004.de/news_index.php verlinkt. Leider wird jetzt auch der normale Board Header und Footer mit angezeigt. Hat jemand ne Idee oder Ahnung wie oder was ich verlinken muss um nur die wirklichen Nachrichten, also quasie die NAchrichtentabelle in das Frame zu bekommen.

http://www.willy-hellpach-schule.de hier knnt ihr euch das Prob mal angucken. Ich nutze den CMX News Mod...


Gruß Helge & Danke... 8)
Wissen ist Macht, wenn man es nutzt.
Benutzeravatar
Markus67
Ehrenadmin
Beiträge: 28346
Registriert: 12.01.2004 16:02
Wohnort: Neuss
Kontaktdaten:

Beitrag von Markus67 »

Hi ...

Das mit den Kommentaren liegt am Aufbau des Intro & Portal MOD ... Wenn der Kommentar nicht in der portal.php definiert ist wird auch nichts angezeigt :wink:

Kannst du bei der Seite news_index.php nicht irgendwo den header bzw. footer rausnehmen der müsste doch irgendwo "included" werden ?

Markus
Webgiant
Mitglied
Beiträge: 32
Registriert: 16.07.2004 04:42

Beitrag von Webgiant »

Hallo,

ich komm einfach net weiter... Hier mal der Quellcoder der PHP udn TPL Datei...

news.tpl:

Code: Alles auswählen

<table class="forumline" width="100%" cellspacing="1" cellpadding="3" border="0">
  <tr>
    <td>

<!-- BEGIN categories -->
    <div style="border: #ddd solid 1px; float: left; padding: 10px; margin: 10px;">
    <a href="{INDEX_FILE}?cat_id={categories.ID}"><img style="border: 0" src="{categories.IMAGE}" alt="{articles.TITLE}" /></a>
    </div>
<!-- END categories -->
<!-- BEGIN arch -->
    <ul style=" padding: 0 1.3em; margin: 10px 0;">
    <!-- BEGIN year -->
      <li class="gen"><a href="{INDEX_FILE}?news=archives&year={arch.year.YEAR}">{arch.year.YEAR}</a></li>
      <!-- BEGIN month -->
      <li class="gen" style="margin-left: 1em;"> <a href="{INDEX_FILE}?news=archives&year={arch.year.YEAR}&month={arch.year.month.MONTH}">{arch.year.month.L_MONTH} {arch.year.month.POST_COUNT} </a></li>
      <!-- BEGIN day -->
      <li class="gen" style="margin-left: 2em;"> <a href="{INDEX_FILE}?news=archives&year={arch.year.YEAR}&month={arch.year.month.MONTH}&day={arch.year.month.day.DAY}">{arch.year.month.day.L_DAY} {arch.year.month.day.POST_COUNT}</a></li>
      <!-- END day -->
      <!-- END month -->
    <!-- END year -->
    </ul>
<!-- END arch -->
<!-- BEGIN articles -->
  <div style="border: #ddd solid 1px; padding: 10px; margin-bottom: 10px; clear: both;">
    <div style="float: right; padding: 5px; margin: 5px;">
    <a href="{INDEX_FILE}?cat_id={articles.CAT_ID}"><img src="{articles.CAT_IMG}" alt="{articles.CATEGORY}" style="border: 0" /></a>
    </div>
    <div class="topictitle"><a href="{INDEX_FILE}?topic_id={articles.ID}">{articles.L_TITLE}</a></div>
    <div class="postdetails">{articles.POST_DATE} by {articles.L_POSTER} | <a href="{articles.U_COMMENTS}">{articles.L_COMMENTS}</a></div>
    <hr />
    <div class="postbody">
    {articles.BODY} {articles.READ_MORE_LINK}
    </div>
    <div style="clear:both; height: 0; margin:0; padding: 0;">&nbsp;</div>
  </div>
<!-- END articles -->
<!-- BEGIN comments -->
  <hr />
  <div style="border: #ddd solid 1px; padding: 10px; margin: 10px 0 10px 20px; clear: both;">
    <div class="topictitle">{comments.L_TITLE}</div>
    <div class="postdetails">{comments.POST_DATE} by {comments.L_POSTER}</div>
    <hr />
    <div class="postbody">
    {comments.BODY}
    </div>
  </div>
<!-- END comments -->

    </td>
  </tr>
</table>

Und die news_index.php

Code: Alles auswählen

<?php

//
// Set up for phpBB intergration.
//
define('IN_PHPBB', true);
$phpbb_root_path = './';

//
// phpBB related files
//

include_once( $phpbb_root_path . 'extension.inc' );
include_once( $phpbb_root_path . 'common.' . $phpEx );
include_once ($phpbb_root_path . 'includes/news.' . $phpEx );

//
// Start session management
//
$userdata = session_pagestart( $user_ip, PAGE_INDEX, $session_length );
init_userprefs( $userdata );

//
// End session management
//



// Tell the template class which template to use.
$template->set_filenames( array( 'news' => 'news_portal.tpl' ) );
    
$content =& new NewsModule( $phpbb_root_path );

$content->setVariables( array(
    'L_INDEX' => $lang['Index'],
    'L_CATEGORIES' => $lang['Categories'],
    'L_ARCHIVES' => $lang['Archives']
    ) );

if( (isset( $_GET['news']  ) && $_GET['news'] == 'categories') )
{
  // View the news categories.
  $content->setVariables( array( 'TITLE' => $lang['News'] . ' ' . $lang['Categories'] ) );
  $content->renderTopics( );
}
elseif( isset( $_GET['news']  ) && $_GET['news'] == 'archives' )
{
  // View the news Archives.
  $year   = (isset( $_GET['year'] )) ? $_GET['year'] : 0;
  $month  = (isset( $_GET['month'] )) ? $_GET['month'] : 0;
  $day    = (isset( $_GET['day'] )) ? $_GET['day'] : 0;
  $key    = (isset( $_GET['key'] )) ? $_GET['key'] : '';

  $content->setVariables( array( 'TITLE' => $lang['News'] . ' ' . $lang['Archives'] ) );
  $content->renderArchives( $year, $month, $day, $key );
}
else
{
  // View news articles.
  $topic_id = 0;
  if( isset( $_GET['topic_id'] ) )
  {
    $topic_id = $_GET['topic_id'];
  }
  elseif( isset( $_GET['news_id'] ) )
  {
    $topic_id = $_GET['news_id'];
  }

  $content->setVariables( array( 'TITLE' => $lang['News'] . ' ' . $lang['Articles'] ) );
  $content->renderArticles( $topic_id );
}

$content->renderPagination( );

$content->display( );
$content->clear( );

include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
?>
Vielleicht kannste mir ja sagen was ich da raus machen muss...
Wissen ist Macht, wenn man es nutzt.
Webgiant
Mitglied
Beiträge: 32
Registriert: 16.07.2004 04:42

Beitrag von Webgiant »

Kann mir da keiner Helfen... :oops: :cry:
Wissen ist Macht, wenn man es nutzt.
Benutzeravatar
FSKiller / Phoenix
Mitglied
Beiträge: 872
Registriert: 28.08.2003 19:57
Wohnort: Berlin

Beitrag von FSKiller / Phoenix »

inculde doch einfach die news_index.php und passe das template an weil der Code für das News template ist ja für news_index.php und du rufst es mit der portal.php auf :)
Kein Support per PN/Mail, wer sucht der findet!
Antworten

Zurück zu „phpBB 2.0: Mod Support“