Icy Phoenix

     
 


This forum is locked: you cannot post, reply or edit topics.  This topic is locked: you cannot edit posts or make replies. 
Page 1 of 2
Goto page 1, 2  Next
 
Reply with quote Download Post 
Post FAP CUSTOMIZATION - Insert Link "all Images Of .." In Message Profiles 
 
Hi,
I have another request for you...
My users asked me a new option in the message profiles: a link to "all images of", the same link is available in membersist profile....I try to explain you with images below:
 icy_req

Thanks in advantage
 



 
felix968Send private message  
Back to topPage bottom
Icy Phoenix is an open source project, you can show your appreciation and support future development by donating to the project.

Support us
 
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
Hi,
I have a similar function already on my board.

There is already one that links to the personal gallery.
http://www.icyphoenix.com/viewtopic.php?p=6561#p6561

I will post the code when i have some time to put it in format..
 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
ok lefty, thank you..
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
sorry took a while, this should work, based on galaxy21's mod

Code: [Download] [Hide] [Select]
#
#-----[ OPEN ]------------------------------------------------
#
viewtopic.php
#
#-----[ FIND ]------------------------------------------------
#
        $profile = '<a href="' . $temp_url . '">' . $lang['Read_profile'] . '</a>';
#
#-----[ AFTER, ADD ]------------------------------------------
#
$sql = "SELECT COUNT(pic_user_id) AS total_pics
        FROM " . ALBUM_TABLE . "
        WHERE pic_user_id = " . $poster_id . "
        AND pic_approval = 1";

if( !($result = $db->sql_query($sql)) )
{
    message_die(GENERAL_ERROR, 'Could not query total pics information', '', __LINE__, __FILE__, $sql);
}

$overalltotalpicrow = ($row = $db->sql_fetchrow($result) ) ? intval($row['total_pics']) : 0;

        if (  $overalltotalpicrow != 0 )
        {
            $temp_url = append_sid("album.$phpEx?user_id=" . $poster_id . "&mode=" . ALBUM_VIEW_LIST);
            $album_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_album'] . '" alt="' . $lang['Show_Pictures_by_user'] . '" title="' . $lang['Show_Pictures_by_user'] . '" border="0" /></a>';
            $album = '<a href="' . $temp_url . '">' . $lang['Show_Pictures_by_user'] . '</a>';

        }
        else
        {
            $album_img = '';
            $album = '';
        }
#
#-----[ FIND ]------------------------------------------------
#
#
        'PROFILE' => $profile,
#
#-----[ AFTER, ADD ]-----------------------------------------
#
        'ALBUM_IMG' => $album_img,
        'ALBUM' => $album,
#
#-----[ OPEN ]------------------------------------------------
#
language/lang_english/lang_main.php
#
#-----[ FIND ]------------------------------------------------
#
#
// That's all Folks!
#
#-----[ AFTER, ADD ]----------------------------------
#

$lang['Show_Pictures_by_user'] = 'Show pictures by user';
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/viewtopic_body.tpl
#
#-----[ FIND ]------------------------------------------------
#
#
                <td valign="middle" nowrap="nowrap">{postrow.PROFILE_IMG} {postrow.PM_IMG} {postrow.EMAIL_IMG} {postrow.WWW_IMG} {postrow.AIM_IMG} {postrow.YIM_IMG} {postrow.MSN_IMG}<script language="JavaScript" type="text/javascript"><!--
#
#-----[ IN-LINE FIND ]----------------------------------------
#
{postrow.PROFILE_IMG}
#
#-----[ IN-LINE AFTER, ADD ]----------------------------------
#
 {postrow.ALBUM_IMG}
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------------

 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
lefty74 wrote: [View Post]
sorry took a while, this should work, based on galaxy21's mod



On my board (phpbb 2.0.21) with FAP 1.4.1 doesn't work ...
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
felix968 wrote: [View Post]
lefty74 wrote: [View Post]
sorry took a while, this should work, based on galaxy21's mod



On my board (phpbb 2.0.21) with FAP 1.4.1 doesn't work ...


On my test board (phpbb 2.0.22) with FAP 1.4.1. it did.
Sorry, description of what doesnt work is a bit vague...
 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
lefty74 wrote: [View Post]

On my test board (phpbb 2.0.22) with FAP 1.4.1. it did.
Sorry, description of what doesnt work is a bit vague...


Lefty, with your mod when I go in a topic (viewtopic.php), the page is http://www.mysite/forum/viewtopic.php?p=1537#1537,
but there is only the banner and menu (from the portal), and below link to administration. Not other.
I have to say my board is integrated in mkportal 1.1.1
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
hmm, strange, its not much code to put in. i dont know anything about the mkportal but would have thought that viewtopic is rather similar...

if u link ur viewtopic.php to here i can have a look
 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
lefty74 wrote: [View Post]
hmm, strange, its not much code to put in. i dont know anything about the mkportal but would have thought that viewtopic is rather similar...

if u link ur viewtopic.php to here i can have a look


Yes, of course...
My site is www.oltrelafoto.com
this is the viewtopic.php page with the mod:

 error_fapmod

and here are my modified files.
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
felix, the viewtopic.php works fine on my board (non-portal) after taking some lines out...

its the viewtopic_body.tpl file that is causing this, can u put one in the link before you did the editing, i.e. one that definitely worked on your board.

thanks
 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
lefty74 wrote: [View Post]
felix, the viewtopic.php works fine on my board (non-portal) after taking some lines out...

its the viewtopic_body.tpl file that is causing this, can u put one in the link before you did the editing, i.e. one that definitely worked on your board.

thanks


Thank a lot Lefty, you're right: is the viewtopic_body.tpl that causing that....I've not problem remiving it from your MOD.
The code before editing is:

Code: [Download] [Hide] [Select]

<table width="100%" cellspacing="2" cellpadding="2" border="0">

  <tr>

    <td align="left" valign="bottom" colspan="2"><a class="maintitle" href="{U_VIEW_TOPIC}">{TOPIC_TITLE}</a><br />

      <span class="gensmall"><b>{PAGINATION}</b><br />

      &nbsp; </span></td>

  </tr>

</table>



<table width="100%" cellspacing="2" cellpadding="2" border="0">

  <tr>

    <td align="left" valign="bottom" nowrap="nowrap"><span class="nav"><a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" alt="{L_POST_NEW_TOPIC}" align="middle" style="filter:alpha(opacity=65)" onMouseOver="this.filters.alpha.opacity=100" onMouseOut="this.filters.alpha.opacity=65" /></a>&nbsp;&nbsp;&nbsp;<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" alt="{L_POST_REPLY_TOPIC}" align="middle" style="filter:alpha(opacity=65)" onMouseOver="this.filters.alpha.opacity=100" onMouseOut="this.filters.alpha.opacity=65" /></a></span></td>

    <td align="left" valign="middle" width="100%"><span class="nav">&nbsp;&nbsp;&nbsp;<a href="{U_INDEX}" class="nav">{L_INDEX}</a>

      -> <a href="{U_VIEW_FORUM}" class="nav">{FORUM_NAME}</a></span></td>

  </tr>

</table>



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

    <tr align="right">

        <td class="catHead" colspan="2" height="28"><span class="nav"><a href="{U_VIEW_OLDER_TOPIC}" class="nav">{L_VIEW_PREVIOUS_TOPIC}</a> :: <a href="{U_VIEW_NEWER_TOPIC}" class="nav">{L_VIEW_NEXT_TOPIC}</a> &nbsp;</span></td>

    </tr>

    {POLL_DISPLAY}

    <tr>

        <th class="thLeft" width="150" height="26" nowrap="nowrap">{L_AUTHOR}</th>

        <th class="thRight" nowrap="nowrap">{L_MESSAGE}</th>

    </tr>

    <!-- BEGIN postrow -->

    <tr>

        <td width="150" align="left" valign="top" class="{postrow.ROW_CLASS}"><span class="name"><a name="{postrow.U_POST_ID}"></a><b>{postrow.POSTER_NAME}</b></span><br /><span class="postdetails">{postrow.POSTER_RANK}<br />{postrow.RANK_IMAGE}{postrow.POSTER_AVATAR}<br /><br />{postrow.POSTER_ONLINE}<br />{postrow.POSTER_JOINED}<br />{postrow.POSTER_POSTS}<br />{postrow.POSTER_FROM}</span><br /></td>

        <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">

            <tr>

                <td width="100%"><a href="{postrow.U_MINI_POST}"><img src="{postrow.MINI_POST_IMG}" width="12" height="9" alt="{postrow.L_MINI_POST_ALT}" title="{postrow.L_MINI_POST_ALT}" border="0" /></a><span class="postdetails">{L_POSTED}: {postrow.POST_DATE}<span class="gen">&nbsp;</span>&nbsp; &nbsp;{L_POST_SUBJECT}: {postrow.POST_SUBJECT}</span></td>

                <td valign="top" nowrap="nowrap">{postrow.QUOTE_IMG} {postrow.EDIT_IMG} {postrow.DELETE_IMG} {postrow.IP_IMG}</td>

            </tr>

            <tr>

                <td colspan="2"><hr /></td>

            </tr>

            <tr>

                <td colspan="2"><span class="postbody">{postrow.MESSAGE}</span>{postrow.ATTACHMENTS}<span class="postbody">{postrow.SIGNATURE}</span><span class="gensmall">{postrow.EDITED_MESSAGE}</span></td>

            </tr>

        </table></td>

    </tr>

    <tr>

        <td class="{postrow.ROW_CLASS}" width="150" align="left" valign="middle"><span class="nav"><a href="#top" class="nav">{L_BACK_TO_TOP}</a></span></td>

        <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="bottom" nowrap="nowrap"><table cellspacing="0" cellpadding="0" border="0" height="18" width="18">

            <tr>

                <td valign="middle" nowrap="nowrap">{postrow.PROFILE_IMG} {postrow.PM_IMG} {postrow.EMAIL_IMG} {postrow.WWW_IMG} {postrow.AIM_IMG} {postrow.YIM_IMG} {postrow.MSN_IMG}<script language="JavaScript" type="text/javascript"><!--



    if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 )

        document.write(' {postrow.ICQ_IMG}');

    else

        document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute">{postrow.ICQ_IMG}</div><div style="position:absolute;left:3px;top:-1px">{postrow.ICQ_STATUS_IMG}</div></div>');

                

                //--></script><noscript>{postrow.ICQ_IMG}</noscript></td>

            </tr>

        </table></td>

    </tr>

    <tr>

        <td class="spaceRow" colspan="2" height="1"><img src="../../originali/templates/subSilver/templates/subSilver/images/spacer.gif" alt="" width="1" height="1" /></td>

    </tr>

    <!-- END postrow -->

    <tr align="center">

        <td class="catBottom" colspan="2" height="28"><table cellspacing="0" cellpadding="0" border="0">

            <tr><form method="post" action="{S_POST_DAYS_ACTION}">

                <td align="center"><span class="gensmall">{L_DISPLAY_POSTS}: {S_SELECT_POST_DAYS}&nbsp;{S_SELECT_POST_ORDER}&nbsp;<input type="submit" value="{L_GO}" class="liteoption" name="submit" /></span></td>

            </form></tr>

        </table></td>

    </tr>

</table>



<table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">

  <tr>

    <td align="left" valign="middle" nowrap="nowrap"><span class="nav"><a href="{U_POST_NEW_TOPIC}"><img src="{POST_IMG}" border="0" alt="{L_POST_NEW_TOPIC}" align="middle" style="filter:alpha(opacity=65)" onMouseOver="this.filters.alpha.opacity=100" onMouseOut="this.filters.alpha.opacity=65" /></a>&nbsp;&nbsp;&nbsp;<a href="{U_POST_REPLY_TOPIC}"><img src="{REPLY_IMG}" border="0" alt="{L_POST_REPLY_TOPIC}" align="middle" style="filter:alpha(opacity=65)" onMouseOver="this.filters.alpha.opacity=100" onMouseOut="this.filters.alpha.opacity=65" /></a></span></td>

    <td align="left" valign="middle" width="100%"><span class="nav">&nbsp;&nbsp;&nbsp;<a href="{U_INDEX}" class="nav">{L_INDEX}</a>

      -> <a href="{U_VIEW_FORUM}" class="nav">{FORUM_NAME}</a></span></td>

    <td align="right" valign="top" nowrap="nowrap"><span class="gensmall">{S_TIMEZONE}</span><br /><span class="nav">{PAGINATION}</span>

      </td>

  </tr>

  <tr>

    <td align="left" colspan="3"><span class="nav">{PAGE_NUMBER}</span></td>

  </tr>

</table>



<table width="100%" cellspacing="2" border="0" align="center">

  <tr>

    <td width="40%" valign="top" nowrap="nowrap" align="left"><span class="gensmall">{S_WATCH_TOPIC}</span><br />

      &nbsp;<br />

      {S_TOPIC_ADMIN}</td>

    <td align="right" valign="top" nowrap="nowrap">{JUMPBOX}<span class="gensmall">{S_AUTH_LIST}</span></td>

  </tr>

</table>

 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
this is some weird file you have. when i paste it into my existing viewtopic_body and save it, it doesnt work, when I extract it and then move to the template folder it seems to work.

Anyway, the attached file just worked on my pc.

viewtopic_body.zip
Description: very weird 
Download
Filename: viewtopic_body.zip
Filesize: 1.72 KB
Downloaded: 282 Time(s)

 



 
lefty74Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
lefty74 wrote: [View Post]
this is some weird file you have. when i paste it into my existing viewtopic_body and save it, it doesnt work, when I extract it and then move to the template folder it seems to work.

Anyway, the attached file just worked on my pc.


Yes! Now it work fine!
Thank Lefty, very much...
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
...i'd like it in album_showpage reply, too         
 



 
felix968Send private message  
Back to topPage bottom
Reply with quote Download Post 
Post Re: Insert Link "all Images Of .." In Message Prof 
 
Code: [Download] [Hide] [Select]
#-----[ OPEN ]------------------------------------------------
#
#
album_showpage.php
#
#-----[ FIND ]------------------------------------------------
#
$template->assign_block_vars('commentrow', array(
#
#-----[ BEFORE, ADD ]------------------------------------------
#
$sql = "SELECT COUNT(pic_user_id) AS total_pics
        FROM " . ALBUM_TABLE . "
        WHERE pic_user_id = " . $commentrow[$i]['user_id'] . "
        AND pic_approval = 1";

if( !($result = $db->sql_query($sql)) )
{
    message_die(GENERAL_ERROR, 'Could not query total pics information', '', __LINE__, __FILE__, $sql);
}

$overalltotalpicrow = ($row = $db->sql_fetchrow($result) ) ? intval($row['total_pics']) : 0;

        if (  $overalltotalpicrow != 0 )
        {
            $temp_url = append_sid("album.$phpEx?user_id=" . $commentrow[$i]['user_id'] . "&mode=" . ALBUM_VIEW_LIST);
            $album_img = '<a href="' . $temp_url . '"><img src="' . $images['icon_album'] . '" alt="' . $lang['Show_Pictures_by_user'] . '" title="' . $lang['Show_Pictures_by_user'] . '" border="0" /></a>';
            $album = '<a href="' . $temp_url . '">' . $lang['Show_Pictures_by_user'] . '</a>';

        }
        else
        {
            $album_img = '';
            $album = '';
        }
#
#-----[ FIND ]------------------------------------------------
#
#
                    'PROFILE_IMG' => ( $commentrow[$i]['user_id'] != ANONYMOUS ) ? '<a href="' . $profile_url . '"><img src="' . $images['icon_profile'] . '" alt="' . $lang['Read_profile'] . '" title="' . $lang['Read_profile'] . '" border="0" /></a>' : '',
#
#-----[ AFTER, ADD ]-----------------------------------------
#
        'ALBUM_IMG' => $album_img,
        'ALBUM' => $album,
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/album_showpage_body.tpl
#
#-----[ FIND ]------------------------------------------------
#
#
                        {commentrow.PROFILE_IMG}&nbsp;
#
#-----[ AFTER, ADD ]----------------------------------
#
                        {commentrow.ALBUM_IMG}&nbsp;
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------------


the language variables should work from the previous edit, if not, add them to lang_album_main.php
 



 
lefty74Send private message  
Back to topPage bottom
This forum is locked: you cannot post, reply or edit topics.  This topic is locked: you cannot edit posts or make replies.  Page 1 of 2
Goto page 1, 2  Next


Display posts from previous:    

HideWas this topic useful?

Link this topic
URL
BBCode
HTML




 
Permissions List
You cannot post new topics
You cannot reply to topics
You cannot edit your posts
You cannot delete your posts
You cannot vote in polls
You cannot attach files
You can download files
You cannot post calendar events