Author Topic: {url_show_user_images} in detail site  (Read 19973 times)

0 Members and 1 Guest are viewing this topic.

Offline TIMT

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
{url_show_user_images} in detail site
« on: May 09, 2006, 11:02:42 PM »
Hi

I want to implement a link on the detail site, which shows all pictures of the photografer whom picture is actually shown in the detail site.
(uppss... bad English  :oops:)

{url_show_user_images} doesn't work.

TIMT

Offline martrix

  • Hero Member
  • *****
  • Posts: 755
    • View Profile
    • overlord.cz
Re: {url_show_user_images} in detail site
« Reply #1 on: June 14, 2006, 01:29:48 PM »
I don't know if it will work as I can't test it (no acces to the source files),
I don't even know if this would be the right way how to do that,
but try this:

Step 1.1
open includes/functions.php
find
Code: [Select]
    $user_name_link = "<a href=\"".$site_sess->url($user_profile_link)."\">".$user_name."</a>";
insert below:
Code: [Select]
    $user_images_link = "<a href=\"search.php?search_user=".$user_name."\">".$lang['pictures']."</a>";
Step 1.2
find
Code: [Select]
$user_name_link = $user_name;insert below
Code: [Select]
$user_images_link = $user_name;
Step 1.3
find
Code: [Select]
"user_name_link" => $user_name_link,insert below
Code: [Select]
"user_images_link" => $user_images_link,
Step 2

open templates/yourtemplate/details.html and insert {user_images_link} where you want to show the user name linked with the search result for all "image owners" uploaded pictures...

Step 3

open lang/yourlang/main.php
and at the end just before ?> add
Code: [Select]
$lang['pictures'] = "Pictures";
« Last Edit: June 17, 2006, 12:27:17 AM by martrix »
MAяTRIX


Offline TIMT

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
Re: {url_show_user_images} in detail site
« Reply #2 on: June 14, 2006, 10:25:09 PM »
Hi matrix

the link is not displayed on the detail page.

Offline martrix

  • Hero Member
  • *****
  • Posts: 755
    • View Profile
    • overlord.cz
Re: {url_show_user_images} in detail site
« Reply #3 on: June 15, 2006, 11:50:58 AM »
That looks like if I did forget something  :wink:
Well, in that case I have to try it again in the evening, when I'll be able to test it :)

Does anything show up after placing {user_images_link}?
MAяTRIX


Offline TIMT

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
Re: {url_show_user_images} in detail site
« Reply #4 on: June 15, 2006, 08:20:06 PM »
no, nothing is shown.

thanks for your help  :)

Offline martrix

  • Hero Member
  • *****
  • Posts: 755
    • View Profile
    • overlord.cz
Re: {url_show_user_images} in detail site
« Reply #5 on: June 16, 2006, 04:28:45 PM »
Please accept my apologize... for some reason I forgot to write another step.

now the added snippet {user_images_link} shoud show up on the details page with the correct link...
« Last Edit: June 17, 2006, 12:28:01 AM by martrix »
MAяTRIX


Offline TIMT

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
Re: {url_show_user_images} in detail site
« Reply #6 on: June 16, 2006, 11:07:46 PM »
Great! It works.  :D

What do I have to do when I'd like to show the word "Pictures" instead of the username.
I mean the link should be named "Pictures" instead of the username.
The link "username" direct to the profile.

Offline martrix

  • Hero Member
  • *****
  • Posts: 755
    • View Profile
    • overlord.cz
Re: {url_show_user_images} in detail site
« Reply #7 on: June 17, 2006, 12:20:04 AM »
That's an easy task. I just refreshed the original posting.

Re-do Step 1.1 and then do step 3
MAяTRIX


Offline TIMT

  • Hero Member
  • *****
  • Posts: 505
    • View Profile
Re: {url_show_user_images} in detail site
« Reply #8 on: June 17, 2006, 09:37:36 AM »
Hi matrix

Thanks! That's exactly I was looking for.

TIMT

Offline martrix

  • Hero Member
  • *****
  • Posts: 755
    • View Profile
    • overlord.cz
Re: {url_show_user_images} in detail site
« Reply #9 on: June 17, 2006, 10:02:48 AM »
You are very welcome  8)
MAяTRIX


Offline nfprehn

  • Newbie
  • *
  • Posts: 41
    • View Profile
    • How to become a model
Re: {url_show_user_images} in detail site
« Reply #10 on: July 27, 2006, 07:42:28 PM »
I have come across a bug:

When I as the administrator edit an existing image of another user (e.g. change description...), the user_images_link then points to no or another user account.  :evil:

Does anyone know why this is happening?  8O

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: {url_show_user_images} in detail site
« Reply #11 on: July 28, 2006, 12:38:09 AM »
and who is the owner of the image (after the editing)?
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)


Offline nfprehn

  • Newbie
  • *
  • Posts: 41
    • View Profile
    • How to become a model
Re: {url_show_user_images} in detail site
« Reply #13 on: July 29, 2006, 01:34:29 PM »
I am trying to take this one further and add the image owner's details (as shown on his profile page) to the details.html .

I cannot get it to show though...  :cry:

Offline V@no

  • If you don't tell me what to do, I won't tell you where you should go :)
  • Global Moderator
  • 4images Guru
  • *****
  • Posts: 17.849
  • mmm PHP...
    • View Profile
    • 4images MODs Demo
Re: {url_show_user_images} in detail site
« Reply #14 on: July 29, 2006, 05:11:48 PM »
Hmm...the username showed is actualy name of the picture and not the owner's name...unless you did some other changes in the code what martrix posted, then I dont see how is this possible at all...
check the changes again.
Your first three "must do" before you ask a question:
Please do not PM me asking for help unless you've been specifically asked to do so. Such PMs will be deleted without answer. (forum rule #6)
Extension for Firefox/Thunderbird: Master Password+    Back/Forward History Tweaks (restartless)    Cookies Manager+    Fit Images (restartless for Thunderbird)