Discussions » Creation Requests

hover on string and show actor image

§
Posted: 2015-02-12
Edited: 2015-02-12

hover on string and show actor image

This will be amazing if this will be possible. So i have this from webpage: Actors: Brad Pitt, A. J. Cook, Jean-Claude Van Damme, Arnold Schwarzenegger
First i need a regex to find the actors delimited by comma and give them href properties, and always after last actor is
, and when i hover over actor name to show me a little photo of him from links down in comments, is it possible?

wOxxOmMod
§
Posted: 2015-02-12
Edited: 2015-02-12

It's possible but such script will slow down the browser and generate thousands of requests to google/imdb, so they'll block you after a few seconds :) If you're really into this hollywood stuff, you'll remember all the stars eventually by heart so just give it some time.

P.S. You've posted into the wrong forum. Site feedback is for greasyfork.org site feedback.

§
Posted: 2015-02-12

I think it should be possible. You'd probably have to have some caching to prevent what @wOxxOm describes.

§
Posted: 2015-02-12
Edited: 2015-02-12

sorry for wrong forum part :D i found something interesting i think:
so for example i have actress Emma Stone,
in this link there http://sg.media-imdb.com/suggests/e/emm.json
found her, it's loading fast, and there is posters too,
for Arnold Schwarzenegerr i just edited the link to
http://sg.media-imdb.com/suggests/a/arn.json and found Arnie too)
http://sg.media-imdb.com/suggests/j/jea.json - Jean-Claude Van Damme
so the script need to parse and find for the 1 letter and 3 letters from family
Bradd Pittt - http://sg.media-imdb.com/suggests/p/pit.json
Eva Longoria - http://sg.media-imdb.com/suggests/l/lon.json
Leslie Nielsen - http://sg.media-imdb.com/suggests/n/nie.json
so there is the first letter from family and then 3 letters too from family
i think this is it, this is the good path for script

§
Posted: 2015-02-12
Edited: 2015-02-12

oh, and one more thing
http://sg.media-imdb.com/suggests/j/jol.json - Angelina Jolie (searched by family)
http://sg.media-imdb.com/suggests/a/ang.json - Angelina Jolie (search by name)
http://sg.media-imdb.com/suggests/p/pit.json - Brad Pitt (by family)
http://sg.media-imdb.com/suggests/b/bra.json - Brad Pitt (by name)
this is fun :D
P.P.S.: FYI this can find movies too
http://sg.media-imdb.com/suggests/a/arr.json - Arrow
http://sg.media-imdb.com/suggests/m/mat.json - The Matrix
http://sg.media-imdb.com/suggests/h/han.json - Hannibal

§
Posted: 2015-02-12

Well I'm not going to write this for you, maybe someone else will, but if you have specific questions I may give you answers.

§
Posted: 2015-02-13
Edited: 2015-02-13

ok, i guess i need to find how to write a regex to

Actors: Brad Pitt, A. J. Cook, Jean-Claude Van Damme, Arnold Schwarzenegger


because after Actors: on each movies will be different numbers of actors, until the
after last actor

§
Posted: 2015-02-13

You probably don't want a regex, you probably want to find all <b>s with text of "Actors", get the text up to the next <br>, then split on ,.

§
Posted: 2015-02-13
Edited: 2015-02-13

that's a good ideea, doing right now, thank you!

i guess the begin will be like that

var actors = /Actori.*?<\/b>\:\s(.*)
/g;
var splitactors = actors.split(',\s');

§
Posted: 2015-02-14

offtopic:
I was plagued by vague doubts, barbiegirl and drakulaboy, aren't they the one and same person?

§
Posted: 2015-02-14

hehe, nope, i'm only one person, my name is Andy and this is only my account

§
Posted: 2015-02-14

found something, but now i just want to convert those strings in links, so when i hover with mouse it will appear a small pic

§
Posted: 2015-02-17

Finally!!!
 
pics from imdb

Post reply

Sign in to post a reply.