Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2005-12-01 18:30:32

Niconemo
Member
From: Rhône-Alpes, France
Registered: 2005-04-18
Posts: 557

Re: Can custom tags be used with multiple images?

It is a very basic thing and it should work… there must be a very little bug somewhere in your operations ;-)

Ok I tried it without the custom tag and it displays.

So it is not a path problem. OK

Then :

Are you sure the field is exactly “rating” (in your advanced preferences)

Are you sure there is a number between 1 and 5 entered in the field of the article you’re viewing ?

Are you sure there is a #rating{} selector in your CSS ?

What XHTML code is output exactly on this line ? (it isn’t possible to have a direct link I guess…)

Last edited by Niconemo (2005-12-01 18:44:53)


Nico

Offline

#14 2005-12-01 18:36:10

Niconemo
Member
From: Rhône-Alpes, France
Registered: 2005-04-18
Posts: 557

Re: Can custom tags be used with multiple images?

> sekhu wrote:
> something like:
> <code><div id=“rating”><strong>Rating:</strong><img src=”../images/<txp:custom_field name=“rating” />1.png” /></div></code>

Err… There is a problem there <txp:custom_field name="rating" />1.png in your code ! The “1” should not be there ! It will display 11.png, 21.png, etc. instead of 1.png, 2.png…

txp:custom_field will display exactly what is in you custom field : no more no less. It won’t do any operations. So <txp:custom_field name="rating" />.png will output “hello.png”, “10.png”, “How do you do ?.png” if there is “hello”, “10” or “How do you do ?” in the custom field.

Last edited by Niconemo (2005-12-01 18:43:52)


Nico

Offline

#15 2005-12-01 19:19:23

sekhu
Member
Registered: 2005-05-12
Posts: 428
Website

Re: Can custom tags be used with multiple images?

> Niconemo wrote:

> > sekhu wrote:
> something like:
> <code><div id=“rating”><strong>Rating:</strong><img src=”../images/<txp:custom_field name=“rating” />1.png” /></div></code>

Err… There is a problem there <txp:custom_field name="rating" />1.png in your code ! The “1” should not be there ! It will display 11.png, 21.png, etc. instead of 1.png, 2.png…

txp:custom_field will display exactly what is in you custom field : no more no less. It won’t do any operations. So <txp:custom_field name="rating" />.png will output “hello.png”, “10.png”, “How do you do ?.png” if there is “hello”, “10” or “How do you do ?” in the custom field.

No, I put that example in with regards to alex’s suggestion of troubleshooting. I have used the code without the 1 which displays a 1 rating in every entry, so again it’s not a path problem but something in the code which has either gone wrong, or perhaps it’s abug?

Basically it outputs nothing, the path it displays is as above but without selecting either the chosen number in the custom tag field (any number 1-5 for example), or anything else. FF displays it as a broken image, with no value preceeding the .png

EDIT: Ok it works it was a case issue, I had used Rating not rating and now it displays.

This is very excellent, now does anyone have plans to write this up? I noted a few people requesting a rating plugin and well this is the next best thing for me. Cheers everyone

Last edited by sekhu (2005-12-01 19:25:00)

Offline

#16 2005-12-02 17:56:48

Niconemo
Member
From: Rhône-Alpes, France
Registered: 2005-04-18
Posts: 557

Re: Can custom tags be used with multiple images?

What is the most requested is a frontside rating (rating by visitors I mean)


Nico

Offline

#17 2005-12-21 11:36:04

gejl
New Member
From: Denmark
Registered: 2005-03-14
Posts: 7
Website

Re: Can custom tags be used with multiple images?

I have the same problem. Cheched for case issue, but my custom field basically displays nothing. There is no output to my image-string? Any suggestions?

Offline

#18 2005-12-22 06:42:36

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: Can custom tags be used with multiple images?

What is the output of the tag (“view source”)?

Offline

Board footer

Powered by FluxBB