News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Please help post index page error

Started by ittiphol, April 06, 2017, 09:20:40 AM

Previous topic - Next topic

ittiphol

Please help post index page error

preview post by SSI.php

At first, there is now no message, try to install a new host does not resolve.


sorry my english

by SSI.php


foreach ($return['topics'] as $news)

{

global $memberContext;

                loadMemberData($news['poster']['id']);

loadMemberContext($news['poster']['id']);







$default_avatar = '' . $settings['images_url'] . '/noavatar.png'; // enter URL of default avatar you want. Like this



if ($parameters['avatar'] != 'none' && isset($news['poster']['avatar']))

$news['body'] = '<img class="ssi_avatar" src="' . $news['poster']['avatar']['href'] . '" style="margin:0 1em 1em 1em; float: ' . $parameters['avatar'] . '" />' . $news['body'];



echo '

<style type="text/css">

.tooltip2{
    display: inline;
    position: relative;
font-family: sans-serif;
font-size: 1.1em;
}

.tooltip2:hover:after{
    background: #333;
    background: rgba(0,0,0,.8);
    border-radius: 5px;
    bottom: 20px;
    color: #fff;
    content: attr(titlex);
    left: 0%;
    padding: 5px 15px;
    position: absolute;
    z-index: 98;
    width: 90px;
font-family: sans-serif;
font-size: 1em;
}

.tooltip2:hover:before{
    border: solid;
    border-color: #333 transparent;
    border-width: 6px 6px 0 6px;
    bottom: 15px;
    content: "";
    left: 70%;
    position: absolute;
    z-index: 99;
font-family: sans-serif;
font-size: 1em;
}

</style>


<style type="text/css">

.tooltip1{
    display: inline;
    position: relative;
font-family: sans-serif;
font-size: 1.1em;
}

.tooltip1:hover:after{
    background: #333;
    background: rgba(0,0,0,.8);
    border-radius: 5px;
    bottom: 26px;
    color: #fff;
    content: attr(titlex);
    left: 0%;
    padding: 5px 15px;
    position: absolute;
    z-index: 98;
    width: 110px;
font-family: sans-serif;
font-size: 1em;
}

.tooltip1:hover:before{
    border: solid;
    border-color: #333 transparent;
    border-width: 6px 6px 0 6px;
    bottom: 20px;
    content: "";
    left: 70%;
    position: absolute;
    z-index: 99;
font-family: sans-serif;
font-size: 1em;
}

</style>


<table border="0" width="505" align="center" height="238" class="picpGal01" style="margin-left:1.7em;">

    <tr>

        <td width="55" align="center" rowspan="2" height="60" valign="top" oncontextmenu="return false;"/>



';





if (!empty($memberContext[$news['poster']['id']]['avatar']['image'])){

echo '
', $memberContext[$news['poster']['id']]['avatar']['image'],'';

                    }           

            else {

echo '
<img src="' . $default_avatar .'" alt="default_avatar" width="55" height="55" oncontextmenu="return false;"/>';

                }



        echo'
<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/th_TH/sdk.js#xfbml=1&version=v2.5";
  fjs.parentNode.insertBefore(js, fjs);
}(document, \'script\', \'facebook-jssdk\'));</script>

<br>

</td>

        <td width="413" align="left" valign="top">

';

global $db_prefix;
global $context, $settings, $options, $txt, $scripturl, $modSettings;
if (!empty($modSettings['onlineEnable']) && !$message['member']['is_guest'])
echo '
<img src="' . $memberContext[$news['poster']['id']]['online']['image_href']. '" alt="', $memberContext[$news['poster']['id']]['online']['text'], '" oncontextmenu="return false" ondragstart="return false" onselectstart="return false" />

            <b><font size="4">', $news['poster']['link'], '</font></b>&nbsp;&nbsp;<font color="999999"> ', $news['time'], '</font> <img src="images/w.png" border="0" oncontextmenu="return false;"/>
         
 
  </td>



    </tr>

    <tr>

        <td width="413" height="43" align="left" valign="top">

           <b><font size="2">Post in</b></font>&nbsp; <font size="2"  titlex="&nbsp;&nbsp;&nbsp;&nbsp;' . $txt['popup4'] . '" class="tooltip2">[' . $news['board']['link'] . ']</font><br><a href="', $news['href'], '"><font size="2">', $news['subject'], '</a></font><br><hr>

        </td>

    </tr>

    <tr>

        <td width="499" align="left" colspan="2" height="135" valign="top" oncontextmenu="return false" ondragstart="return false" onselectstart="return false">


<a href="', $news['href'], '">', $news['body'], '</a><br>



</td>

    </tr>

    <tr>

        <td width="499" align="left" colspan="2">
<br>
<font color="#999999" size="2">', $txt['viewin'], ' ' . $news['num_views'], ' ', $txt['viewin2'], '</font>
<hr>

     <img src="images/reply0.png" border="0" oncontextmenu="return false;"/>&nbsp;

<font color="#627aad"  titlex="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;' . $txt['popup1'] . '" class="tooltip1">', $news['link'], $news['locked'] ? '' : ' </font>

&nbsp;&nbsp;&nbsp;&nbsp; <img src="images/share0.png" border="0" oncontextmenu="return false;"/>&nbsp;
<font color="#627aad"  titlex="&nbsp;&nbsp;&nbsp;' . $txt['popup3'] . '" class="tooltip1"><div class="fb-share-button" data-href="', $news['href'], '" data-layout="link"></div></font>
        </td>

    </tr>

</table>



<table border="0" width="505" align="center" height="20" class="picpGal02" style="margin-left:1.7em;">

    <tr>

        <td width="55" align="left" rowspan="2" height="50" valign="top">









<table border="0" width="100%" align="center" height="20">

    <tr>

        <td width="20" align="left" rowspan="2" height="20" valign="top">



';



if (!empty($context['user']['avatar'])){

echo '



<a href="' . $scripturl . '?action=profile;area=forumprofile' . $memID . ';sa=forumProfile" alt="' . $txt['forumProfile'] . '">



<img src="', $context['user']['avatar']['href'],'" style="width: 35px; height: 35px;" alt=""  oncontextmenu="return false;"/>

</a>';}



else{

                echo ' <a href="' . $scripturl . '?action=profile;area=forumprofile' . $memID . ';sa=forumProfile" alt="' . $txt['forumProfile'] . '">

<img src="', $settings['images_url'], '/noavatar.png" alt="' . $txt['forumProfile'] . '"  width="30" height="30" oncontextmenu="return false;"/></a>



';

}



echo '



        </td>

        <td width="350" align="left" rowspan="2" height="20">



<table width="100%" align="center" height="33" style="border-width:1px;border-color:#CCCCCC;border-style:solid; background-color:#ffffff" border=0>

    <tr>

        <td width="100%" align="left" rowspan="2" height="20">


&nbsp;&nbsp;
<font color="#999999"  titlex="&nbsp;&nbsp;' . $txt['popup2'] . '" class="tooltip1">' . $news['comment_link'], '</font>

</td>

    </tr>

    <tr>
        <td width="1" align="right" rowspan="2" height="20">


<iframe src="http://www.facebook.com/plugins/like.php?href=', $news['href'], '&amp;layout=button_count&amp;show_faces=false&amp;width=80&amp;action=like&amp;colorscheme=light" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:100px; height:21px"></iframe>



</td>
    </tr>

</table>

        </td>

    </tr>

</table>





        </td>

    </tr>

</table>

















';




[edit] code tags - Illori

ittiphol


Advertisement: