Page 1 of 1

Script idea: IMDB check

Posted: 15 Nov 2008 10:17
by sTu_Deimus
Hi all.

Here's a (somewhat self-serving) script idea I'd love to see created.

Supposing one had a bunch of files with names representing backups of movies, eg:

Superman.avi

I'd like to be able to right-click and run that script and have it fire-off a URL in a browser that searches for that name (without the extension etc) at IMDB.com.

Many such sites have standard search syntax, so I presume that syntax could be filled out with the name as found in the filename.

Does this sound like a piece of cake or what? :)

Stu.

Re: Script idea: IMDB check

Posted: 15 Nov 2008 10:45
by admin
Nice idea! Have an example for how to link to imdb by movie title?

Re: Script idea: IMDB check

Posted: 15 Nov 2008 10:51
by admin
admin wrote:Nice idea! Have an example for how to link to imdb by movie title?
Found some info: http://us.imdb.com/how_to_link

The rest is easy, I leave it as an excercise. :mrgreen:

Tips: POM, <curbase>

Re: Script idea: IMDB check

Posted: 15 Nov 2008 16:10
by TheQwerty

Code: Select all

"Search IMDB" *>::Open("http://www.imdb.com/find?s=tt&q=<curbase>");
You might want to adjust the filter to only apply it to video files.


It would be nice if we had URLEncode() and URLDecode() functions available in scripting, Don. :wink:

Re: Script idea: IMDB check

Posted: 15 Nov 2008 19:51
by admin
TheQwerty wrote:

Code: Select all

"Search IMDB" *>::Open("http://www.imdb.com/find?s=tt&q=<curbase>");
You might want to adjust the filter to only apply it to video files.


It would be nice if we had URLEncode() and URLDecode() functions available in scripting, Don. :wink:
Yep, I'll add them.

@sTu_Deimus
That line of code from TheQwerty should be added into Portable File Associations/POM. If you need more help, say so.

Re: Script idea: IMDB check

Posted: 15 Nov 2008 22:53
by sTu_Deimus
Yep, works a treat! Thanks :)

One question though... the only way I seem to be able to access it is via File-OpenWith.

The ContextSensetiveMenu:OpenWith doesn't show it (presume this one is windows generated).

Can I have such an entry appear on the root of the ContextSensetiveMenu ? :) Perhaps the fact that its an open-slather wildcard PFA makes it more suitable for this.

:)

Stu.

Re: Script idea: IMDB check

Posted: 16 Nov 2008 01:14
by TheQwerty
sTu_Deimus wrote:The ContextSensetiveMenu:OpenWith doesn't show it (presume this one is windows generated).

Can I have such an entry appear on the root of the ContextSensetiveMenu ? :) Perhaps the fact that its an open-slather wildcard PFA makes it more suitable for this.
You're correct here.

You could add the Open With button to your toolbar as well, but currently you can't trigger it via Right Click/Context Menu. I believe this will come eventually, but for now we have to live with only having all the other options.

Re: Script idea: IMDB check

Posted: 16 Nov 2008 07:29
by serendipity
sTu_Deimus wrote:Yep, works a treat! Thanks :)

One question though... the only way I seem to be able to access it is via File-OpenWith.

The ContextSensetiveMenu:OpenWith doesn't show it (presume this one is windows generated).

Can I have such an entry appear on the root of the ContextSensetiveMenu ? :) Perhaps the fact that its an open-slather wildcard PFA makes it more suitable for this.

:)

Stu.
Just to add few more points apart from what TheQwerty said. You can already use a small script which will open a custom menu on double-click. For example you can paste the below script in a text file inside XY's scripts folder and name it anything; say "OpenVIDs.xys".

Code: Select all

"Open Video with &Media player" 
    OpenWith "C:\Program Files\K-Lite Codec Pack\Media Player Classic\mplayerc.exe", s; 

"Search &IMDB database" 
    Open("http://www.imdb.com/find?s=tt&q=<curbase>");
You can change the path to your media player above accordingly.

Now put the below line in "Tools | List management | Portable file associations":

Code: Select all

"Open Videos" wmv;avi;mpg>::load "OpenVIDs"
Ofcourse you can add or remove extensions above and double clicking on those extensions will pop-up your created menu, in this case Open video with Media player and Search IMDB database.

Re: Script idea: IMDB check

Posted: 17 Nov 2008 11:30
by admin
TheQwerty wrote:It would be nice if we had URLEncode() and URLDecode() functions available in scripting, Don. :wink:
Next version. 8)

Re: Script idea: IMDB check

Posted: 07 Aug 2011 02:06
by sTu_Deimus
Hi,

When I last looked at this (above)there was a partial workaround, but I ended up not using it due to whatever inadequacies were present... I see some comments above about upcoming/missing functionality that would help the cause. Any comment about improvements in this are in the current release?

Or, has something similar been directly implemented?

One thing I didn't mention back then, was the need to filter out specific tags in the filename, eg:

sometag.SuperBob (1234)[Somecode][geeba].avi

I'd like to filter all but the SuperBob for the URL trigger.

From the above example, I'd also like for XY to offer tree list columns based on those tags in brackets. eg. if XY sees [Somecode] in the name, it strips it from the filename display, and shows that value in that column. That is an inver-simplification but still seems like something XY could do.

Stu.

Re: Script idea: IMDB check

Posted: 07 Aug 2011 02:16
by nas8e9
sTu_Deimus wrote:Hi,

When I last looked at this (above)there was a partial workaround, but I ended up not using it due to whatever inadequacies were present... I see some comments above about upcoming/missing functionality that would help the cause. Any comment about improvements in this are in the current release?

Or, has something similar been directly implemented?
URLEncode and URLDecode have been implemented and are documented in the help file. Context menu editing isn't yet available; it may be part of the planned Custom Event Actions (CEA)-functionality.

I can't help you with your other questions, unfortunately.

Re: Script idea: IMDB check

Posted: 07 Aug 2011 02:21
by sTu_Deimus
NP - Thanks for the info :)