Package Java

Examples of Java.Photo


        if(page > photos.size()/pageItems) {page = needed;}
        if(page < 1) {page = 1;}
        max = (page*(pageItems-1)+page);
        int i;
        for(i = max-pageItems; i < photos.size() && i < max; i++) {
            Photo p = photos.get(i);
            out.print("<div class='container'>");
            out.print("<div class='img' onclick='photoClick(" + p.getNo() + ")'>");
            out.print("<img src='ServletGetImage?photo=" + p.getNo() + "'>");
            out.print("</div>");
            out.print("<input type='button' id='btn" + p.getNo() + "' onclick='like(" + p.getNo() + ")' value='" + liked("" + p.getNo()) + "' style='margin: 0px;'/>");
            out.print("<b>" + p.getRating() + " likes</b>");
            out.print("</div>");
        }
        return i;
    }
View Full Code Here


        if(page > photos.size()/pageItems) {page = needed;}
        if(page < 1) {page = 1;}
        max = (page*(pageItems-1)+page);
        int i;
        for(i = max-pageItems; i < photos.size() && i < max; i++) {
            Photo p = photos.get(i);
            out.print("<div class='container'>");
            out.print("<div class='img' onclick='photoClick(" + p.getNo() + ")'>");
            out.print("<img src='ServletGetImage?photo=" + p.getNo() + "'>");
            out.print("</div>");
            out.print("<input type='button' id='btn" + p.getNo() + "' onclick='Javascript:like(" + p.getNo() + ");' value='" + liked("" + p.getNo()) + "' style='margin: 0px;'/>");
            out.print("<b id='likes" + p.getNo() + "'>" + p.getRating() + " like(s)</b>");
            out.print("</div>");
        }
        return i;
    }
View Full Code Here

TOP

Related Classes of Java.Photo

Copyright © 2015 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.