But its only for jpg.Is there any way to apply on other file formats.

You can do it for any format you wish, just specify which one after the ";". But keep in mind that each file format has different coding needed to handle it. You will have to put in a Select statement to grab the file tag and execute the code that is for it.

I have the same problem as nandhinijp. I have this thing working on my local, but it doesnt work on the server. Did you ever find out what the problem was with that?

Try giving nandhinijp a PM and see if he will respond. I never heard from it again, so I am assuming he solved it.

Hi,I didnt solve problem.

It most likely is a settings problem. Try removing the extra gunk from the VS web.config, and keep what you need. VS tends to add so much extra, that I usually have to rewrite the entire file in order for it to work on the server.

I mean, on here they say to do some IIS configuration but it still doesn't seem to do it. When i add the extensions, none of the images on the website appear at all.

Really i dont know the exact problem..I think its not setting pbm.Because i am using one type of server,another one using another type of server.but both place it doesnt give result.

this is sooooo frustrating. After battling to get the functionality working I can't implement it into my server. GRRR! sorry had to vent...

hello there,
In your your web.config file, you have the ImageHandler class being called for every .jpg, etc
So put all the coding within a function. Then you can call that function on the certain photos you want watermarked. Feel free to drop in queries further.
Regards,
Bmora96

I could'nt get.How to put all the codings within a function.the whole details are in one separate class file it implements httphandler.Please tell specifically.

Is there any new idea for this..

i want to add watermark in image.i am using image handler. its not properly working. i want to add watermark at runtime only no need for original image.in my home page i have 25 thumbnail images. when i click any one of the image it goes next page and display large image at that time only i need watermark in image.please reply as early as possible.

hai i am satheesh, i have the full coding for the watermark , may i help u ,....

hai i am satheesh, i have the full coding for the watermark , may i help u ,....

Instead of asking such silly question you should already posted

Hi ,
Its not working in remote server.Please help!

What is it displaying to you.. an error, or just the image that is unwatermarked?

If it is displaying just the image, post your config file and the image names you are calling.

Yes .display the image that is unwatermarked.

Webconfig

<?xml version="1.0"?>
<!-- 
    Note: As an alternative to hand editing this file you can use the 
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in 
    machine.config.comments usually located in 
    \Windows\Microsoft.Net\Framework\v2.x\Config 
-->
<configuration>
	
	<appSettings>

		


		
		
		<!-- UPLOAD SITE-->
		<add key="ConnectionString" value="server=aaa;uid=xxx;pwd=yyy;database=zzz;" />
		<!-- Connectionstring-->		
		
		
    
	</appSettings>	
	<connectionStrings/>
	  
	<system.web>
		<!-- 
            Set compilation debug="true" to insert debugging 
            symbols into the compiled page. Because this 
            affects performance, set this value to true only 
            during development.
        -->
		[B]<httpHandlers>
			<add verb="*" type="ImageHandler" path="*showimage.jpg,*showimage.png,*showimage.gif,*showimage.bmp"/>
		</httpHandlers>[/B]		
		<compilation debug="true"/>
		<!--
            The <authentication> section enables configuration 
            of the security authentication mode used by 
            ASP.NET to identify an incoming user. 
        -->
		<authentication mode="Windows"/>
		<!--
            The <customErrors> section enables configuration 
            of what to do if/when an unhandled error occurs 
            during the execution of a request. Specifically, 
            it enables developers to configure html error pages 
            to be displayed in place of a error stack trace.

        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>
        -->
		<customErrors mode="Off">
		</customErrors>
	</system.web>
	
</configuration>

<httpHandlers> </httpHandlers> this is only for watermark.Other details are already posted.

you need to specify your assembly after your "ImageHandler". Also make sure you're re-routing requests. But I am pretty damn sure it is because the imagehandler is never being called. You will need to attach that specific handler to your assembly class.

i want to add watermark in image.i am using image handler. its not properly working. i want to add watermark at runtime only no need for original image.in my home page i have 25 thumbnail images. when i click any one of the image it goes next page and display large image at that time only i need watermark in image.please reply as early as possible.

Why not use free watermark software??? Google can give you tons of results...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.