- Posts: 8
- Thank you received: 0
Discussion about Hot Spinner Joomla module.
Center rotating images
-
jcandco
Inactive member - Topic Author
- New Member
Less
More
13 years 5 months ago #9206
by jcandco
Center rotating images was created by jcandco
hi,
Could you give me the parameters used in your demo ?
I would like have the same effect
Like you can see in my test, the rotating images are not centered horizontally and not vertically.
Thanks
JC
Could you give me the parameters used in your demo ?
I would like have the same effect
Like you can see in my test, the rotating images are not centered horizontally and not vertically.
Thanks
JC
Please Log in to join the conversation.
-
ivan.milic
Support Staff - Moderator
Less
More
- Posts: 14116
- Thank you received: 1639
13 years 5 months ago #9224
by ivan.milic
Replied by ivan.milic on topic Re: Center rotating images
Hi,
Here are parameters in attachment, but I would say that you problem is not with the parameters.
Eater center of rotation is bad or container is translated by some css property coming form your template.
Here is how it's calculated :
<?php
$rotationCenterX = ($moduleWidth / 2) - ($rotatingImageWidth / 4);
$rotationCenterY = ($moduleHeight / 2) - ($rotatingImageHeight / 4);
?>
If parameters don't help you can try to add offset to this:
example:
<?php
$rotationCenterX = ($moduleWidth / 2) - ($rotatingImageWidth / 4) - 300;
$rotationCenterY = ($moduleHeight / 2) - ($rotatingImageHeight / 4) - 20;
?>
I added -300 to X and -20 to Y position.
this is in
modules\mod_hot_spinner\tmpl\default.php
Here are parameters in attachment, but I would say that you problem is not with the parameters.
Eater center of rotation is bad or container is translated by some css property coming form your template.
Here is how it's calculated :
<?php
$rotationCenterX = ($moduleWidth / 2) - ($rotatingImageWidth / 4);
$rotationCenterY = ($moduleHeight / 2) - ($rotatingImageHeight / 4);
?>
If parameters don't help you can try to add offset to this:
example:
<?php
$rotationCenterX = ($moduleWidth / 2) - ($rotatingImageWidth / 4) - 300;
$rotationCenterY = ($moduleHeight / 2) - ($rotatingImageHeight / 4) - 20;
?>
I added -300 to X and -20 to Y position.
this is in
modules\mod_hot_spinner\tmpl\default.php
Attachments:
Please Log in to join the conversation.
-
planethop
Inactive member - Member
Less
More
- Posts: 21
- Thank you received: 0
13 years 4 months ago - 13 years 4 months ago #10373
by planethop
Replied by planethop on topic Re: Center rotating images
For some reason the images in my spinner are suddenly shifted to the right. I made no recent changes to the module. Please see:
planethop.com/
This only seems to be happening on widescreen monitors. I checked on several PCs and laptops.
Why is this happening?
How would I get the images to be centered in the module again?
I amusing Joomla 1.5.23
planethop.com/
This only seems to be happening on widescreen monitors. I checked on several PCs and laptops.
Why is this happening?
How would I get the images to be centered in the module again?
I amusing Joomla 1.5.23
Last edit: 13 years 4 months ago by planethop.
Please Log in to join the conversation.
-
ivan.milic
Support Staff - Moderator
Less
More
- Posts: 14116
- Thank you received: 1639
13 years 4 months ago #10381
by ivan.milic
Replied by ivan.milic on topic Re: Center rotating images
In your template all divs are relatively positioned. You must add this css:
.art-sheet-body,.art-sheet{
position:static!important;
}
.art-sheet-body,.art-sheet{
position:static!important;
}
Please Log in to join the conversation.
Time to create page: 0.156 seconds