| Author |
Message |
Geahn

Joined: 13 Mar 2007 Posts: 13
|
|
How concatenate {avatar) + any code? |
|
I need to use the command {avatar} inside a code, but don't works, look my code and running:
Original Code:
 |  | <img scr="code.php?{avatar},morecode" /> |
Running in my page:
 |  | ,morecode (this is a text ok?) |
How i can to concatenate the {avatar} whit more codes?
|
|
| Wed Jul 02, 2008 5:59 am |
|
 |
Guest
|
|
|
Please login to hide the ads.
|
|
|
|
 |
SolidSnake2003

Joined: 31 Jul 2007 Posts: 54
|
|
|
|
all you need to display the avatar is {avatar}
|
|
| Wed Jul 02, 2008 8:19 am |
|
 |
Geahn

Joined: 13 Mar 2007 Posts: 13
|
|
|
|
I know, but I need concatenate the code whit {avatar}, my question isn't how to display an avatar.
|
|
| Wed Jul 02, 2008 8:41 am |
|
 |
SolidSnake2003

Joined: 31 Jul 2007 Posts: 54
|
|
|
|
I guess I just don't understand what you mean by concatenate
|
|
| Wed Jul 02, 2008 11:51 pm |
|
 |
Syrion

Joined: 02 Aug 2006 Posts: 172
|
|
|
|
He wants to include the output of {avatar} in a longer string of code.
_________________
Mini-me |
|
| Thu Jul 03, 2008 10:33 pm |
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
Can't you edit it directly in inc/show.news.php?
 |  | $output = str_replace('{avatar}', ($row['avatar'] ? '<img src="'.$row['avatar'].'" alt="" border="0" align="absmiddle">' : ''), $output); |
Or use {avatar-url} which shows just the url instead of {avatar} which shows the whole image code.
|
|
| Fri Jul 04, 2008 2:01 pm |
|
 |
nam

Joined: 23 Dec 2006 Posts: 67
|
|
|
|
This works for me but face problem with certain titles.
When titles has a doublequote string, the page will not be dispalyed correctly and the XHTML validator will also show error message.
For example with the following title: UN says: "poverty is global"
The HTML code will be:
<img src="http://www.yoursite.com/data/upimages/un.jpg" alt="UN says: "poverty is global"" border="0" align="absmiddle">
Which causes the problem.
Any solution?
|
|
| Mon Jul 07, 2008 4:12 pm |
|
 |
scottdallas

Joined: 04 May 2006 Posts: 1802 Location: US |
|
|
|
 |  | Or use {avatar-url} |
Since when? Do I need to modify code to use that or was that always there?
_________________ www.scottdizzle.com uses cnr
last update: 07-22-08: 8:30 pm |
|
| Tue Jul 08, 2008 6:56 pm |
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
 |  | When titles has a doublequote string, the page will not be dispalyed correctly and the XHTML validator will also show error message. |
I don't understand why your title is in the alt tag of the image? Please explain.
|
|
| Thu Jul 10, 2008 6:45 pm |
|
 |
FI-DD
Admin

Joined: 22 Sep 2005 Posts: 2668 Location: Germany |
|
|
|
 |  |  |  | Or use {avatar-url} |
Since when? Do I need to modify code to use that or was that always there? |
It was always there. 
|
|
| Thu Jul 10, 2008 6:47 pm |
|
 |
|