Forum FAQForum FAQSearchSearch MemberlistMemberlist Forum ignore listForum ignore list RegisterRegister ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in
Ne loada mi fotogaleriju

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Flash
View previous topic :: View next topic  
Author Message
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 27.01.2007 00:10    Post subject: Ne loada mi fotogaleriju Add user to your forum ignore list Reply with quote

BOk ekipo.
Evo imam jedan problem.
Imam početni file u kojemu sam napisao u action scriptu:

_root.contents.loadMovie("Onamatekst.swf");
_root.hedr.loadMovie("meni+header.swf");
_root.slike.loadMovie("slike.swf");

i on meni otvara ova prednja dva, a ovu galeriju mi neće loadati.
Napravio sam ju pomoću totorijala sa :

http://www.kirupa.com/developer/mx/photogallery.htm

Ajd helpajte...hitno mi je..

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
blackduke
mi3.crew


Joined: 08 Sep 2003
Posts: 2681
Location: Zagreb

PostPosted: 27.01.2007 04:57    Post subject: Add user to your forum ignore list Reply with quote

pa moze bit hrpa stvari. pokazi cijelu stvar da ti pomognemo...
Back to top
View user's profile Send private message Visit poster's website Twitter profile
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 27.01.2007 10:11    Post subject: Add user to your forum ignore list Reply with quote

Stvar je u tome da loada galeriju, ali ne loada slike koje galerije vuće iz fileova sastrane.

Ovo je kod galerije:

/*
i wrote this code, but you can use and abuse it however you like.
the methods are defined in the order which they occur to make it
easier to understand.
*/
// variables ------------------------------------------
// put the path to your pics here, include the slashes (ie. "pics/")
// leave it blank if they're in the same directory
this.pathToPics = "tulum1/";
// fill this array with your pics
this.pArray = ["image0.jpg", "image1.jpg", "image2.jpg", "image3.jpg"];
this.fadeSpeed = 50;
this.pIndex = 0;
// MovieClip methods ----------------------------------
// d=direction; should 1 or -1 but can be any number
//loads an image automatically when you run animation
loadMovie(this.pathToPics+this.pArray[0], _root.photo);
MovieClip.prototype.changePhoto = function(d) {
// make sure pIndex falls within pArray.length
this.pIndex = (this.pIndex+d)%this.pArray.length;
if (this.pIndex<0) {
this.pIndex += this.pArray.length;
}
this.onEnterFrame = fadeOut;
};
MovieClip.prototype.fadeOut = function() {
if (this.photo._alpha>this.fadeSpeed) {
this.photo._alpha -= this.fadeSpeed;
} else {
this.loadPhoto();
}
};
MovieClip.prototype.loadPhoto = function() {
// specify the movieclip to load images into
var p = _root.photo;
//------------------------------------------
p._alpha = 0;
p.loadMovie(this.pathToPics+this.pArray[this.pIndex]);
this.onEnterFrame = loadMeter;
};
MovieClip.prototype.loadMeter = function() {
var i, l, t;
l = this.photo.getBytesLoaded();
t = this.photo.getBytesTotal();
if (t>0 && t == l) {
this.onEnterFrame = fadeIn;
} else {
trace(l/t);
}
};
MovieClip.prototype.fadeIn = function() {
if (this.photo._alpha<100-this.fadeSpeed) {
this.photo._alpha += this.fadeSpeed;
} else {
this.photo._alpha = 100;
this.onEnterFrame = null;
}
};
// Actions -----------------------------------------
// these aren't necessary, just an example implementation
this.onKeyDown = function() {
if (Key.getCode() == Key.LEFT) {
this.changePhoto(-1);
} else if (Key.getCode() == Key.RIGHT) {
this.changePhoto(1);
}
};
Key.addListener(this);

Znaći u istom folderu su ovaj početni file i file od galerije, a slike su u Folderu Tulum1.

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
astolitu



Joined: 26 Jun 2004
Posts: 547
Location: Zagreb

PostPosted: 27.01.2007 17:45    Post subject: Add user to your forum ignore list Reply with quote

Tulum 1 folder ti treba bit u istom folderu sa ovim ostalim

_________________
http://www.markobjedov.com/
Back to top
View user's profile Send private message Visit poster's website Twitter profile
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 27.01.2007 19:32    Post subject: Add user to your forum ignore list Reply with quote

Jesu, u istom su folderu!

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
astolitu



Joined: 26 Jun 2004
Posts: 547
Location: Zagreb

PostPosted: 27.01.2007 19:42    Post subject: Add user to your forum ignore list Reply with quote

"/tulum1"

_________________
http://www.markobjedov.com/
Back to top
View user's profile Send private message Visit poster's website Twitter profile
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 27.01.2007 20:49    Post subject: Add user to your forum ignore list Reply with quote

Gle.. . kada sam radio galeriju sve u njoj radi i sada kad ju otvorim otvara slike i sve super, ali kad mi loada iz glavne stranice galeriju neće loadati slike...

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
astolitu



Joined: 26 Jun 2004
Posts: 547
Location: Zagreb

PostPosted: 27.01.2007 21:17    Post subject: Add user to your forum ignore list Reply with quote

_root.loadMovie("pg7.swf", "slike");

ovo ce ti radit, a zasto? proceprkaj sam Cool

_________________
http://www.markobjedov.com/
Back to top
View user's profile Send private message Visit poster's website Twitter profile
astolitu



Joined: 26 Jun 2004
Posts: 547
Location: Zagreb

PostPosted: 27.01.2007 21:54    Post subject: Add user to your forum ignore list Reply with quote

_root.slike.loadMovie("slike.swf");


evo ti kod za slike:

this.pathToPics = "tulum1/";
// fill this array with your pics
this.pArray = ["image0.jpg", "image1.jpg", "image2.jpg", "image3.jpg"];
this.fadeSpeed = 20;
this.pIndex = 0;
// MovieClip methods ----------------------------------
// d=direction; should 1 or -1 but can be any number
//loads an image automatically when you run animation
photo.loadMovie(this.pathToPics+this.pArray[0]);
MovieClip.prototype.changePhoto = function(d) {
// make sure pIndex falls within pArray.length
this.pIndex = (this.pIndex+d)%this.pArray.length;
if (this.pIndex<0) {
this.pIndex += this.pArray.length;
}
this.onEnterFrame = fadeOut;
};
MovieClip.prototype.fadeOut = function() {
if (this.photo._alpha>this.fadeSpeed) {
this.photo._alpha -= this.fadeSpeed;
} else {
this.loadPhoto();
}
};
MovieClip.prototype.loadPhoto = function() {
// specify the movieclip to load images into
var p = photo;
//------------------------------------------
p._alpha = 0;
p.loadMovie(this.pathToPics+this.pArray[this.pIndex]);
this.onEnterFrame = loadMeter;
};
MovieClip.prototype.loadMeter = function() {
var i, l, t;
l = this.photo.getBytesLoaded();
t = this.photo.getBytesTotal();
if (t>0 && t == l) {
this.onEnterFrame = fadeIn;
} else {
//trace(l/t);
}
};
MovieClip.prototype.fadeIn = function() {
if (this.photo._alpha<100-this.fadeSpeed) {
this.photo._alpha += this.fadeSpeed;
} else {
this.photo._alpha = 100;
this.onEnterFrame = null;
}
};

this.onKeyDown = function() {
if (Key.getCode() == Key.LEFT) {
changePhoto(-1);
} else if (Key.getCode() == Key.RIGHT) {
changePhoto(1);
}
};
Key.addListener(this);


na botunu ide ovo:
//desni:
on (release) {
changePhoto(1);
}
//lijevi
on (release) {
changePhoto(-1);
}

_________________
http://www.markobjedov.com/
Back to top
View user's profile Send private message Visit poster's website Twitter profile
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 28.01.2007 12:50    Post subject: Add user to your forum ignore list Reply with quote

Fala ti...puno ti hvala. Spasio si me. U čemu je bila greška?

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 30.01.2007 00:07    Post subject: Add user to your forum ignore list Reply with quote

I sad ju stavim na web i neće mi raditi..niti zasebno kao file..popizdit ću..

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Julius



Joined: 18 Dec 2004
Posts: 376
Location: Jastrebarsko

PostPosted: 30.01.2007 00:16    Post subject: Add user to your forum ignore list Reply with quote

Evo da pojasnim. Stavio sam u kod da loada kaoa folder galerije folder gdje je on na internetu i s akompa mi sve korektno radi. Ako ugasim internet ne radi, znači da funkcionira. Kad dođem na net stranica mi loada galeriju, ali nema slika. Nije mi sad više niš jasno...

_________________
BOlje biti mrtav Pijan nego mrtav Trijezan...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    mi3dot.org Forum Index -> Flash All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group