Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

take an image portion

jacque99jacque99 Posts: 5Member
I made a calculation of the proportion between width and height from the maximum dimensions and the same thing from
actual dimensions of the picture: I then compared the two resizing in the appropriate direction depending on whether the result is
positive or negative.
Finally, my code works:)
For cons, I still have that to make a thumbnail of my image, the principle and calculated the center of the height and width of the image and make a thumbnail from the center as shown in the image

www.mestestes.eu / proportion.jpg
I await your comments
Here is my code that works well
[code]













Le nom de l'image redimensionner avec 95 ,95














[/PHP]


[PHP]
<?php


$nomImage=$_POST['video'];

if( isset($_POST['upload']) ) // si formulaire soumis
{
$content_dir = 'upload/'; // dossier o
Sign In or Register to comment.