Is it possible to put HTML in an ASP.NET .ashx file? -
i wondering possible place html/javascript/etc in .ashx file. tried doing this, , getting error "a namespace cannot directly contain members such fields or methods"
the reason want this, because trying implement photoswipe (http://www.photoswipe.com). photoswipe needs special css, think losing when go .ashx file. want able add html point @ css file think losing.
edit: here example of markup looks like. when click on href, brought new page ".ashx?querystringparms=blah" in browser. here believe losing css.
<div style="text-align:center;" class="gallery-page" data-role="content"> <ul id="gallery" class="gallery" style="max-height: 75%;"> <li style="height: 120px; width: 93px; padding-bottom: 2px;"><a href="../utilities/imagehandler.ashx?querystringparms=blah rel="external"><img src="../utilities/imagehandler.ashx?querystringparms=blah" /></a></li></ul></div>
thanks
your code should :
<div style="text-align:center;" class="gallery-page" data-role="content"> <ul id="gallery" class="gallery" style="max-height: 75%;"> <li style="height: 120px; width: 93px; padding-bottom: 2px;"><a href="bigimage.aspx?querystringparms=blah rel="external"><img src="../utilities/imagehandler.ashx?querystringparms=blah" /></a></li></ul></div>
and then, in bigimage.aspx file, you'd have html (the css , javascript may need) + image tag :
<img src="../utilities/imagehandler.ashx?querystringparms=blah" />
i presume querystring params indicate image want , needed size
Comments
Post a Comment