looking for code to make image zom with frame
2 posters
Page 1 of 1
looking for code to make image zom with frame
looking for code to make image zom with frame instead of click here to inlarge image something like this but with a frame
edit
the needed Script with click not hover on the images
- Code:
.postbody img{-webkit-transition-duration: 0.5s; /*Webkit: Animation duration*/-moz-transition-duration: 0.5s; /*Mozilla duration version*/ } .postbody img:hover{-moz-transform:scale(1.1); /*Mozilla scale version*/-moz-box-shadow:0px 0px 0px gray; /*Mozilla shadow version*/opacity: 1;}
edit
the needed Script with click not hover on the images
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
Hello Michael,
Something like this ?
https://help.forumotion.com/t115826-add-a-lightbox-effect-to-the-images-of-the-forum
Something like this ?
https://help.forumotion.com/t115826-add-a-lightbox-effect-to-the-images-of-the-forum
Re: looking for code to make image zom with frame
1st sorry for delay internet is super badAnge Tuteur wrote:Hello Michael,
Something like this ?
https://help.forumotion.com/t115826-add-a-lightbox-effect-to-the-images-of-the-forum
2nd yes it is all what i like to add is a frame around the image when zoom
if possible
and thanks for understanding what i was looking for it
i like your way of reading my mind
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
That's fine there's no rush.
So, you don't want it exactly like that ? You just want the image to zoom when you click on it ?
So, you don't want it exactly like that ? You just want the image to zoom when you click on it ?
Re: looking for code to make image zom with frame
Ange Tuteur wrote:That's fine there's no rush.
So, you don't want it exactly like that ? You just want the image to zoom when you click on it ?
yes when i click on and i like to know if it possible to have a freame a round the image when zoom if possible
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
is the frame part hard
or topic lost in wonderland hahah
im just kidding
just for bump
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
See if this is what you want :
Administration Panel > Modules > JavaScript codes management > Create a new script
Title : Your choice
Placement : In the topics
Paste the code below and submit :
Next go to Display > Colors > CSS stylesheet and add the code below :
The class .c_0 is the default class (Not clicked), It is changed to .c_1 on click.
Administration Panel > Modules > JavaScript codes management > Create a new script
Title : Your choice
Placement : In the topics
Paste the code below and submit :
- Code:
$(function() {
var img = $('.post .postbody div img');
for (i=0; i<img.length; i++) {
img[i].className += ' c_0';
img[i].onclick = function() {
if (/c_0/.test(this.className)) this.className = this.className.replace(/c_0/,'c_1');
else if (/c_1/.test(this.className)) this.className = this.className.replace(/c_1/,'c_0');
}
}
});
Next go to Display > Colors > CSS stylesheet and add the code below :
- Code:
.c_0, .c_1 { transition:500ms }
.c_1 {
transform:scale(1.5);
border:4px solid #AAA;
box-shadow:3px 3px 3px rgba(0,0,0, 0.5);
}
The class .c_0 is the default class (Not clicked), It is changed to .c_1 on click.
Re: looking for code to make image zom with frame
wow super cool thanks so much ange
if you dont mind tell me how to edit the frame and the zoom and mark topic as solved
this what i want in topics
topic solved super thanks
if you dont mind tell me how to edit the frame and the zoom and mark topic as solved
this what i want in topics
topic solved super thanks
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
You're welcome ^^
You can modify this rule to change the style of the clicked image :
this rule determines the speed of the transition :
That's all you need to change.
You can modify this rule to change the style of the clicked image :
- Code:
.c_1 {
transform:scale(1.5);
border:4px solid #AAA;
box-shadow:3px 3px 3px rgba(0,0,0, 0.5);
}
this rule determines the speed of the transition :
- Code:
.c_0, .c_1 { transition:500ms }
That's all you need to change.
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Re: looking for code to make image zom with frame
You can set it as a background, but I'm not sure how well it would appear. Here's the CSS of that though :
Yep, scale adjusts how the image zooms.
The third line :
Adds a drop shadow to the image.
- Code:
.c_1 {
transform:scale(1.5);
background:url('http://i39.servimg.com/u/f39/11/74/20/44/4010.jpg') no-repeat center / 100% 100%;
padding:3%; /* space around image */
box-shadow:3px 3px 3px rgba(0, 0, 0, 0.5);
}
Yep, scale adjusts how the image zooms.
The third line :
Adds a drop shadow to the image.
- Code:
box-shadow:3px 3px 3px rgba(0, 0, 0, 0.5);
Re: looking for code to make image zom with frame
worked after i added this
- Code:
.c_0, .c_1 { transition:500ms }
.c_1 {
- Code:
transform:scale(1.5);
background:url('http://i39.servimg.com/u/f39/11/74/20/44/4010.jpg') no-repeat center / 100% 100%;
padding:3%; /* space around image */
box-shadow:3px 3px 3px rgba(0, 0, 0, 0.5);
}
Michael_vx- Forumember
- Posts : 659
Reputation : 29
Language : Arabic and some English
Location : Egypt
Similar topics
» Code to frame tinychat
» Make the Image a Link
» Text frame to an image
» Make image
» How do i make an image pop-up
» Make the Image a Link
» Text frame to an image
» Make image
» How do i make an image pop-up
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum