Simple Machines Community Forum

Customizing SMF => SMF Coding Discussion => Aiheen aloitti: Xpresskonami - marraskuu 12, 2013, 10:30:31 IP

Otsikko: Help me correct this code @all wapmasters and ADMINS
Kirjoitti: Xpresskonami - marraskuu 12, 2013, 10:30:31 IP
I want to make include to the script, you we see somting like include('mypost.php');

echo'
<p align="right">', $message['time'], '</p><table><tbody><tr><td class="post"> include('myposts.php'); </td><td class="other">
', $context['can_send_pm'] ? '<a href="' . @$message['member']['online']['href'] . '" title="' . @$message['member']['online']['label'] . '">' : '', $settings['use_image_buttons'] ? '<img src="' . @$message['member']['online']['image_href'] . '" alt="" />' : @$message['member']['online']['text'], $context['can_send_pm'] ? '</a>' : '', $settings['use_image_buttons'] ? '<span class="smalltext"></span>' : '', '';


Otsikko: Re: Help me correct this code @all wapmasters and ADMINS
Kirjoitti: TheListener - marraskuu 12, 2013, 10:48:10 IP
Letting us know what the code is helps. Ie is it mod related?

Your subject title isn't very informative either.
Otsikko: Re: Help me correct this code @all wapmasters and ADMINS
Kirjoitti: Xpresskonami - marraskuu 13, 2013, 12:11:48 AP
It is image/avatar script not mods,

I have modify it,
this is the script i want to add to it,
if (!empty($settings['show_user_images']) && empty($options['show_no_avatars']) && !empty($message['member']['avatar']['image']))
echo '
<a href="', $scripturl, '?action=profile;u=', $message['member']['id'], '">
', $message['member']['avatar']['image'], '
</a>';


echo'
<p align="right">', $message['time'], '</p><table><tbody><tr><td class="post">
if (!empty($settings['show_user_images']) && empty($options['show_no_avatars']) && !empty($message['member']['avatar']['image']))
echo '
<a href="', $scripturl, '?action=profile;u=', $message['member']['id'], '">
', $message['member']['avatar']['image'], '
</a>';
</td><td class="other">
', $context['can_send_pm'] ? '<a href="' . @$message['member']['online']['href'] . '" title="' . @$message['member']['online']['label'] . '">' : '', $settings['use_image_buttons'] ? '<img src="' . @$message['member']['online']['image_href'] . '" alt="" />' : @$message['member']['online']['text'], $context['can_send_pm'] ? '</a>' : '', $settings['use_image_buttons'] ? '<span class="smalltext"></span>' : '', '';


Otsikko: Re: Help me correct this code @all wapmasters and ADMINS
Kirjoitti: Colin - marraskuu 13, 2013, 03:24:51 AP
I am still confused. What exactly are you trying to do?