开发一个简单的照片ASP.NET / MVC应用程序,该怎么做?

时间:2022-10-21 04:14:02

I found this web site (photoblog) http://www.OneReaction.net/

我找到了这个网站(photoblog)http://www.OneReaction.net/

and I am very curious how this is done: 1) From source code you don't see the image URL 2) How to overlay the copyright information on the image without changing the underlying photo?

我很好奇这是如何做到的:1)从源代码中你看不到图像URL 2)如何在不改变底层照片的情况下在图像上叠加版权信息?

Ideas? Thanks!

3 个解决方案

#1


4  

Check this link: Watermarking Images in ASP.NET with an HttpHandler. It describes a technique for adding watermarks to every image of your site. By changing the path of the HttpHandler in the web.config to something less general (e.g. /photos/*.jpg), you can constraint the effect to a subset of images.

检查此链接:使用HttpHandler在ASP.NET中为图像添加水印。它描述了一种为网站的每个图像添加水印的技术。通过将web.config中HttpHandler的路径更改为较不通用的(例如/photos/*.jpg),可以将效果约束为图像子集。

#2


2  

I believe that the ImageHandler.ashx is intercepting the requests and placing the copyright information into the image before delivering it to the browser. The handler is likely set up to capture all attempts to browse to a .jpg file.

我相信ImageHandler.ashx正在拦截请求并将版权信息放入图像,然后再将其发送到浏览器。处理程序可能设置为捕获浏览到.jpg文件的所有尝试。

The documentation on the drawing namespace should help you figure out the actual code for inserting text into an image.

有关绘图命名空间的文档应该可以帮助您确定将文本插入图像的实际代码。

#3


0  

The URL is in source code

URL位于源代码中

<img id="image" title="Condemned to Contrast II" src="Resources/ImageHandler.ashx" 
    alt="Condemned to Contrast II" style="border-width:0px;" />

Try this link

试试这个链接

#1


4  

Check this link: Watermarking Images in ASP.NET with an HttpHandler. It describes a technique for adding watermarks to every image of your site. By changing the path of the HttpHandler in the web.config to something less general (e.g. /photos/*.jpg), you can constraint the effect to a subset of images.

检查此链接:使用HttpHandler在ASP.NET中为图像添加水印。它描述了一种为网站的每个图像添加水印的技术。通过将web.config中HttpHandler的路径更改为较不通用的(例如/photos/*.jpg),可以将效果约束为图像子集。

#2


2  

I believe that the ImageHandler.ashx is intercepting the requests and placing the copyright information into the image before delivering it to the browser. The handler is likely set up to capture all attempts to browse to a .jpg file.

我相信ImageHandler.ashx正在拦截请求并将版权信息放入图像,然后再将其发送到浏览器。处理程序可能设置为捕获浏览到.jpg文件的所有尝试。

The documentation on the drawing namespace should help you figure out the actual code for inserting text into an image.

有关绘图命名空间的文档应该可以帮助您确定将文本插入图像的实际代码。

#3


0  

The URL is in source code

URL位于源代码中

<img id="image" title="Condemned to Contrast II" src="Resources/ImageHandler.ashx" 
    alt="Condemned to Contrast II" style="border-width:0px;" />

Try this link

试试这个链接