For those who like a functional rating bar

Hert
Posts: 21020
Joined: 13 Sep 03 7:24

For those who like a functional rating bar

Post by Hert » 19 Feb 18 12:33

Use the script below as a custom thumb line (click the View button in upper right corner) to get a fully functional rating bar;

http://repository.idimager.com/openreso ... D198B0A7B8

Here's a screenshot
ratings.png
ratings.png (310.85 KiB) Viewed 762 times
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

weidmic
moderator
Posts: 4454
Joined: 04 Dec 06 22:21

Re: For those who like a functional rating bar

Post by weidmic » 19 Feb 18 14:43

COOOL!
PSUServer 4.x, PostgreSQL 10.x
My homepage http://www.michaelweidner.com
PSU Tips and Tricks http://www.michaelweidner.com/WP/psu/

weidmic
moderator
Posts: 4454
Joined: 04 Dec 06 22:21

Re: For those who like a functional rating bar

Post by weidmic » 19 Feb 18 15:16

Hert,
it works. But there seems to be a little bug.
When using the rating bar, images stay in sync...

Cheers,
Michael

P.S.: I have set PSU to not write automatically catalog changes to the image file.
PSUServer 4.x, PostgreSQL 10.x
My homepage http://www.michaelweidner.com
PSU Tips and Tricks http://www.michaelweidner.com/WP/psu/

Hert
Posts: 21020
Joined: 13 Sep 03 7:24

Re: For those who like a functional rating bar

Post by Hert » 19 Feb 18 16:14

Great, I've updated the script in the opening post. tnx
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

sanphotgn
Posts: 428
Joined: 26 Aug 07 18:06

Re: For those who like a functional rating bar

Post by sanphotgn » 19 Feb 18 16:43

I copied the latest updated script. Note the stars are clipped. Using PSU 4. Thanks.

Ratings.PNG
Ratings.PNG (14.37 KiB) Viewed 921 times
Photo Supreme 3.3.0.2602 (64 bits) (Windows)

weidmic
moderator
Posts: 4454
Joined: 04 Dec 06 22:21

Re: For those who like a functional rating bar

Post by weidmic » 19 Feb 18 16:49

May I suggest to create a new main-topic in the tips for working with photo supreme where everyone can add his scripts and snippets - (no dicusions) - just scripts and the description? This script might otherwise go lost in the abandance of posts!

Everyone could add scripts as I could add my custom thumb script, the script you wrote me for the labels etc.
It might be a great source, additionally to the script repository...

Even with some write protection for new users or post approval...
PSUServer 4.x, PostgreSQL 10.x
My homepage http://www.michaelweidner.com
PSU Tips and Tricks http://www.michaelweidner.com/WP/psu/

weidmic
moderator
Posts: 4454
Joined: 04 Dec 06 22:21

Re: For those who like a functional rating bar

Post by weidmic » 19 Feb 18 16:54

Sanphotgn,

I can see a small A in the last row. What is that for?
Maybe you can exchange the two lines and put the rating bar in the last line...
Attachments
rating bar.PNG
rating bar.PNG (245.18 KiB) Viewed 915 times
PSUServer 4.x, PostgreSQL 10.x
My homepage http://www.michaelweidner.com
PSU Tips and Tricks http://www.michaelweidner.com/WP/psu/

RobiWan
Posts: 79
Joined: 03 Nov 17 9:14

Re: For those who like a functional rating bar

Post by RobiWan » 19 Feb 18 17:52

Hi,

I believe I'm doing something wrong.
I have removed the 2 lines and with copy/ paste inserted the code. Then I receive "Runtime Error. Access violation"
Attachments
19-02-_2018_17-47-21.png
19-02-_2018_17-47-21.png (85.49 KiB) Viewed 899 times

Hert
Posts: 21020
Joined: 13 Sep 03 7:24

Re: For those who like a functional rating bar

Post by Hert » 19 Feb 18 18:14

Best to use the drop down -> Remove Line, then paste the entire script. You'll only see part of it in the line field but it should work as soon as you leave the line
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

RobiWan
Posts: 79
Joined: 03 Nov 17 9:14

Re: For those who like a functional rating bar

Post by RobiWan » 19 Feb 18 18:33

I do not know why but now it works.

Is there a way to display date as well as the file name in the first line?

sanphotgn
Posts: 428
Joined: 26 Aug 07 18:06

Re: For those who like a functional rating bar

Post by sanphotgn » 19 Feb 18 20:03

weidmic wrote:
19 Feb 18 16:54
Sanphotgn,

I can see a small A in the last row. What is that for?
Maybe you can exchange the two lines and put the rating bar in the last line...
The small A is the file name:

Code: Select all

<font size="14" family="arial" color="white">%FileName</font>
This is my test database where I try out stuff.

Result of moving the functional rating bar script to the lower row:

RatingsBottomRow.PNG
RatingsBottomRow.PNG (13.55 KiB) Viewed 859 times
Photo Supreme 3.3.0.2602 (64 bits) (Windows)

weidmic
moderator
Posts: 4454
Joined: 04 Dec 06 22:21

Re: For those who like a functional rating bar

Post by weidmic » 19 Feb 18 20:28

yeah, I see :)

I think my stars are way smaller. Propably relatet to the screen resolution.
My screens are all 4k...
PSUServer 4.x, PostgreSQL 10.x
My homepage http://www.michaelweidner.com
PSU Tips and Tricks http://www.michaelweidner.com/WP/psu/

jgodfrey
moderator
Posts: 5372
Joined: 17 Dec 05 5:03
Location: Warrensburg, MO (USA)

Re: For those who like a functional rating bar

Post by jgodfrey » 19 Feb 18 21:08

While I didn't analyze this script closely, reducing the "size=22" values in the following 4 lines seem to eliminate the star clipping. In my case, going down to just "size=20" fixed the clipping, though you can go smaller if necessary.

Code: Select all

      ARatingNoOnStar   := '<a href="' + ARatingAnchorHref + '"><img title="no rating" size="22" path="' + ARatingStar + '" pathfillcolor="' + ARatingNoColor + '" pathstrokestyle="solid" pathstrokecolor="' + ARatingNoColor + '"></a>';
      ARatingNoOffStar  := '<a href="' + ARatingAnchorHref + '"><img size="22" path="' + ARatingStar + '" pathfillstyle="none" pathstrokestyle="solid" pathstrokecolor="' + ARatingNoColor  + '"></a>';
      ARatingOnStar     := '<a href="' + ARatingAnchorHref + '"><img size="22" path="' + ARatingStar + '" pathfillcolor="' + ARatingColor + '" pathstrokestyle="solid" pathstrokecolor="' + ARatingColor + '"></a>';
      ARatingOffStar    := '<a href="' + ARatingAnchorHref + '"><img size="22" path="' + ARatingStar + '" pathfillstyle="none" pathstrokestyle="solid" pathstrokecolor="' + ARatingColor + '"></a>';

sanphotgn
Posts: 428
Joined: 26 Aug 07 18:06

Re: For those who like a functional rating bar

Post by sanphotgn » 19 Feb 18 22:14

jgodfrey - Thank you! Works. I had to go down to "size=18".
Photo Supreme 3.3.0.2602 (64 bits) (Windows)

Hert
Posts: 21020
Joined: 13 Sep 03 7:24

Re: For those who like a functional rating bar

Post by Hert » 20 Feb 18 14:53

The size indeed should have been "18". The images in HTML didn't scale to high DPI and so different resolutions could need different sizes. That is corrected in build 1023 which is now available. A size of "18" should fit all.
The opening script is updated.
This is a User-to-User forum which means that users post questions here for other users.
Feature requests, change suggestions, or bugs can be logged in the ticketing system

Post Reply