Solved

aspjepg component

Posted on 2006-11-03
4
275 Views
Last Modified: 2011-10-03
Hello,
I just downloaded a trial version of aspjpeg component, but i don't know how to use it.
I was wondering if someone could show me how to use this component in a regular asp page requesting the width and the height from the url?

Thank you.
0
Comment
Question by:itortu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 28

Expert Comment

by:strickdd
ID: 17867701
<%
' Create instance of AspJpeg
Set Jpeg = Server.CreateObject("Persits.Jpeg")

' Compute path to source image
Path = Server.MapPath("../images/apple.jpg")

' Open source image
Jpeg.Open Path

' Decrease image size by 50%
Jpeg.Width = Jpeg.OriginalWidth / 2
Jpeg.Height = Jpeg.OriginalHeight / 2

' create thumbnail and save it to disk
Jpeg.Save Server.MapPath("apple_small.jpg")

%>

http://www.aspjpeg.com/manual_01.html
0
 

Author Comment

by:itortu
ID: 17867721
where are the width and the height beeing requested from the url?

thank you.
0
 

Author Comment

by:itortu
ID: 17867898
how can i view the image using the script in the example? would you be able to show me?
0
 
LVL 28

Accepted Solution

by:
strickdd earned 150 total points
ID: 17868001
<%
' Create instance of AspJpeg
Set Jpeg = Server.CreateObject("Persits.Jpeg")

' Compute path to source image
Path = Server.MapPath("../images/apple.jpg")

' Open source image
Jpeg.Open Path

' Decrease image size by 50%
Jpeg.Width = Request.QueryString("Width")
Jpeg.Height = Request.QueryString("Height")

' create thumbnail and save it to disk
Jpeg.Save Server.MapPath(FileName & ".jpg") 'input what you want the file to be called

Response.Write("<img src='" & Server.MapPath(FileName & ".jpg")  & "'>")

%>
0

Featured Post

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
JQuery to parse xml string and get element by id 4 65
Sending ASP to server side 8 33
SQL to JSON 14 40
JQuery DataTable Functionality 8 20
Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question